From 8f5acb09328395c71744eb1f9a1b49bb8488482e Mon Sep 17 00:00:00 2001 From: mark_story Date: Tue, 27 May 2014 23:19:44 -0400 Subject: [PATCH] Fix CS errors in skel/ --- app/Config/Schema/db_acl.php | 14 ++++++++++- .../Templates/skel/Config/Schema/db_acl.php | 22 +++++++++++++++++ .../Templates/skel/Config/Schema/i18n.php | 22 +++++++++++++++++ .../Templates/skel/Config/Schema/sessions.php | 24 ++++++++++++++++++- .../skel/Controller/PagesController.php | 3 +-- .../Templates/skel/Test/Case/AllTestsTest.php | 5 ++++ 6 files changed, 86 insertions(+), 4 deletions(-) diff --git a/app/Config/Schema/db_acl.php b/app/Config/Schema/db_acl.php index 91d93e084..7ba826b04 100644 --- a/app/Config/Schema/db_acl.php +++ b/app/Config/Schema/db_acl.php @@ -18,7 +18,7 @@ * @license http://www.opensource.org/licenses/mit-license.php MIT License */ -/* +/** * * Using the Schema command line utility * cake schema run create DbAcl @@ -26,10 +26,22 @@ */ class DbAclSchema extends CakeSchema { +/** + * Before event. + * + * @param array $event The event data. + * @return boolean success + */ public function before($event = array()) { return true; } +/** + * After event. + * + * @param array $event The event data. + * @return void + */ public function after($event = array()) { } diff --git a/lib/Cake/Console/Templates/skel/Config/Schema/db_acl.php b/lib/Cake/Console/Templates/skel/Config/Schema/db_acl.php index b532fe370..39bc58a29 100644 --- a/lib/Cake/Console/Templates/skel/Config/Schema/db_acl.php +++ b/lib/Cake/Console/Templates/skel/Config/Schema/db_acl.php @@ -17,13 +17,28 @@ */ class DbAclSchema extends CakeSchema { +/** + * Before event. + * + * @param array $event The event data. + * @return boolean success + */ public function before($event = array()) { return true; } +/** + * After event. + * + * @param array $event The event data. + * @return void + */ public function after($event = array()) { } +/** + * ACO - Access Control Object - Something that is wanted + */ public $acos = array( 'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'key' => 'primary'), 'parent_id' => array('type' => 'integer', 'null' => true, 'default' => null, 'length' => 10), @@ -35,6 +50,9 @@ class DbAclSchema extends CakeSchema { 'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1)) ); +/** + * ARO - Access Request Object - Something that wants something + */ public $aros = array( 'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'key' => 'primary'), 'parent_id' => array('type' => 'integer', 'null' => true, 'default' => null, 'length' => 10), @@ -46,6 +64,10 @@ class DbAclSchema extends CakeSchema { 'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1)) ); +/** + * Used by the Cake::Model:Permission class. + * Checks if the given $aro has access to action $action in $aco. + */ public $aros_acos = array( 'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'key' => 'primary'), 'aro_id' => array('type' => 'integer', 'null' => false, 'length' => 10, 'key' => 'index'), diff --git a/lib/Cake/Console/Templates/skel/Config/Schema/i18n.php b/lib/Cake/Console/Templates/skel/Config/Schema/i18n.php index d09922e83..078e6d585 100644 --- a/lib/Cake/Console/Templates/skel/Config/Schema/i18n.php +++ b/lib/Cake/Console/Templates/skel/Config/Schema/i18n.php @@ -19,15 +19,37 @@ */ class I18nSchema extends CakeSchema { +/** + * The name property + * + * @var string + */ public $name = 'i18n'; +/** + * Before event. + * + * @param array $event The event data. + * @return boolean success + */ public function before($event = array()) { return true; } +/** + * After event. + * + * @param array $event The event data. + * @return void + */ public function after($event = array()) { } +/** + * The i18n table property + * + * @var array + */ public $i18n = array( 'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'key' => 'primary'), 'locale' => array('type' => 'string', 'null' => false, 'length' => 6, 'key' => 'index'), diff --git a/lib/Cake/Console/Templates/skel/Config/Schema/sessions.php b/lib/Cake/Console/Templates/skel/Config/Schema/sessions.php index 078f5d531..aab57f3fb 100644 --- a/lib/Cake/Console/Templates/skel/Config/Schema/sessions.php +++ b/lib/Cake/Console/Templates/skel/Config/Schema/sessions.php @@ -9,7 +9,7 @@ * @since CakePHP(tm) v 0.2.9 */ -/* +/** * * Using the Schema command line utility * cake schema run create Sessions @@ -17,15 +17,37 @@ */ class SessionsSchema extends CakeSchema { +/** + * Name property + * + * @var string + */ public $name = 'Sessions'; +/** + * Before event. + * + * @param array $event The event data. + * @return bool Success + */ public function before($event = array()) { return true; } +/** + * After event. + * + * @param array $event The event data. + * @return void + */ public function after($event = array()) { } +/** + * cake_sessions table definition + * + * @var array + */ public $cake_sessions = array( 'id' => array('type' => 'string', 'null' => false, 'key' => 'primary'), 'data' => array('type' => 'text', 'null' => true, 'default' => null), diff --git a/lib/Cake/Console/Templates/skel/Controller/PagesController.php b/lib/Cake/Console/Templates/skel/Controller/PagesController.php index 87fb589af..eb023a573 100644 --- a/lib/Cake/Console/Templates/skel/Controller/PagesController.php +++ b/lib/Cake/Console/Templates/skel/Controller/PagesController.php @@ -31,10 +31,9 @@ class PagesController extends AppController { /** * Displays a view * - * @param mixed What page to display * @return void * @throws NotFoundException When the view file could not be found - * or MissingViewException in debug mode. + * or MissingViewException in debug mode. */ public function display() { $path = func_get_args(); diff --git a/lib/Cake/Console/Templates/skel/Test/Case/AllTestsTest.php b/lib/Cake/Console/Templates/skel/Test/Case/AllTestsTest.php index 904bc3b50..9929fa582 100644 --- a/lib/Cake/Console/Templates/skel/Test/Case/AllTestsTest.php +++ b/lib/Cake/Console/Templates/skel/Test/Case/AllTestsTest.php @@ -18,6 +18,11 @@ class AllTestsTest extends CakeTestSuite { +/** + * Get the suite object. + * + * @return CakeTestSuite Suite class instance. + */ public static function suite() { $suite = new CakeTestSuite('All application tests'); $suite->addTestDirectoryRecursive(TESTS . 'Case');