From f291c5f365c244e21d64394b82c357cc968ca137 Mon Sep 17 00:00:00 2001 From: Peter Thaleikis Date: Mon, 28 Sep 2015 22:31:31 +1300 Subject: [PATCH] fixing phpdoc blocks to refering to Objects to built-in types of PHP --- code/controllers/CMSMain.php | 8 ++++---- code/controllers/CMSPagesController.php | 2 +- code/controllers/CMSSiteTreeFilter.php | 2 +- code/controllers/LeftAndMainPageIconsExtension.php | 2 +- code/controllers/SilverStripeNavigator.php | 10 +++++----- code/model/ErrorPage.php | 2 +- code/model/SiteTree.php | 2 +- code/model/SiteTreeFileExtension.php | 8 ++++---- tests/behat/features/bootstrap/FeatureContext.php | 2 +- 9 files changed, 19 insertions(+), 19 deletions(-) diff --git a/code/controllers/CMSMain.php b/code/controllers/CMSMain.php index b7e4e361..b1773529 100644 --- a/code/controllers/CMSMain.php +++ b/code/controllers/CMSMain.php @@ -422,7 +422,7 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr * Create serialized JSON string with site tree hints data to be injected into * 'data-hints' attribute of root node of jsTree. * - * @return String Serialized JSON + * @return string Serialized JSON */ public function SiteTreeHints() { $json = ''; @@ -591,7 +591,7 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr } /** - * @param Int $id + * @param int $id * @param FieldList $fields * @return Form */ @@ -701,7 +701,7 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr /** * @param SS_HTTPRequest $request - * @return String HTML + * @return string HTML */ public function treeview($request) { return $this->renderWith($this->getTemplatesWithSuffix('_TreeView')); @@ -709,7 +709,7 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr /** * @param SS_HTTPRequest $request - * @return String HTML + * @return string HTML */ public function listview($request) { return $this->renderWith($this->getTemplatesWithSuffix('_ListView')); diff --git a/code/controllers/CMSPagesController.php b/code/controllers/CMSPagesController.php index fd398d94..e80c7773 100644 --- a/code/controllers/CMSPagesController.php +++ b/code/controllers/CMSPagesController.php @@ -17,7 +17,7 @@ class CMSPagesController extends CMSMain { } /** - * @return String + * @return string */ public function ViewState() { return $this->getRequest()->getVar('view'); diff --git a/code/controllers/CMSSiteTreeFilter.php b/code/controllers/CMSSiteTreeFilter.php index f90e779e..6af0e9c0 100644 --- a/code/controllers/CMSSiteTreeFilter.php +++ b/code/controllers/CMSSiteTreeFilter.php @@ -44,7 +44,7 @@ abstract class CMSSiteTreeFilter extends Object implements LeftAndMain_SearchFil protected $_cache_expanded = array(); /** - * @var String + * @var string */ protected $childrenMethod = null; diff --git a/code/controllers/LeftAndMainPageIconsExtension.php b/code/controllers/LeftAndMainPageIconsExtension.php index 5b481d7d..ee65661a 100644 --- a/code/controllers/LeftAndMainPageIconsExtension.php +++ b/code/controllers/LeftAndMainPageIconsExtension.php @@ -15,7 +15,7 @@ class LeftAndMainPageIconsExtension extends Extension { * Include CSS for page icons. We're not using the JSTree 'types' option * because it causes too much performance overhead just to add some icons. * - * @return String CSS + * @return string CSS */ public function generatePageIconsCss() { $css = ''; diff --git a/code/controllers/SilverStripeNavigator.php b/code/controllers/SilverStripeNavigator.php index b5e4d2f3..dbfe384c 100644 --- a/code/controllers/SilverStripeNavigator.php +++ b/code/controllers/SilverStripeNavigator.php @@ -120,13 +120,13 @@ class SilverStripeNavigatorItem extends ViewableData { } /** - * @return String HTML, mostly a link - but can be more complex as well. + * @return string HTML, mostly a link - but can be more complex as well. * For example, a "future state" item might show a date selector. */ public function getHTML() {} /** - * @return String + * @return string * Get the Title of an item */ public function getTitle() {} @@ -143,12 +143,12 @@ class SilverStripeNavigatorItem extends ViewableData { * Not all items are simple links, please use {@link getHTML()} * to represent an item in markup unless you know what you're doing. * - * @return String + * @return string */ public function getLink() {} /** - * @return String + * @return string */ public function getMessage() {} @@ -160,7 +160,7 @@ class SilverStripeNavigatorItem extends ViewableData { } /** - * @return Int + * @return int */ public function getPriority() { return $this->stat('priority'); diff --git a/code/model/ErrorPage.php b/code/model/ErrorPage.php index 2ee49249..5fa1d736 100644 --- a/code/model/ErrorPage.php +++ b/code/model/ErrorPage.php @@ -280,7 +280,7 @@ class ErrorPage extends Page { * which is generated through {@link publish()}. * * @param int $statusCode A HTTP Statuscode, mostly 404 or 500 - * @param String $locale A locale, e.g. 'de_DE' (Optional) + * @param string $locale A locale, e.g. 'de_DE' (Optional) * * @return string */ diff --git a/code/model/SiteTree.php b/code/model/SiteTree.php index c7e298a8..abe79040 100755 --- a/code/model/SiteTree.php +++ b/code/model/SiteTree.php @@ -177,7 +177,7 @@ class SiteTree extends DataObject implements PermissionProvider,i18nEntityProvid /** * @config - * @var String Description of the class functionality, typically shown to a user + * @var string Description of the class functionality, typically shown to a user * when selecting which page type to create. Translated through {@link provideI18nEntities()}. */ private static $description = 'Generic content page'; diff --git a/code/model/SiteTreeFileExtension.php b/code/model/SiteTreeFileExtension.php index 12b6c9c7..501385b5 100644 --- a/code/model/SiteTreeFileExtension.php +++ b/code/model/SiteTreeFileExtension.php @@ -24,7 +24,7 @@ class SiteTreeFileExtension extends DataExtension { /** * Generate an HTML list which provides links to where a file is used. * - * @return String + * @return string */ public function BackLinkHTMLList() { $html = '' . _t('SiteTreeFileExtension.BACKLINK_LIST_DESCRIPTION', 'This list shows all pages where the file has been added through a WYSIWYG editor.') . ''; @@ -91,7 +91,7 @@ class SiteTreeFileExtension extends DataExtension { /** * @todo Unnecessary shortcut for AssetTableField, coupled with cms module. * - * @return Integer + * @return integer */ public function BackLinkTrackingCount() { $pages = $this->owner->BackLinkTracking(); @@ -133,8 +133,8 @@ class SiteTreeFileExtension extends DataExtension { * * @uses SiteTree->rewriteFileURL() * - * @param String $old File path relative to the webroot - * @param String $new File path relative to the webroot + * @param string $old File path relative to the webroot + * @param string $new File path relative to the webroot */ public function updateLinks($old, $new) { if(class_exists('Subsite')) Subsite::disable_subsite_filter(true); diff --git a/tests/behat/features/bootstrap/FeatureContext.php b/tests/behat/features/bootstrap/FeatureContext.php index 2dce078e..41a22526 100644 --- a/tests/behat/features/bootstrap/FeatureContext.php +++ b/tests/behat/features/bootstrap/FeatureContext.php @@ -26,7 +26,7 @@ class FeatureContext extends \SilverStripe\Framework\Test\Behaviour\FeatureConte * Initializes context. * Every scenario gets it's own context object. * - * @param array $parameters context parameters (set them up through behat.yml) + * @param array $parameters context parameters (set them up through behat.yml) */ public function __construct(array $parameters) { parent::__construct($parameters);