Fix the phpdoc blocks

This commit is contained in:
William Desportes 2020-12-21 22:23:23 +01:00
parent a8d121d23f
commit c932d7e7fb
No known key found for this signature in database
GPG Key ID: 90A0EF1B8251A889
85 changed files with 199 additions and 195 deletions

View File

@ -72,6 +72,7 @@ class CLIRequestBuilder extends HTTPRequestBuilder
/** /**
* @param array $variables * @param array $variables
* @param string $input * @param string $input
* @param string|null $url
* @return HTTPRequest * @return HTTPRequest
*/ */
public static function createFromVariables(array $variables, $input, $url = null) public static function createFromVariables(array $variables, $input, $url = null)

View File

@ -663,7 +663,7 @@ class Controller extends RequestHandler implements TemplateGlobalProvider
* *
* Caution: All parameters are expected to be URI-encoded already. * Caution: All parameters are expected to be URI-encoded already.
* *
* @param string|array $arg,.. One or more link segments, or list of link segments as an array * @param string|array $arg One or more link segments, or list of link segments as an array
* @return string * @return string
*/ */
public static function join_links($arg = null) public static function join_links($arg = null)

View File

@ -26,7 +26,7 @@ class HTTPResponse_Exception extends Exception
* response. * response.
* @param int $statusCode * @param int $statusCode
* @param string $statusDescription * @param string $statusDescription
* @see HTTPResponse::__construct(); * @see HTTPResponse::__construct()
*/ */
public function __construct($body = null, $statusCode = null, $statusDescription = null) public function __construct($body = null, $statusCode = null, $statusDescription = null)
{ {

View File

@ -54,6 +54,7 @@ class GetParameter implements Rule, Bypass
* Generates the confirmation item * Generates the confirmation item
* *
* @param string $token * @param string $token
* @param string $value
* *
* @return Confirmation\Item * @return Confirmation\Item
*/ */
@ -70,7 +71,7 @@ class GetParameter implements Rule, Bypass
* Generates the unique token depending on the path and the parameter * Generates the unique token depending on the path and the parameter
* *
* @param string $path URL path * @param string $path URL path
* @param string $param The parameter value * @param string $value The parameter value
* *
* @return string * @return string
*/ */

View File

@ -19,7 +19,7 @@ class HttpMethodBypass implements Bypass
/** /**
* Initialize the bypass with HTTP methods * Initialize the bypass with HTTP methods
* *
* @param string[] ...$method * @param string[] ...$methods
*/ */
public function __construct(...$methods) public function __construct(...$methods)
{ {

View File

@ -80,7 +80,7 @@ class Url implements Rule, Bypass
* against parameter values accordingly. Null * against parameter values accordingly. Null
* as a value in the array matches any parameter values. * as a value in the array matches any parameter values.
* *
* @param string|null $httpMethods * @param string|null $params
* *
* @return $this * @return $this
*/ */
@ -186,6 +186,7 @@ class Url implements Rule, Bypass
/** /**
* Generates the unique token depending on the path * Generates the unique token depending on the path
* *
* @param string $httpMethod HTTP method
* @param string $path URL path * @param string $path URL path
* *
* @return string * @return string

View File

@ -244,7 +244,7 @@ class RSSFeed extends ViewableData
* Set the name of the template to use. Actual template will be resolved * Set the name of the template to use. Actual template will be resolved
* via the standard template inclusion process. * via the standard template inclusion process.
* *
* @param string * @param string $template
*/ */
public function setTemplate($template) public function setTemplate($template)
{ {

View File

@ -85,7 +85,7 @@ class IPUtils
* Compares two IPv6 addresses. * Compares two IPv6 addresses.
* In case a subnet is given, it checks if it contains the request IP. * In case a subnet is given, it checks if it contains the request IP.
* *
* @author David Soria Parra <dsp at php dot net> * @author David Soria Parra <dsp@php.net>
* *
* @see https://github.com/dsp/v6tools * @see https://github.com/dsp/v6tools
* *

View File

@ -109,7 +109,7 @@ class Config_ForClass
} }
/** /**
* @param string * @param string $class
* *
* @return Config_ForClass * @return Config_ForClass
*/ */

View File

@ -336,7 +336,7 @@ class Convert
* Convert a XML string to a PHP array recursively. Do not * Convert a XML string to a PHP array recursively. Do not
* call this function directly, Please use {@link Convert::xml2array()} * call this function directly, Please use {@link Convert::xml2array()}
* *
* @param SimpleXMLElement * @param SimpleXMLElement $xml
* *
* @return mixed * @return mixed
*/ */
@ -491,7 +491,7 @@ class Convert
* Convert a string (normally a title) to a string suitable for using in * Convert a string (normally a title) to a string suitable for using in
* urls and other html attributes. Uses {@link URLSegmentFilter}. * urls and other html attributes. Uses {@link URLSegmentFilter}.
* *
* @param string * @param string $title
* @return string * @return string
*/ */
public static function raw2url($title) public static function raw2url($title)

View File

@ -1103,7 +1103,7 @@ class Injector implements ContainerInterface
* Additional parameters are passed through as * Additional parameters are passed through as
* *
* @param string $name * @param string $name
* @param mixed $argument,... arguments to pass to the constructor * @param mixed ...$argument arguments to pass to the constructor
* @return mixed A new instance of the specified object * @return mixed A new instance of the specified object
*/ */
public function create($name, $argument = null) public function create($name, $argument = null)

View File

@ -17,7 +17,7 @@ class ClassManifestErrorHandler implements ErrorHandler
protected $pathname; protected $pathname;
/** /**
* @param String $pathname * @param string $pathname
*/ */
public function __construct($pathname) public function __construct($pathname)
{ {

View File

@ -44,7 +44,6 @@ class RequestFlushDiscoverer implements FlushDiscoverer
/** /**
* Checks whether the request contains any flush indicators * Checks whether the request contains any flush indicators
* *
* @param HTTPRequest $request active request
* *
* @return null|bool flush or don't care * @return null|bool flush or don't care
*/ */

View File

@ -55,7 +55,7 @@ abstract class BuildTask
* execute via the TaskRunner * execute via the TaskRunner
* *
* @param HTTPRequest $request * @param HTTPRequest $request
* @return * @return void
*/ */
abstract public function run($request); abstract public function run($request);

View File

@ -68,7 +68,7 @@ class CSSContentParser
* Currently the selector engine only supports querying by tag, id, and class. * Currently the selector engine only supports querying by tag, id, and class.
* See {@link getByXpath()} for a more direct selector syntax. * See {@link getByXpath()} for a more direct selector syntax.
* *
* @param String $selector * @param string $selector
* @return SimpleXMLElement[] * @return SimpleXMLElement[]
*/ */
public function getBySelector($selector) public function getBySelector($selector)
@ -80,7 +80,7 @@ class CSSContentParser
/** /**
* Allows querying the content through XPATH selectors. * Allows querying the content through XPATH selectors.
* *
* @param String $xpath SimpleXML compatible XPATH statement * @param string $xpath SimpleXML compatible XPATH statement
* @return SimpleXMLElement[] * @return SimpleXMLElement[]
*/ */
public function getByXpath($xpath) public function getByXpath($xpath)
@ -92,7 +92,7 @@ class CSSContentParser
* Converts a CSS selector into an equivalent xpath expression. * Converts a CSS selector into an equivalent xpath expression.
* Currently the selector engine only supports querying by tag, id, and class. * Currently the selector engine only supports querying by tag, id, and class.
* *
* @param String $selector See {@link getBySelector()} * @param string $selector See {@link getBySelector()}
* @return String XPath expression * @return String XPath expression
*/ */
public function selector2xpath($selector) public function selector2xpath($selector)

View File

@ -134,7 +134,7 @@ class CSVParser implements Iterator
* )); * ));
* </code> * </code>
* *
* @param array * @param array $columnMap
*/ */
public function mapColumns($columnMap) public function mapColumns($columnMap)
{ {
@ -156,7 +156,7 @@ class CSVParser implements Iterator
* If you call this function, then the first row of the CSV will be * If you call this function, then the first row of the CSV will be
* included in the data returned. * included in the data returned.
* *
* @param array * @param array $headerRow
*/ */
public function provideHeaderRow($headerRow) public function provideHeaderRow($headerRow)
{ {
@ -210,7 +210,7 @@ class CSVParser implements Iterator
/** /**
* Map the contents of a header array using $this->mappedColumns. * Map the contents of a header array using $this->mappedColumns.
* *
* @param array * @param array $header
* *
* @return array * @return array
*/ */

View File

@ -48,8 +48,8 @@ class FixtureBlueprint
]; ];
/** /**
* @param String $name * @param string $name
* @param String $class Defaults to $name * @param string $class Defaults to $name
* @param array $defaults * @param array $defaults
*/ */
public function __construct($name, $class = null, $defaults = []) public function __construct($name, $class = null, $defaults = [])

View File

@ -239,7 +239,7 @@ class FixtureFactory
} }
/** /**
* @param String $name * @param string $name
* @return FixtureBlueprint|false * @return FixtureBlueprint|false
*/ */
public function getBlueprint($name) public function getBlueprint($name)

View File

@ -35,7 +35,7 @@ class i18nTextCollectorTask extends BuildTask
* It will search for existent modules that use the i18n feature, parse the _t() calls * It will search for existent modules that use the i18n feature, parse the _t() calls
* and write the resultant files in the lang folder of each module. * and write the resultant files in the lang folder of each module.
* *
* @uses DataObject->collectI18nStatics() * @uses DataObject::collectI18nStatics()
* *
* @param HTTPRequest $request * @param HTTPRequest $request
*/ */

View File

@ -324,7 +324,7 @@ class CompositeField extends FormField
/** /**
* Add a new child field to the end of the set. * Add a new child field to the end of the set.
* *
* @param FormField * @param FormField $field
*/ */
public function push(FormField $field) public function push(FormField $field)
{ {
@ -334,7 +334,7 @@ class CompositeField extends FormField
/** /**
* Add a new child field to the beginning of the set. * Add a new child field to the beginning of the set.
* *
* @param FormField * @param FormField $field
*/ */
public function unshift(FormField $field) public function unshift(FormField $field)
{ {
@ -342,10 +342,11 @@ class CompositeField extends FormField
} }
/** /**
* @uses FieldList->insertBefore() * @uses FieldList::insertBefore()
* *
* @param string $insertBefore * @param string $insertBefore
* @param FormField $field * @param FormField $field
* @param bool $appendIfMissing
* @return false|FormField * @return false|FormField
*/ */
public function insertBefore($insertBefore, $field, $appendIfMissing = true) public function insertBefore($insertBefore, $field, $appendIfMissing = true)
@ -354,9 +355,10 @@ class CompositeField extends FormField
} }
/** /**
* @uses FieldList->insertAfter() * @uses FieldList::insertAfter()
* @param string $insertAfter * @param string $insertAfter
* @param FormField $field * @param FormField $field
* @param bool $appendIfMissing
* @return false|FormField * @return false|FormField
*/ */
public function insertAfter($insertAfter, $field, $appendIfMissing = true) public function insertAfter($insertAfter, $field, $appendIfMissing = true)
@ -470,7 +472,7 @@ class CompositeField extends FormField
* Find the numerical position of a field within * Find the numerical position of a field within
* the children collection. Doesn't work recursively. * the children collection. Doesn't work recursively.
* *
* @param string|FormField * @param string|FormField $field
* @return int Position in children collection (first position starts with 0). Returns FALSE if the field can't * @return int Position in children collection (first position starts with 0). Returns FALSE if the field can't
* be found. * be found.
*/ */
@ -496,9 +498,9 @@ class CompositeField extends FormField
} }
/** /**
* Transform the named field into a readonly feld. * Transform the named field into a readonly field.
* *
* @param string|FormField * @param string|FormField $field
* @return bool * @return bool
*/ */
public function makeFieldReadonly($field) public function makeFieldReadonly($field)

View File

@ -288,7 +288,7 @@ class DatetimeField extends TextField
/** /**
* Get a date formatter for the ISO 8601 format * Get a date formatter for the ISO 8601 format
* *
* @param String $timezone Optional timezone identifier (defaults to server timezone) * @param string $timezone Optional timezone identifier (defaults to server timezone)
* @return IntlDateFormatter * @return IntlDateFormatter
*/ */
protected function getInternalFormatter($timezone = null) protected function getInternalFormatter($timezone = null)

View File

@ -881,7 +881,7 @@ class FieldList extends ArrayList
* Find the numerical position of a field within * Find the numerical position of a field within
* the children collection. Doesn't work recursively. * the children collection. Doesn't work recursively.
* *
* @param string|FormField * @param string|FormField $field
* @return int Position in children collection (first position starts with 0). * @return int Position in children collection (first position starts with 0).
* Returns FALSE if the field can't be found. * Returns FALSE if the field can't be found.
*/ */

View File

@ -170,9 +170,9 @@ class Form extends ViewableData implements HasRequestHandler
/** /**
* The SS template to render this form HTML into. * The SS template to render this form HTML into.
* Default is "Form", but this can be changed to * Default is "Form", but this can be changed to
* another template for customisation. * another template for customization.
* *
* @see Form->setTemplate() * @see Form::setTemplate()
* @var string|array|null * @var string|array|null
*/ */
protected $template; protected $template;
@ -326,7 +326,7 @@ class Form extends ViewableData implements HasRequestHandler
} }
/** /**
* @param bool * @param bool $flag
*/ */
public function setNotifyUnsavedChanges($flag) public function setNotifyUnsavedChanges($flag)
{ {
@ -664,7 +664,7 @@ class Form extends ViewableData implements HasRequestHandler
/** /**
* Set actions that are exempt from validation * Set actions that are exempt from validation
* *
* @param array * @param array $actions
* @return $this * @return $this
*/ */
public function setValidationExemptActions($actions) public function setValidationExemptActions($actions)
@ -916,7 +916,7 @@ class Form extends ViewableData implements HasRequestHandler
* Set the target of this form to any value - useful for opening the form contents in a new window or refreshing * Set the target of this form to any value - useful for opening the form contents in a new window or refreshing
* another frame * another frame
* *
* @param string|FormTemplateHelper * @param string|FormTemplateHelper $helper
*/ */
public function setTemplateHelper($helper) public function setTemplateHelper($helper)
{ {
@ -1371,9 +1371,9 @@ class Form extends ViewableData implements HasRequestHandler
* Escaping happens automatically on saving the data through * Escaping happens automatically on saving the data through
* {@link saveInto()}. * {@link saveInto()}.
* *
* @uses FieldList->dataFields() * @uses FieldList::dataFields()
* @uses FormField->setSubmittedValue() * @uses FormField::setSubmittedValue()
* @uses FormField->setValue() * @uses FormField::setValue()
* *
* @param array|DataObject $data * @param array|DataObject $data
* @param int $mergeStrategy * @param int $mergeStrategy

View File

@ -75,7 +75,7 @@ class FormAction extends FormField
* *
* @param string $action The method to call when the button is clicked * @param string $action The method to call when the button is clicked
* @param string $title The label on the button. This should be plain text, not escaped as HTML. * @param string $title The label on the button. This should be plain text, not escaped as HTML.
* @param Form form The parent form, auto-set when the field is placed inside a form * @param Form $form The parent form, auto-set when the field is placed inside a form
*/ */
public function __construct($action, $title = "", $form = null) public function __construct($action, $title = "", $form = null)
{ {
@ -225,7 +225,7 @@ class FormAction extends FormField
/** /**
* Enable or disable the rendering of this action as a <button /> * Enable or disable the rendering of this action as a <button />
* *
* @param boolean * @param boolean $bool
* @return $this * @return $this
*/ */
public function setUseButtonTag($bool) public function setUseButtonTag($bool)

View File

@ -521,7 +521,7 @@ class FormField extends RequestHandler
/** /**
* Sets the right title for this formfield * Sets the right title for this formfield
* *
* @param string|DBField Plain text string, or a DBField with appropriately escaped HTML * @param string|DBField $rightTitle Plain text string, or a DBField with appropriately escaped HTML
* @return $this * @return $this
*/ */
public function setRightTitle($rightTitle) public function setRightTitle($rightTitle)
@ -1012,7 +1012,7 @@ class FormField extends RequestHandler
$result = $context->renderWith($this->getTemplates()); $result = $context->renderWith($this->getTemplates());
// Trim whitespace from the result, so that trailing newlines are supressed. Works for strings and HTMLText values // Trim whitespace from the result, so that trailing newlines are suppressed. Works for strings and HTMLText values
if (is_string($result)) { if (is_string($result)) {
$result = trim($result); $result = trim($result);
} elseif ($result instanceof DBField) { } elseif ($result instanceof DBField) {
@ -1294,7 +1294,7 @@ class FormField extends RequestHandler
* *
* It's handy for assigning HTML classes. Doesn't signify the input type attribute. * It's handy for assigning HTML classes. Doesn't signify the input type attribute.
* *
* @see {link getAttributes()}. * @see {@link getAttributes()}.
* *
* @return string * @return string
*/ */

View File

@ -68,7 +68,7 @@ class GridFieldConfig
} }
/** /**
* @param GridFieldComponent|GridFieldComponent[] $component,... One or more components, or an array of components * @param GridFieldComponent|GridFieldComponent[] ...$component One or more components, or an array of components
* @return $this * @return $this
*/ */
public function addComponents($component = null) public function addComponents($component = null)

View File

@ -34,7 +34,7 @@ class GridFieldDataColumns implements GridField_ColumnProvider
* See {@link GridFieldDataColumns->getDisplayFields()} and {@link GridFieldDataColumns}. * See {@link GridFieldDataColumns->getDisplayFields()} and {@link GridFieldDataColumns}.
* *
* @param GridField $gridField * @param GridField $gridField
* @param array - List reference of all column names. * @param array $columns List reference of all column names. (by reference)
*/ */
public function augmentColumns($gridField, &$columns) public function augmentColumns($gridField, &$columns)
{ {

View File

@ -165,6 +165,8 @@ class GridFieldFilterHeader implements GridField_URLHandler, GridField_HTMLProvi
* If the GridField has a filterable datalist, return an array of actions * If the GridField has a filterable datalist, return an array of actions
* *
* @param GridField $gridField * @param GridField $gridField
* @param string $actionName
* @param array $data
* @return void * @return void
*/ */
public function handleAction(GridField $gridField, $actionName, $arguments, $data) public function handleAction(GridField $gridField, $actionName, $arguments, $data)

View File

@ -53,7 +53,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr
/** /**
* Place the print button in a <p> tag below the field * Place the print button in a <p> tag below the field
* *
* @param GridField * @param GridField $gridField
* *
* @return array * @return array
*/ */
@ -78,7 +78,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr
/** /**
* Print is an action button. * Print is an action button.
* *
* @param GridField * @param GridField $gridField
* *
* @return array * @return array
*/ */
@ -106,7 +106,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr
/** /**
* Print is accessible via the url * Print is accessible via the url
* *
* @param GridField * @param GridField $gridField
* @return array * @return array
*/ */
public function getURLHandlers($gridField) public function getURLHandlers($gridField)
@ -145,7 +145,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr
/** /**
* Return the columns to print * Return the columns to print
* *
* @param GridField * @param GridField $gridField
* *
* @return array * @return array
*/ */
@ -167,7 +167,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr
/** /**
* Return the title of the printed page * Return the title of the printed page
* *
* @param GridField * @param GridField $gridField
* *
* @return array * @return array
*/ */

View File

@ -25,7 +25,7 @@ interface GridField_ActionProvider extends GridFieldComponent
* There is no namespacing on these actions, so you need to ensure that * There is no namespacing on these actions, so you need to ensure that
* they don't conflict with other components. * they don't conflict with other components.
* *
* @param GridField * @param GridField $gridField
* @return array with action identifier strings. * @return array with action identifier strings.
*/ */
public function getActions($gridField); public function getActions($gridField);

View File

@ -33,12 +33,12 @@ class HTMLEditorSanitiser
*/ */
private static $link_rel_value = 'noopener noreferrer'; private static $link_rel_value = 'noopener noreferrer';
/** @var [stdClass] - $element => $rule hash for whitelist element rules where the element name isn't a pattern */ /** @var stdClass - $element => $rule hash for whitelist element rules where the element name isn't a pattern */
protected $elements = []; protected $elements = [];
/** @var [stdClass] - Sequential list of whitelist element rules where the element name is a pattern */ /** @var stdClass - Sequential list of whitelist element rules where the element name is a pattern */
protected $elementPatterns = []; protected $elementPatterns = [];
/** @var [stdClass] - The list of attributes that apply to all further whitelisted elements added */ /** @var stdClass - The list of attributes that apply to all further whitelisted elements added */
protected $globalAttributes = []; protected $globalAttributes = [];
/** /**

View File

@ -403,12 +403,12 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
* *
* If passing in an associative array, the key of each item should be the plugin name. * If passing in an associative array, the key of each item should be the plugin name.
* The value of each item is one of: * The value of each item is one of:
* - null - Will be treated as a stardard plugin in the standard location * - null - Will be treated as a standard plugin in the standard location
* - relative path - Will be treated as a relative url * - relative path - Will be treated as a relative url
* - absolute url - Some url to an external plugin * - absolute url - Some url to an external plugin
* - An instance of ModuleResource object containing the plugin * - An instance of ModuleResource object containing the plugin
* *
* @param string|array $plugin,... a string, or several strings, or a single array of strings - The plugins to enable * @param string|array ...$plugin a string, or several strings, or a single array of strings - The plugins to enable
* @return $this * @return $this
*/ */
public function enablePlugins($plugin) public function enablePlugins($plugin)
@ -432,7 +432,7 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
/** /**
* Enable one or several plugins. Will properly handle being passed a plugin that is already disabled * Enable one or several plugins. Will properly handle being passed a plugin that is already disabled
* @param string|array $plugin,... a string, or several strings, or a single array of strings - The plugins to enable * @param string|array ...$plugin a string, or several strings, or a single array of strings - The plugins to enable
* @return $this * @return $this
*/ */
public function disablePlugins($plugin) public function disablePlugins($plugin)
@ -492,7 +492,7 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
* Totally re-set the buttons on a given line * Totally re-set the buttons on a given line
* *
* @param int $line The line number to redefine, from 1 to 3 * @param int $line The line number to redefine, from 1 to 3
* @param string $buttons,... A string or several strings, or a single array of strings. * @param string ...$buttons A string or several strings, or a single array of strings.
* The button names to assign to this line. * The button names to assign to this line.
* @return $this * @return $this
*/ */
@ -509,7 +509,7 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
/** /**
* Add buttons to the end of a line * Add buttons to the end of a line
* @param int $line The line number to redefine, from 1 to 3 * @param int $line The line number to redefine, from 1 to 3
* @param string $buttons,... A string or several strings, or a single array of strings. * @param string ...$buttons A string or several strings, or a single array of strings.
* The button names to add to this line * The button names to add to this line
* @return $this * @return $this
*/ */
@ -554,11 +554,11 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
} }
/** /**
* Insert buttons before the first occurance of another button * Insert buttons before the first occurrence of another button
* @param string $before the name of the button to insert other buttons before * @param string $before the name of the button to insert other buttons before
* @param string $buttons,... a string, or several strings, or a single array of strings. * @param string ...$buttons a string, or several strings, or a single array of strings.
* The button names to insert before that button * The button names to insert before that button
* @return bool True if insertion occured, false if it did not (because the given button name was not found) * @return bool True if insertion occurred, false if it did not (because the given button name was not found)
*/ */
public function insertButtonsBefore($before, $buttons) public function insertButtonsBefore($before, $buttons)
{ {
@ -573,11 +573,11 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
} }
/** /**
* Insert buttons after the first occurance of another button * Insert buttons after the first occurrence of another button
* @param string $after the name of the button to insert other buttons before * @param string $after the name of the button to insert other buttons before
* @param string $buttons,... a string, or several strings, or a single array of strings. * @param string ...$buttons a string, or several strings, or a single array of strings.
* The button names to insert after that button * The button names to insert after that button
* @return bool True if insertion occured, false if it did not (because the given button name was not found) * @return bool True if insertion occurred, false if it did not (because the given button name was not found)
*/ */
public function insertButtonsAfter($after, $buttons) public function insertButtonsAfter($after, $buttons)
{ {
@ -592,8 +592,8 @@ class TinyMCEConfig extends HTMLEditorConfig implements i18nEntityProvider
} }
/** /**
* Remove the first occurance of buttons * Remove the first occurrence of buttons
* @param string $buttons,... one or more strings - the name of the buttons to remove * @param string ...$buttons one or more strings - the name of the buttons to remove
*/ */
public function removeButtons($buttons) public function removeButtons($buttons)
{ {

View File

@ -260,7 +260,7 @@ abstract class SelectField extends FormField
* *
* @see FormField::castedCopy() * @see FormField::castedCopy()
* *
* @param String $classOrCopy * @param string $classOrCopy
* @return FormField * @return FormField
*/ */
public function castedCopy($classOrCopy) public function castedCopy($classOrCopy)

View File

@ -16,9 +16,9 @@ class SelectionGroup_Item extends CompositeField
protected $title; protected $title;
/** /**
* @param String $value Form field identifier * @param string $value Form field identifier
* @param FormField|array $fields Contents of the option * @param FormField|array $fields Contents of the option
* @param String $title Title to show for the radio button option * @param string $title Title to show for the radio button option
*/ */
function __construct($value, $fields = null, $title = null) function __construct($value, $fields = null, $title = null)
{ {

View File

@ -218,6 +218,7 @@ class TabSet extends CompositeField
* *
* @param string $insertBefore Name of the field to insert before * @param string $insertBefore Name of the field to insert before
* @param FormField $field The form field to insert * @param FormField $field The form field to insert
* @param bool $appendIfMissing
* @return FormField|null * @return FormField|null
*/ */
public function insertBefore($insertBefore, $field, $appendIfMissing = true) public function insertBefore($insertBefore, $field, $appendIfMissing = true)
@ -233,6 +234,7 @@ class TabSet extends CompositeField
* *
* @param string $insertAfter Name of the field to insert after * @param string $insertAfter Name of the field to insert after
* @param FormField $field The form field to insert * @param FormField $field The form field to insert
* @param bool $appendIfMissing
* @return FormField|null * @return FormField|null
*/ */
public function insertAfter($insertAfter, $field, $appendIfMissing = true) public function insertAfter($insertAfter, $field, $appendIfMissing = true)

View File

@ -97,7 +97,7 @@ trait UploadReceiver
* for each of these categories * for each of these categories
* *
* @param string $category Category name * @param string $category Category name
* @param string,... $categories Additional category names * @param string ...$categories Additional category names
* @return $this * @return $this
*/ */
public function setAllowedFileCategories($category) public function setAllowedFileCategories($category)

View File

@ -249,7 +249,7 @@ class ArrayList extends ViewableData implements SS_List, Filterable, Sortable, L
* *
* @param array|object $item * @param array|object $item
* @param array|object $with * @param array|object $with
* @return void; * @return void
*/ */
public function replace($item, $with) public function replace($item, $with)
{ {

View File

@ -52,12 +52,14 @@ abstract class DBSchemaManager
protected $supressOutput = false; protected $supressOutput = false;
/** /**
* @var array * @var array<string,string>
*/ */
protected static $table_name_warnings = []; protected static $table_name_warnings = [];
/** /**
* @param string * @param string $table
* @param string $class
*
* @deprecated 4.0.0:5.0.0 * @deprecated 4.0.0:5.0.0
*/ */
public static function showTableNameWarning($table, $class) public static function showTableNameWarning($table, $class)
@ -958,7 +960,7 @@ MESSAGE
* Return the list of indexes in a table. * Return the list of indexes in a table.
* *
* @param string $table The table name. * @param string $table The table name.
* @return array[array] List of current indexes in the table, each in standard * @return array[] List of current indexes in the table, each in standard
* array form. The key for this array should be predictable using the indexKey * array form. The key for this array should be predictable using the indexKey
* method * method
*/ */

View File

@ -484,8 +484,8 @@ abstract class Database
/** /**
* Generate a WHERE clause for text matching. * Generate a WHERE clause for text matching.
* *
* @param String $field Quoted field name * @param string $field Quoted field name
* @param String $value Escaped search. Can include percentage wildcards. * @param string $value Escaped search. Can include percentage wildcards.
* Ignored if $parameterised is true. * Ignored if $parameterised is true.
* @param boolean $exact Exact matches or wildcard support. * @param boolean $exact Exact matches or wildcard support.
* @param boolean $negate Negate the clause. * @param boolean $negate Negate the clause.
@ -526,7 +526,7 @@ abstract class Database
* function to return an SQL datetime expression that can be used with the adapter in use * function to return an SQL datetime expression that can be used with the adapter in use
* used for querying a datetime addition * used for querying a datetime addition
* *
* @param string $date, can be either 'now', literal datetime like '1973-10-14 10:30:00' or field name, * @param string $date can be either 'now', literal datetime like '1973-10-14 10:30:00' or field name,
* e.g. '"SiteTree"."Created"' * e.g. '"SiteTree"."Created"'
* @param string $interval to be added, use the format [sign][integer] [qualifier], e.g. -1 Day, +15 minutes, * @param string $interval to be added, use the format [sign][integer] [qualifier], e.g. -1 Day, +15 minutes,
* +1 YEAR * +1 YEAR
@ -547,7 +547,7 @@ abstract class Database
* function to return an SQL datetime expression that can be used with the adapter in use * function to return an SQL datetime expression that can be used with the adapter in use
* used for querying a datetime substraction * used for querying a datetime substraction
* *
* @param string $date1, can be either 'now', literal datetime like '1973-10-14 10:30:00' or field name * @param string $date1 can be either 'now', literal datetime like '1973-10-14 10:30:00' or field name
* e.g. '"SiteTree"."Created"' * e.g. '"SiteTree"."Created"'
* @param string $date2 to be substracted of $date1, can be either 'now', literal datetime * @param string $date2 to be substracted of $date1, can be either 'now', literal datetime
* like '1973-10-14 10:30:00' or field name, e.g. '"SiteTree"."Created"' * like '1973-10-14 10:30:00' or field name, e.g. '"SiteTree"."Created"'

View File

@ -55,7 +55,7 @@ class MySQLiConnector extends DBConnector
* Retrieve a prepared statement for a given SQL string * Retrieve a prepared statement for a given SQL string
* *
* @param string $sql * @param string $sql
* @param boolean &$success * @param boolean $success (by reference)
* @return mysqli_stmt * @return mysqli_stmt
*/ */
public function prepareStatement($sql, &$success) public function prepareStatement($sql, &$success)
@ -190,7 +190,7 @@ class MySQLiConnector extends DBConnector
* Prepares the list of parameters in preparation for passing to mysqli_stmt_bind_param * Prepares the list of parameters in preparation for passing to mysqli_stmt_bind_param
* *
* @param array $parameters List of parameters * @param array $parameters List of parameters
* @param array &$blobs Out parameter for list of blobs to bind separately * @param array $blobs Out parameter for list of blobs to bind separately (by reference)
* @return array List of parameters appropriate for mysqli_stmt_bind_param function * @return array List of parameters appropriate for mysqli_stmt_bind_param function
*/ */
public function parsePreparedParameters($parameters, &$blobs) public function parsePreparedParameters($parameters, &$blobs)

View File

@ -530,7 +530,7 @@ class DB
/** /**
* Create a new table. * Create a new table.
* @param string $table The name of the table * @param string $table The name of the table
* @param array$fields A map of field names to field types * @param array $fields A map of field names to field types
* @param array $indexes A map of indexes * @param array $indexes A map of indexes
* @param array $options An map of additional options. The available keys are as follows: * @param array $options An map of additional options. The available keys are as follows:
* - 'MSSQLDatabase'/'MySQLDatabase'/'PostgreSQLDatabase' - database-specific options such as "engine" * - 'MSSQLDatabase'/'MySQLDatabase'/'PostgreSQLDatabase' - database-specific options such as "engine"

View File

@ -135,7 +135,6 @@ abstract class DataExtension extends Extension
* See {@link DataObject::can()} and {@link DataObject::extendedCan()} for context. * See {@link DataObject::can()} and {@link DataObject::extendedCan()} for context.
* *
* @param Member $member * @param Member $member
* @param array $context
* @return bool|null * @return bool|null
*/ */
public function can($member) public function can($member)
@ -150,7 +149,6 @@ abstract class DataExtension extends Extension
* See {@link DataObject::canEdit()} and {@link DataObject::extendedCan()} for context. * See {@link DataObject::canEdit()} and {@link DataObject::extendedCan()} for context.
* *
* @param Member $member * @param Member $member
* @param array $context
* @return bool|null * @return bool|null
*/ */
public function canEdit($member) public function canEdit($member)
@ -165,7 +163,6 @@ abstract class DataExtension extends Extension
* See {@link DataObject::canDelete()} and {@link DataObject::extendedCan()} for context. * See {@link DataObject::canDelete()} and {@link DataObject::extendedCan()} for context.
* *
* @param Member $member * @param Member $member
* @param array $context
* @return bool|null * @return bool|null
*/ */
public function canDelete($member) public function canDelete($member)
@ -180,7 +177,6 @@ abstract class DataExtension extends Extension
* See {@link DataObject::canCreate()} and {@link DataObject::extendedCan()} for context. * See {@link DataObject::canCreate()} and {@link DataObject::extendedCan()} for context.
* *
* @param Member $member * @param Member $member
* @param array $context
* @return bool|null * @return bool|null
*/ */
public function canCreate($member) public function canCreate($member)

View File

@ -309,7 +309,7 @@ class DataList extends ViewableData implements SS_List, Filterable, Sortable, Li
* @example $list = $list->sort('Name', 'ASC'); * @example $list = $list->sort('Name', 'ASC');
* @example $list = $list->sort(array('Name'=>'ASC', 'Age'=>'DESC')); * @example $list = $list->sort(array('Name'=>'ASC', 'Age'=>'DESC'));
* *
* @param String|array Escaped SQL statement. If passed as array, all keys and values are assumed to be escaped. * @param string|array Escaped SQL statement. If passed as array, all keys and values are assumed to be escaped.
* @return static * @return static
*/ */
public function sort() public function sort()
@ -512,7 +512,7 @@ class DataList extends ViewableData implements SS_List, Filterable, Sortable, Li
* *
* *
* @param string $field Name of field or relation to apply * @param string $field Name of field or relation to apply
* @param string &$columnName Quoted column name * @param string $columnName Quoted column name (by reference)
* @param bool $linearOnly Set to true to restrict to linear relations only. Set this * @param bool $linearOnly Set to true to restrict to linear relations only. Set this
* if this relation will be used for sorting, and should not include duplicate rows. * if this relation will be used for sorting, and should not include duplicate rows.
* @return $this DataList with this relation applied * @return $this DataList with this relation applied

View File

@ -1237,7 +1237,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* *
* This called after {@link $this->validate()}, so you can be sure that your data is valid. * This called after {@link $this->validate()}, so you can be sure that your data is valid.
* *
* @uses DataExtension->onBeforeWrite() * @uses DataExtension::onBeforeWrite()
*/ */
protected function onBeforeWrite() protected function onBeforeWrite()
{ {
@ -1253,7 +1253,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* $this->changed will have a record * $this->changed will have a record
* database. Don't forget to call parent::onAfterWrite(), though! * database. Don't forget to call parent::onAfterWrite(), though!
* *
* @uses DataExtension->onAfterWrite() * @uses DataExtension::onAfterWrite()
*/ */
protected function onAfterWrite() protected function onAfterWrite()
{ {
@ -1283,7 +1283,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* You can overload this to clean up or otherwise process data before delete this * You can overload this to clean up or otherwise process data before delete this
* record. Don't forget to call parent::onBeforeDelete(), though! * record. Don't forget to call parent::onBeforeDelete(), though!
* *
* @uses DataExtension->onBeforeDelete() * @uses DataExtension::onBeforeDelete()
*/ */
protected function onBeforeDelete() protected function onBeforeDelete()
{ {
@ -1309,7 +1309,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* Will traverse the defaults of the current class and all its parent classes. * Will traverse the defaults of the current class and all its parent classes.
* Called by the constructor when creating new records. * Called by the constructor when creating new records.
* *
* @uses DataExtension->populateDefaults() * @uses DataExtension::populateDefaults()
* @return DataObject $this * @return DataObject $this
*/ */
public function populateDefaults() public function populateDefaults()
@ -1560,7 +1560,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* - $this->onBeforeWrite() gets called beforehand. * - $this->onBeforeWrite() gets called beforehand.
* - Extensions such as Versioned will ammend the database-write to ensure that a version is saved. * - Extensions such as Versioned will ammend the database-write to ensure that a version is saved.
* *
* @uses DataExtension->augmentWrite() * @uses DataExtension::augmentWrite()
* *
* @param boolean $showDebug Show debugging information * @param boolean $showDebug Show debugging information
* @param boolean $forceInsert Run INSERT command rather than UPDATE, even if record already exists * @param boolean $forceInsert Run INSERT command rather than UPDATE, even if record already exists
@ -1733,7 +1733,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* Delete this data object. * Delete this data object.
* $this->onBeforeDelete() gets called. * $this->onBeforeDelete() gets called.
* Note that in Versioned objects, both Stage and Live will be deleted. * Note that in Versioned objects, both Stage and Live will be deleted.
* @uses DataExtension->augmentSQL() * @uses DataExtension::augmentSQL()
*/ */
public function delete() public function delete()
{ {
@ -3490,7 +3490,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
/** /**
* @see $sourceQueryParams * @see $sourceQueryParams
* @param array * @param array $array
*/ */
public function setSourceQueryParams($array) public function setSourceQueryParams($array)
{ {
@ -3525,7 +3525,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
/** /**
* Check the database schema and update it as necessary. * Check the database schema and update it as necessary.
* *
* @uses DataExtension->augmentDatabase() * @uses DataExtension::augmentDatabase()
*/ */
public function requireTable() public function requireTable()
{ {
@ -3607,7 +3607,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* this to add default records when the database is built, but make sure you * this to add default records when the database is built, but make sure you
* call parent::requireDefaultRecords(). * call parent::requireDefaultRecords().
* *
* @uses DataExtension->requireDefaultRecords() * @uses DataExtension::requireDefaultRecords()
*/ */
public function requireDefaultRecords() public function requireDefaultRecords()
{ {

View File

@ -167,7 +167,7 @@ class DBEnum extends DBString
* Returns the values of this enum as an array, suitable for insertion into * Returns the values of this enum as an array, suitable for insertion into
* a {@link DropdownField} * a {@link DropdownField}
* *
* @param boolean * @param bool $hasEmpty
* *
* @return array * @return array
*/ */

View File

@ -27,8 +27,8 @@ interface DBIndexable
/** /**
* Set the desired index type to use * Set the desired index type to use
* *
* @param string|bool $indexType Either of the types listed in {@link SilverStripe\ORM\FieldType\DBIndexable}, or * @param string|bool $type Either of the types listed in {@link SilverStripe\ORM\FieldType\DBIndexable}, or
* boolean true to indicate that the default index type should be used. * boolean true to indicate that the default index type should be used.
* @return $this * @return $this
* @throws \InvalidArgumentException If $type is not one of TYPE_INDEX, TYPE_UNIQUE or TYPE_FULLTEXT * @throws \InvalidArgumentException If $type is not one of TYPE_INDEX, TYPE_UNIQUE or TYPE_FULLTEXT
*/ */

View File

@ -19,7 +19,7 @@ class DBMoney extends DBComposite
protected $locale = null; protected $locale = null;
/** /**
* @param array * @var array<string,string>
*/ */
private static $composite_db = [ private static $composite_db = [
'Currency' => 'Varchar(3)', 'Currency' => 'Varchar(3)',

View File

@ -82,7 +82,7 @@ abstract class DBString extends DBField
/** /**
* (non-PHPdoc) * (non-PHPdoc)
* @see core/model/fieldtypes/DBField#exists() * @see DBField::exists()
*/ */
public function exists() public function exists()
{ {

View File

@ -8,7 +8,9 @@ namespace SilverStripe\ORM;
* All methods in this interface are immutable - they should return new instances with the filter * All methods in this interface are immutable - they should return new instances with the filter
* applied, rather than applying the filter in place * applied, rather than applying the filter in place
* *
* @see SS_List, Sortable, Limitable * @see SS_List
* @see Sortable
* @see Limitable
*/ */
interface Filterable extends SS_List interface Filterable extends SS_List
{ {

View File

@ -224,7 +224,7 @@ abstract class SearchFilter
} }
/** /**
* @param String * @param string $name
*/ */
public function setName($name) public function setName($name)
{ {
@ -243,7 +243,7 @@ abstract class SearchFilter
} }
/** /**
* @param String * @param string $name
*/ */
public function setFullName($name) public function setFullName($name)
{ {

View File

@ -18,7 +18,7 @@ class HasManyList extends RelationList
/** /**
* Create a new HasManyList object. * Create a new HasManyList object.
* Generation of the appropriate record set is left up to the caller, using the normal * Generation of the appropriate record set is left up to the caller, using the normal
* {@link DataList} methods. Addition arguments are used to support {@@link add()} * {@link DataList} methods. Addition arguments are used to support {@link add()}
* and {@link remove()} methods. * and {@link remove()} methods.
* *
* @param string $dataClass The class of the DataObjects that this will list. * @param string $dataClass The class of the DataObjects that this will list.

View File

@ -344,8 +344,7 @@ class Hierarchy extends DataExtension
* a list of record IDs, for more efficient database querying. If $idList * a list of record IDs, for more efficient database querying. If $idList
* is null, then every record will be pre-cached. * is null, then every record will be pre-cached.
* *
* @param string $class * @param string $baseClass
* @param string $stage
* @param array $idList * @param array $idList
*/ */
public static function prepopulate_numchildren_cache($baseClass, $idList = null) public static function prepopulate_numchildren_cache($baseClass, $idList = null)

View File

@ -8,7 +8,9 @@ namespace SilverStripe\ORM;
* All methods in this interface are immutable - they should return new instances with the limit * All methods in this interface are immutable - they should return new instances with the limit
* applied, rather than applying the limit in place * applied, rather than applying the limit in place
* *
* @see SS_List, Sortable, Filterable * @see SS_List
* @see Sortable
* @see Filterable
*/ */
interface Limitable extends SS_List interface Limitable extends SS_List
{ {

View File

@ -49,7 +49,7 @@ class ManyManyList extends RelationList
* *
* Generation of the appropriate record set is left up to the caller, using * Generation of the appropriate record set is left up to the caller, using
* the normal {@link DataList} methods. Addition arguments are used to * the normal {@link DataList} methods. Addition arguments are used to
* support {@@link add()} and {@link remove()} methods. * support {@link add()} and {@link remove()} methods.
* *
* @param string $dataClass The class of the DataObjects that this will list. * @param string $dataClass The class of the DataObjects that this will list.
* @param string $joinTable The name of the table whose entries define the content of this many_many relation. * @param string $joinTable The name of the table whose entries define the content of this many_many relation.

View File

@ -29,7 +29,7 @@ class PaginatedList extends ListDecorator
* *
* @param SS_List $list The list to paginate. The getRange method will * @param SS_List $list The list to paginate. The getRange method will
* be used to get the subset of objects to show. * be used to get the subset of objects to show.
* @param array|ArrayAccess Either a map of request parameters or * @param array|ArrayAccess $request Either a map of request parameters or
* request object that the pagination offset is read from. * request object that the pagination offset is read from.
* @throws Exception * @throws Exception
*/ */
@ -72,7 +72,7 @@ class PaginatedList extends ListDecorator
/** /**
* Returns the number of items displayed per page. This defaults to 10. * Returns the number of items displayed per page. This defaults to 10.
* *
* @return int. * @return int
*/ */
public function getPageLength() public function getPageLength()
{ {
@ -511,7 +511,7 @@ class PaginatedList extends ListDecorator
/** /**
* Set the request object for this list * Set the request object for this list
* *
* @param HTTPRequest|ArrayAccess * @param HTTPRequest|ArrayAccess $request
*/ */
public function setRequest($request) public function setRequest($request)
{ {

View File

@ -133,7 +133,7 @@ abstract class SQLConditionalExpression extends SQLExpression
* @param int $order A numerical index to control the order that joins are added to the query; lower order values * @param int $order A numerical index to control the order that joins are added to the query; lower order values
* will cause the query to appear first. The default is 20, and joins created automatically by the * will cause the query to appear first. The default is 20, and joins created automatically by the
* ORM have a value of 10. * ORM have a value of 10.
* @param array $parameters Any additional parameters if the join is a parameterised subquery * @param array $parameters Any additional parameters if the join is a parameterized subquery
* @return $this Self reference * @return $this Self reference
*/ */
public function addLeftJoin($table, $onPredicate, $tableAlias = '', $order = 20, $parameters = []) public function addLeftJoin($table, $onPredicate, $tableAlias = '', $order = 20, $parameters = [])
@ -161,7 +161,7 @@ abstract class SQLConditionalExpression extends SQLExpression
* @param int $order A numerical index to control the order that joins are added to the query; lower order * @param int $order A numerical index to control the order that joins are added to the query; lower order
* values will cause the query to appear first. The default is 20, and joins created automatically by the * values will cause the query to appear first. The default is 20, and joins created automatically by the
* ORM have a value of 10. * ORM have a value of 10.
* @param array $parameters Any additional parameters if the join is a parameterised subquery * @param array $parameters Any additional parameters if the join is a parameterized subquery
* @return $this Self reference * @return $this Self reference
*/ */
public function addInnerJoin($table, $onPredicate, $tableAlias = null, $order = 20, $parameters = []) public function addInnerJoin($table, $onPredicate, $tableAlias = null, $order = 20, $parameters = [])
@ -256,7 +256,7 @@ abstract class SQLConditionalExpression extends SQLExpression
} }
/** /**
* Retrieves the finalised list of joins * Retrieves the finalized list of joins
* *
* @todo This part of the code could be simplified * @todo This part of the code could be simplified
* *
@ -374,7 +374,7 @@ abstract class SQLConditionalExpression extends SQLExpression
* *
* @see http://stackoverflow.com/q/4353739/139301 * @see http://stackoverflow.com/q/4353739/139301
* *
* @param array &$array The array to sort * @param array $array The array to sort (by reference)
* @param callable|string $cmpFunction The function to use for comparison * @param callable|string $cmpFunction The function to use for comparison
*/ */
protected function mergesort(&$array, $cmpFunction = 'strcmp') protected function mergesort(&$array, $cmpFunction = 'strcmp')
@ -426,8 +426,7 @@ abstract class SQLConditionalExpression extends SQLExpression
* *
* @see SQLConditionalExpression::addWhere() for syntax examples * @see SQLConditionalExpression::addWhere() for syntax examples
* *
* @param mixed $where Predicate(s) to set, as escaped SQL statements or paramaterised queries * @param mixed ...$where Predicate(s) to set, as escaped SQL statements or parameterized queries
* @param mixed $where,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function setWhere($where) public function setWhere($where)
@ -440,7 +439,7 @@ abstract class SQLConditionalExpression extends SQLExpression
/** /**
* Adds a WHERE clause. * Adds a WHERE clause.
* *
* Note that the database will execute any parameterised queries using * Note that the database will execute any parameterized queries using
* prepared statements whenever available. * prepared statements whenever available.
* *
* There are several different ways of doing this. * There are several different ways of doing this.
@ -513,8 +512,7 @@ abstract class SQLConditionalExpression extends SQLExpression
* )); * ));
* </code> * </code>
* *
* @param mixed $where Predicate(s) to set, as escaped SQL statements or paramaterised queries * @param mixed ...$where Predicate(s) to set, as escaped SQL statements or parameterized queries
* @param mixed $where,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function addWhere($where) public function addWhere($where)
@ -530,8 +528,7 @@ abstract class SQLConditionalExpression extends SQLExpression
/** /**
* @see SQLConditionalExpression::addWhere() * @see SQLConditionalExpression::addWhere()
* *
* @param mixed $filters Predicate(s) to set, as escaped SQL statements or paramaterised queries * @param mixed ...$filters Predicate(s) to set, as escaped SQL statements or parameterized queries
* @param mixed $filters,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function setWhereAny($filters) public function setWhereAny($filters)
@ -545,8 +542,7 @@ abstract class SQLConditionalExpression extends SQLExpression
/** /**
* @see SQLConditionalExpression::addWhere() * @see SQLConditionalExpression::addWhere()
* *
* @param mixed $filters Predicate(s) to set, as escaped SQL statements or paramaterised queries * @param mixed ...$filters Predicate(s) to set, as escaped SQL statements or parameterized queries
* @param mixed $filters,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function addWhereAny($filters) public function addWhereAny($filters)
@ -583,19 +579,19 @@ abstract class SQLConditionalExpression extends SQLExpression
/** /**
* Given a key / value pair, extract the predicate and any potential paramaters * Given a key / value pair, extract the predicate and any potential paramaters
* in a format suitable for storing internally as a list of paramaterised conditions. * in a format suitable for storing internally as a list of parameterized conditions.
* *
* @param string|integer $key The left hand (key index) of this condition. * @param string|integer $key The left hand (key index) of this condition.
* Could be the predicate or an integer index. * Could be the predicate or an integer index.
* @param mixed $value The The right hand (array value) of this condition. * @param mixed $value The The right hand (array value) of this condition.
* Could be the predicate (if non-paramaterised), or the parameter(s). Could also be * Could be the predicate (if non-parameterized), or the parameter(s). Could also be
* an array containing a nested condition in the similar format this function outputs. * an array containing a nested condition in the similar format this function outputs.
* @return array|SQLConditionGroup A single item array in the format * @return array|SQLConditionGroup A single item array in the format
* array($predicate => array($parameters)), unless it's a SQLConditionGroup * array($predicate => array($parameters)), unless it's a SQLConditionGroup
*/ */
protected function parsePredicate($key, $value) protected function parsePredicate($key, $value)
{ {
// If a string key is given then presume this is a paramaterised condition // If a string key is given then presume this is a parameterized condition
if ($value instanceof SQLConditionGroup) { if ($value instanceof SQLConditionGroup) {
return $value; return $value;
} elseif (is_string($key)) { } elseif (is_string($key)) {
@ -631,14 +627,14 @@ abstract class SQLConditionalExpression extends SQLExpression
return $this->parsePredicate($key, $pairValue); return $this->parsePredicate($key, $pairValue);
} }
} else { } else {
// Non-paramaterised condition // Non-parameterized condition
return [$value => []]; return [$value => []];
} }
} }
/** /**
* Given a list of conditions in any user-acceptable format, convert this * Given a list of conditions in any user-acceptable format, convert this
* to an array of paramaterised predicates suitable for merging with $this->where. * to an array of parameterized predicates suitable for merging with $this->where.
* *
* Normalised predicates are in the below format, in order to avoid key collisions. * Normalised predicates are in the below format, in order to avoid key collisions.
* *
@ -691,7 +687,7 @@ abstract class SQLConditionalExpression extends SQLExpression
*/ */
public function splitQueryParameters($conditions, &$predicates, &$parameters) public function splitQueryParameters($conditions, &$predicates, &$parameters)
{ {
// Merge all filters with paramaterised queries // Merge all filters with parameterized queries
$predicates = []; $predicates = [];
$parameters = []; $parameters = [];
foreach ($conditions as $condition) { foreach ($conditions as $condition) {
@ -742,7 +738,7 @@ abstract class SQLConditionalExpression extends SQLExpression
{ {
$regexp = '/^(.*\.)?("|`)?[a-zA-Z]+ID("|`)?\s?(=|IN)/'; $regexp = '/^(.*\.)?("|`)?[a-zA-Z]+ID("|`)?\s?(=|IN)/';
// @todo - Test this works with paramaterised queries // @todo - Test this works with parameterized queries
foreach ($this->getWhereParameterised($parameters) as $predicate) { foreach ($this->getWhereParameterised($parameters) as $predicate) {
if (preg_match($regexp, $predicate)) { if (preg_match($regexp, $predicate)) {
return true; return true;

View File

@ -14,7 +14,7 @@ class SQLInsert extends SQLExpression implements SQLWriteExpression
/** /**
* List of rows to be inserted * List of rows to be inserted
* *
* @var array[SQLAssignmentRow] * @var SQLAssignmentRow[]
*/ */
protected $rows = []; protected $rows = [];

View File

@ -489,8 +489,7 @@ class SQLSelect extends SQLConditionalExpression
* *
* @see SQLSelect::addWhere() for syntax examples * @see SQLSelect::addWhere() for syntax examples
* *
* @param mixed $having Predicate(s) to set, as escaped SQL statements or parameterised queries * @param mixed ...$having Predicate(s) to set, as escaped SQL statements or parameterised queries
* @param mixed $having,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function setHaving($having) public function setHaving($having)
@ -505,8 +504,7 @@ class SQLSelect extends SQLConditionalExpression
* *
* @see SQLSelect::addWhere() for syntax examples * @see SQLSelect::addWhere() for syntax examples
* *
* @param mixed $having Predicate(s) to set, as escaped SQL statements or parameterised queries * @param mixed ...$having Predicate(s) to set, as escaped SQL statements or parameterised queries
* @param mixed $having,... Unlimited additional predicates
* @return $this Self reference * @return $this Self reference
*/ */
public function addHaving($having) public function addHaving($having)

View File

@ -8,7 +8,9 @@ namespace SilverStripe\ORM;
* All methods in this interface are immutable - they should return new instances with the sort * All methods in this interface are immutable - they should return new instances with the sort
* applied, rather than applying the sort in place * applied, rather than applying the sort in place
* *
* @see SS_List, Filterable, Limitable * @see SS_List
* @see Filterable
* @see Limitable
*/ */
interface Sortable extends SS_List interface Sortable extends SS_List
{ {

View File

@ -176,7 +176,6 @@ class UnsavedRelationList extends ArrayList implements Relation
* Remove the items from this list with the given IDs * Remove the items from this list with the given IDs
* *
* @param array $items * @param array $items
* @param array $items
* @return $this * @return $this
*/ */
public function removeMany($items) public function removeMany($items)

View File

@ -359,7 +359,7 @@ class Storage
* *
* @param string $url Success URL * @param string $url Success URL
* *
* @return $this; * @return $this
*/ */
public function setSuccessUrl($url) public function setSuccessUrl($url)
{ {
@ -382,7 +382,7 @@ class Storage
* *
* @param string $url Failure URL * @param string $url Failure URL
* *
* @return $this; * @return $this
*/ */
public function setFailureUrl($url) public function setFailureUrl($url)
{ {

View File

@ -476,7 +476,7 @@ class Group extends DataObject
/** /**
* Overloaded to ensure the code is always descent. * Overloaded to ensure the code is always descent.
* *
* @param string * @param string $val
*/ */
public function setCode($val) public function setCode($val)
{ {

View File

@ -41,7 +41,7 @@ class InheritedPermissionFlusher extends DataExtension implements Flushable
} }
/** /**
* @param MemberCacheFlusher[] * @param MemberCacheFlusher[] $services
* @throws InvalidArgumentException * @throws InvalidArgumentException
* @return $this * @return $this
*/ */

View File

@ -1103,7 +1103,7 @@ class Member extends DataObject
/** /**
* @param array $columns Column names on the Member record to show in {@link getTitle()}. * @param array $columns Column names on the Member record to show in {@link getTitle()}.
* @param String $sep Separator * @param string $sep Separator
*/ */
public static function set_title_columns($columns, $sep = ' ') public static function set_title_columns($columns, $sep = ' ')
{ {

View File

@ -13,8 +13,8 @@ class NullSecurityToken extends SecurityToken
{ {
/** /**
* @param String * @param string $compare
* @return boolean * @return bool
*/ */
public function check($compare) public function check($compare)
{ {
@ -43,8 +43,8 @@ class NullSecurityToken extends SecurityToken
} }
/** /**
* @param String $url * @param string $url
* @return String * @return string
*/ */
public function addToUrl($url) public function addToUrl($url)
{ {
@ -52,7 +52,7 @@ class NullSecurityToken extends SecurityToken
} }
/** /**
* @return String * @return string
*/ */
public function getValue() public function getValue()
{ {
@ -60,7 +60,7 @@ class NullSecurityToken extends SecurityToken
} }
/** /**
* @param String $val * @param string $val
*/ */
public function setValue($val) public function setValue($val)
{ {
@ -68,7 +68,7 @@ class NullSecurityToken extends SecurityToken
} }
/** /**
* @return String * @return string
*/ */
public function generate() public function generate()
{ {

View File

@ -32,7 +32,7 @@ abstract class PasswordEncryptor
} }
/** /**
* @param String $algorithm * @param string $algorithm
* @return PasswordEncryptor * @return PasswordEncryptor
* @throws PasswordEncryptor_NotFoundException * @throws PasswordEncryptor_NotFoundException
*/ */
@ -65,8 +65,8 @@ abstract class PasswordEncryptor
* Return a string value stored in the {@link Member->Password} property. * Return a string value stored in the {@link Member->Password} property.
* The password should be hashed with {@link salt()} if applicable. * The password should be hashed with {@link salt()} if applicable.
* *
* @param String $password Cleartext password to be hashed * @param string $password Cleartext password to be hashed
* @param String $salt (Optional) * @param string $salt (Optional)
* @param Member $member (Optional) * @param Member $member (Optional)
* @return String Maximum of 512 characters. * @return String Maximum of 512 characters.
*/ */

View File

@ -238,7 +238,6 @@ class PasswordExpirationMiddleware implements HTTPMiddleware
* Allow the current request to be finished without password expiration check * Allow the current request to be finished without password expiration check
* *
* @param Session $session Session where we persist the redirect URL * @param Session $session Session where we persist the redirect URL
* @param string $url change password form address
*/ */
public static function allowCurrentRequest(Session $session) public static function allowCurrentRequest(Session $session)
{ {

View File

@ -223,7 +223,7 @@ class PasswordValidator
} }
/** /**
* @param String $password * @param string $password
* @param Member $member * @param Member $member
* @return ValidationResult * @return ValidationResult
*/ */

View File

@ -160,7 +160,7 @@ class Permission extends DataObject implements TemplateGlobalProvider, Resettabl
/** /**
* Check that the given member has the given permission. * Check that the given member has the given permission.
* *
* @param int|Member memberID The ID of the member to check. Leave blank for the current member. * @param int|Member $member The ID of the member to check. Leave blank for the current member.
* Alternatively you can use a member object. * Alternatively you can use a member object.
* @param string|array $code Code of the permission to check (case-sensitive) * @param string|array $code Code of the permission to check (case-sensitive)
* @param string $arg Optional argument (e.g. a permissions for a specific page) * @param string $arg Optional argument (e.g. a permissions for a specific page)

View File

@ -39,10 +39,10 @@ class PermissionCheckboxSetField extends FormField
protected $source = null; protected $source = null;
/** /**
* @param String $name * @param string $name
* @param String $title * @param string $title
* @param String $managedClass * @param string $managedClass
* @param String $filterField * @param string $filterField
* @param Group|SS_List $records One or more {@link Group} or {@link PermissionRole} records * @param Group|SS_List $records One or more {@link Group} or {@link PermissionRole} records
* used to determine permission checkboxes. * used to determine permission checkboxes.
* Caution: saveInto() can only be used with a single record, all inherited permissions will be marked readonly. * Caution: saveInto() can only be used with a single record, all inherited permissions will be marked readonly.

View File

@ -611,7 +611,7 @@ class Security extends Controller implements TemplateGlobalProvider
/** /**
* Get the HTML Content for the $Content area during login * Get the HTML Content for the $Content area during login
* *
* @param string &$messageType Type of message, if available, passed back to caller * @param string $messageType Type of message, if available, passed back to caller (by reference)
* @return string Message in HTML format * @return string Message in HTML format
*/ */
protected function getSessionMessage(&$messageType = null) protected function getSessionMessage(&$messageType = null)

View File

@ -39,7 +39,7 @@ class ArrayData extends ViewableData
} elseif (count($value) === 0) { } elseif (count($value) === 0) {
$this->array = []; $this->array = [];
} else { } else {
$message = 'ArrayData constructor expects an object or associative array, $message = 'ArrayData constructor expects an object or associative array,
enumerated array passed instead. Did you mean to use ArrayList?'; enumerated array passed instead. Did you mean to use ArrayList?';
throw new InvalidArgumentException($message); throw new InvalidArgumentException($message);
} }
@ -112,7 +112,7 @@ class ArrayData extends ViewableData
/** /**
* Converts an associative array to a simple object * Converts an associative array to a simple object
* *
* @param array * @param array $arr
* @return stdClass $obj * @return stdClass $obj
*/ */
public static function array_to_object($arr = null) public static function array_to_object($arr = null)

View File

@ -37,7 +37,7 @@ class EmbedResource implements Embeddable
protected $dispatcher; protected $dispatcher;
/** /**
* @param string @url * @param string $url
*/ */
public function __construct($url) public function __construct($url)
{ {

View File

@ -39,7 +39,7 @@ abstract class HTMLCleaner
} }
/** /**
* @param array * @param array $config
*/ */
public function setConfig($config) public function setConfig($config)
{ {

View File

@ -146,7 +146,7 @@ class URLSegmentFilter implements FilterInterface
} }
/** /**
* @param boolean * @param bool $bool
*/ */
public function setAllowMultibyte($bool) public function setAllowMultibyte($bool)
{ {

View File

@ -72,7 +72,7 @@ class Requirements implements Flushable
* filemtime. This has the benefit of allowing the browser to cache the URL infinitely, * filemtime. This has the benefit of allowing the browser to cache the URL infinitely,
* while automatically busting this cache every time the file is changed. * while automatically busting this cache every time the file is changed.
* *
* @param bool * @param bool $var
*/ */
public static function set_suffix_requirements($var) public static function set_suffix_requirements($var)
{ {
@ -449,7 +449,7 @@ class Requirements implements Flushable
* Set whether you want to write the JS to the body of the page rather than at the end of the * Set whether you want to write the JS to the body of the page rather than at the end of the
* head tag. * head tag.
* *
* @param bool * @param bool $var
*/ */
public static function set_write_js_to_body($var) public static function set_write_js_to_body($var)
{ {

View File

@ -306,7 +306,7 @@ class Requirements_Backend
* filemtime. This has the benefit of allowing the browser to cache the URL infinitely, * filemtime. This has the benefit of allowing the browser to cache the URL infinitely,
* while automatically busting this cache every time the file is changed. * while automatically busting this cache every time the file is changed.
* *
* @param bool * @param bool $var
*/ */
public function setSuffixRequirements($var) public function setSuffixRequirements($var)
{ {
@ -327,7 +327,7 @@ class Requirements_Backend
* Set whether you want to write the JS to the body of the page rather than at the end of the * Set whether you want to write the JS to the body of the page rather than at the end of the
* head tag. * head tag.
* *
* @param bool * @param bool $var
* @return $this * @return $this
*/ */
public function setWriteJavascriptToBody($var) public function setWriteJavascriptToBody($var)
@ -350,7 +350,7 @@ class Requirements_Backend
/** /**
* Forces the JavaScript requirements to the end of the body, right before the closing tag * Forces the JavaScript requirements to the end of the body, right before the closing tag
* *
* @param bool * @param bool $var
* @return $this * @return $this
*/ */
public function setForceJSToBottom($var) public function setForceJSToBottom($var)

View File

@ -1186,7 +1186,7 @@ class SSTemplateParser extends Parser implements TemplateParser
$matchrule = "QuotedString"; $result = $this->construct($matchrule, $matchrule, null); $matchrule = "QuotedString"; $result = $this->construct($matchrule, $matchrule, null);
$_154 = NULL; $_154 = NULL;
do { do {
$stack[] = $result; $result = $this->construct( $matchrule, "q" ); $stack[] = $result; $result = $this->construct( $matchrule, "q" );
if (( $subres = $this->rx( '/[\'"]/' ) ) !== FALSE) { if (( $subres = $this->rx( '/[\'"]/' ) ) !== FALSE) {
$result["text"] .= $subres; $result["text"] .= $subres;
$subres = $result; $result = array_pop($stack); $subres = $result; $result = array_pop($stack);
@ -1196,7 +1196,7 @@ class SSTemplateParser extends Parser implements TemplateParser
$result = array_pop($stack); $result = array_pop($stack);
$_154 = FALSE; break; $_154 = FALSE; break;
} }
$stack[] = $result; $result = $this->construct( $matchrule, "String" ); $stack[] = $result; $result = $this->construct( $matchrule, "String" );
if (( $subres = $this->rx( '/ (\\\\\\\\ | \\\\. | [^'.$this->expression($result, $stack, 'q').'\\\\])* /' ) ) !== FALSE) { if (( $subres = $this->rx( '/ (\\\\\\\\ | \\\\. | [^'.$this->expression($result, $stack, 'q').'\\\\])* /' ) ) !== FALSE) {
$result["text"] .= $subres; $result["text"] .= $subres;
$subres = $result; $result = array_pop($stack); $subres = $result; $result = array_pop($stack);
@ -1549,7 +1549,7 @@ class SSTemplateParser extends Parser implements TemplateParser
$pos_211 = $this->pos; $pos_211 = $this->pos;
$_210 = NULL; $_210 = NULL;
do { do {
$stack[] = $result; $result = $this->construct( $matchrule, "Not" ); $stack[] = $result; $result = $this->construct( $matchrule, "Not" );
if (( $subres = $this->literal( 'not' ) ) !== FALSE) { if (( $subres = $this->literal( 'not' ) ) !== FALSE) {
$result["text"] .= $subres; $result["text"] .= $subres;
$subres = $result; $result = array_pop($stack); $subres = $result; $result = array_pop($stack);
@ -1944,7 +1944,7 @@ class SSTemplateParser extends Parser implements TemplateParser
else { $_286 = FALSE; break; } else { $_286 = FALSE; break; }
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
else { $_286 = FALSE; break; } else { $_286 = FALSE; break; }
$stack[] = $result; $result = $this->construct( $matchrule, "Call" ); $stack[] = $result; $result = $this->construct( $matchrule, "Call" );
$_282 = NULL; $_282 = NULL;
do { do {
$matcher = 'match_'.'Word'; $key = $matcher; $pos = $this->pos; $matcher = 'match_'.'Word'; $key = $matcher; $pos = $this->pos;
@ -2449,7 +2449,7 @@ class SSTemplateParser extends Parser implements TemplateParser
$_379 = NULL; $_379 = NULL;
do { do {
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
$stack[] = $result; $result = $this->construct( $matchrule, "Conditional" ); $stack[] = $result; $result = $this->construct( $matchrule, "Conditional" );
$_375 = NULL; $_375 = NULL;
do { do {
$_373 = NULL; $_373 = NULL;
@ -2875,7 +2875,7 @@ class SSTemplateParser extends Parser implements TemplateParser
if (( $subres = $this->literal( '<%' ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->literal( '<%' ) ) !== FALSE) { $result["text"] .= $subres; }
else { $_511 = FALSE; break; } else { $_511 = FALSE; break; }
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
$stack[] = $result; $result = $this->construct( $matchrule, "CacheTag" ); $stack[] = $result; $result = $this->construct( $matchrule, "CacheTag" );
$_464 = NULL; $_464 = NULL;
do { do {
$_462 = NULL; $_462 = NULL;
@ -2934,7 +2934,7 @@ class SSTemplateParser extends Parser implements TemplateParser
$_480 = NULL; $_480 = NULL;
do { do {
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
$stack[] = $result; $result = $this->construct( $matchrule, "Conditional" ); $stack[] = $result; $result = $this->construct( $matchrule, "Conditional" );
$_476 = NULL; $_476 = NULL;
do { do {
$_474 = NULL; $_474 = NULL;
@ -3874,7 +3874,7 @@ class SSTemplateParser extends Parser implements TemplateParser
unset( $pos_641 ); unset( $pos_641 );
} }
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
$stack[] = $result; $result = $this->construct( $matchrule, "Zap" ); $stack[] = $result; $result = $this->construct( $matchrule, "Zap" );
if (( $subres = $this->literal( '%>' ) ) !== FALSE) { if (( $subres = $this->literal( '%>' ) ) !== FALSE) {
$result["text"] .= $subres; $result["text"] .= $subres;
$subres = $result; $result = array_pop($stack); $subres = $result; $result = array_pop($stack);
@ -4284,7 +4284,7 @@ class SSTemplateParser extends Parser implements TemplateParser
if (( $subres = $this->literal( '<%' ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->literal( '<%' ) ) !== FALSE) { $result["text"] .= $subres; }
else { $_699 = FALSE; break; } else { $_699 = FALSE; break; }
if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->whitespace( ) ) !== FALSE) { $result["text"] .= $subres; }
$stack[] = $result; $result = $this->construct( $matchrule, "Tag" ); $stack[] = $result; $result = $this->construct( $matchrule, "Tag" );
$_693 = NULL; $_693 = NULL;
do { do {
if (( $subres = $this->literal( 'end_' ) ) !== FALSE) { $result["text"] .= $subres; } if (( $subres = $this->literal( 'end_' ) ) !== FALSE) { $result["text"] .= $subres; }
@ -5071,6 +5071,7 @@ EOC;
/** /**
* @param string $code * @param string $code
* @param string $templateName
* @return string $code * @return string $code
*/ */
protected function includeDebuggingComments($code, $templateName) protected function includeDebuggingComments($code, $templateName)

View File

@ -561,7 +561,7 @@ class SSViewer implements Flushable
/** /**
* Flag whether to include the requirements in this response. * Flag whether to include the requirements in this response.
* *
* @param bool * @param bool $incl
*/ */
public function includeRequirements($incl = true) public function includeRequirements($incl = true)
{ {

View File

@ -335,7 +335,7 @@ class SSViewer_Scope
} }
/** /**
* @param array * @param array $stack
*/ */
protected function setItemStack(array $stack) protected function setItemStack(array $stack)
{ {

View File

@ -158,7 +158,7 @@ class i18nTextCollector
* i18n feature, parse the _t() calls and write the resultant files * i18n feature, parse the _t() calls and write the resultant files
* in the lang folder of each module. * in the lang folder of each module.
* *
* @uses DataObject->collectI18nStatics() * @uses DataObject::collectI18nStatics()
* *
* @param array $restrictToModules * @param array $restrictToModules
* @param bool $mergeWithExisting Merge new master strings with existing * @param bool $mergeWithExisting Merge new master strings with existing

View File

@ -148,7 +148,7 @@ class i18n implements TemplateGlobalProvider
* @param string $entity Entity that identifies the string. It must be in the form * @param string $entity Entity that identifies the string. It must be in the form
* "Namespace.Entity" where Namespace will be usually the class name where this * "Namespace.Entity" where Namespace will be usually the class name where this
* string is used and Entity identifies the string inside the namespace. * string is used and Entity identifies the string inside the namespace.
* @param mixed $arg,... Additional arguments are parsed as such: * @param mixed $arg Additional arguments are parsed as such:
* - Next string argument is a default. Pass in a `|` pipe-delimited value with `{count}` * - Next string argument is a default. Pass in a `|` pipe-delimited value with `{count}`
* to do pluralisation. * to do pluralisation.
* - Any other string argument after default is context for i18nTextCollector * - Any other string argument after default is context for i18nTextCollector

View File

@ -18,7 +18,7 @@ use SilverStripe\i18n\TextCollection\i18nTextCollector;
* Classes must be able to be constructed without mandatory arguments, otherwise * Classes must be able to be constructed without mandatory arguments, otherwise
* this interface will have no effect. * this interface will have no effect.
* *
* @uses i18nTextCollector->collectFromEntityProviders() * @uses i18nTextCollector::collectFromEntityProviders()
*/ */
interface i18nEntityProvider interface i18nEntityProvider
{ {

View File

@ -49,7 +49,7 @@ function project()
* @param string $entity Entity that identifies the string. It must be in the form * @param string $entity Entity that identifies the string. It must be in the form
* "Namespace.Entity" where Namespace will be usually the class name where this * "Namespace.Entity" where Namespace will be usually the class name where this
* string is used and Entity identifies the string inside the namespace. * string is used and Entity identifies the string inside the namespace.
* @param mixed $arg,... Additional arguments are parsed as such: * @param mixed $arg Additional arguments are parsed as such:
* - Next string argument is a default. Pass in a `|` pipe-delimeted value with `{count}` * - Next string argument is a default. Pass in a `|` pipe-delimeted value with `{count}`
* to do pluralisation. * to do pluralisation.
* - Any other string argument after default is context for i18nTextCollector * - Any other string argument after default is context for i18nTextCollector

View File

@ -382,9 +382,9 @@ EOT;
/** /**
* @param String $html [description] * @param string $html [description]
* @param array $nodes Breadcrumb path as array * @param array $nodes Breadcrumb path as array
* @param String $message * @param string $message
*/ */
protected function assertTreeContains($html, $nodes, $message = null) protected function assertTreeContains($html, $nodes, $message = null)
{ {
@ -398,9 +398,9 @@ EOT;
} }
/** /**
* @param String $html [description] * @param string $html [description]
* @param array $nodes Breadcrumb path as array * @param array $nodes Breadcrumb path as array
* @param String $message * @param string $message
*/ */
protected function assertTreeNotContains($html, $nodes, $message = null) protected function assertTreeNotContains($html, $nodes, $message = null)
{ {