File modules/cms/action/Method.class.php
Last commit: Tue Oct 13 22:52:59 2026 +0200 Jan Dankert New: The UI is now able to send hierarchical form data and the server is converting it into an object. This is a very nice feature, because this enables a better OpenAPI interface.
1 <?php 2 3 4 namespace cms\action; 5 6 /** 7 * Method. 8 * 9 * A Method is divided into 10 * - a view and 11 * - a post action. 12 * 13 * Every Method must implement this interface. 14 * 15 * @package cms\action 16 */ 17 interface Method 18 { 19 /** 20 * View. 21 * 22 * View action for displaying data. 23 * Normally this is called after a HTTP GET. 24 * This method needs to be idempotent, this usually means that no data is written to the model. 25 * This method should be readonly, but may write data to the session. 26 * 27 * @return void 28 */ 29 public function view(); 30 31 /** 32 * Post action. 33 * 34 * Post action for writing data to the model (and the database). 35 * 36 * Normally this is called after a HTTP POST. 37 * 38 * @return object|null 39 */ 40 public function post(); 41 }
Downloadmodules/cms/action/Method.class.php
History Tue, 13 Oct 2026 22:52:59 +0200 Jan Dankert New: The UI is now able to send hierarchical form data and the server is converting it into an object. This is a very nice feature, because this enables a better OpenAPI interface. Thu, 18 Feb 2021 01:55:01 +0100 Jan Dankert New: Action for displaying a navigation while no other action is selected. Tue, 17 Nov 2020 23:51:00 +0100 Jan Dankert Refactoring: Every Actionmethod has now its own class.