@@ -379,7 +379,7 @@ discard block |
||
379 | 379 | /** |
380 | 380 | * Return the IDs of all the marked nodes. |
381 | 381 | * |
382 | - * @return array |
|
382 | + * @return integer[] |
|
383 | 383 | */ |
384 | 384 | public function markedNodeIDs() { |
385 | 385 | return array_keys($this->markedNodes); |
@@ -756,7 +756,7 @@ discard block |
||
756 | 756 | * Get the next node in the tree of the type. If there is no instance of the className descended from this node, |
757 | 757 | * then search the parents. |
758 | 758 | * @param string $className Class name of the node to find. |
759 | - * @param string|int $root ID/ClassName of the node to limit the search to |
|
759 | + * @param integer $root ID/ClassName of the node to limit the search to |
|
760 | 760 | * @param DataObject $afterNode Used for recursive calls to this function |
761 | 761 | * @return DataObject |
762 | 762 | */ |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | /** |
25 | 25 | * Modify method visibility to public for testing |
26 | 26 | * |
27 | - * @param mixed $errors |
|
27 | + * @param string $errors |
|
28 | 28 | */ |
29 | 29 | public function setDisplayErrors($errors) |
30 | 30 | { |
@@ -33,6 +33,10 @@ discard block |
||
33 | 33 | } |
34 | 34 | |
35 | 35 | // Change function visibility to be testable directly |
36 | + |
|
37 | + /** |
|
38 | + * @param string $memstring |
|
39 | + */ |
|
36 | 40 | public function translateMemstring($memstring) { |
37 | 41 | return parent::translateMemstring($memstring); |
38 | 42 | } |
@@ -191,7 +191,7 @@ discard block |
||
191 | 191 | * |
192 | 192 | * TODO: Pass $response object to ->outputToBrowser() to loosen dependence on global state for easier testing/prototyping so dev can inject custom SS_HTTPResponse instance. |
193 | 193 | * |
194 | - * @return HTMLText |
|
194 | + * @return DBField |
|
195 | 195 | */ |
196 | 196 | public function outputToBrowser() { |
197 | 197 | $prevState = Config::inst()->get('SSViewer', 'source_file_comments'); |
@@ -222,6 +222,7 @@ discard block |
||
222 | 222 | * via the standard template inclusion process. |
223 | 223 | * |
224 | 224 | * @param string |
225 | + * @param string $template |
|
225 | 226 | */ |
226 | 227 | public function setTemplate($template) { |
227 | 228 | $this->template = $template; |
@@ -318,6 +319,7 @@ discard block |
||
318 | 319 | /** |
319 | 320 | * Return the named field as an obj() call from $this->failover. |
320 | 321 | * Default to the given class if there's no casting information. |
322 | + * @param string $fieldName |
|
321 | 323 | */ |
322 | 324 | public function rssField($fieldName, $defaultClass = 'Varchar') { |
323 | 325 | if($fieldName) { |
@@ -22,7 +22,7 @@ |
||
22 | 22 | /** |
23 | 23 | * Gets the list of shortcodes provided by this handler |
24 | 24 | * |
25 | - * @return mixed |
|
25 | + * @return string[] |
|
26 | 26 | */ |
27 | 27 | public static function get_shortcodes() |
28 | 28 | { |
@@ -132,6 +132,7 @@ discard block |
||
132 | 132 | * {@inheritdoc} |
133 | 133 | * |
134 | 134 | * Also set the URLParams |
135 | + * @param SS_HTTPRequest $request |
|
135 | 136 | */ |
136 | 137 | public function setRequest($request) { |
137 | 138 | $return = parent::setRequest($request); |
@@ -372,7 +373,7 @@ discard block |
||
372 | 373 | * |
373 | 374 | * @param string $action |
374 | 375 | * |
375 | - * @return HTMLText |
|
376 | + * @return DBField |
|
376 | 377 | */ |
377 | 378 | public function defaultAction($action) { |
378 | 379 | return $this->getViewer($action)->process($this); |
@@ -508,7 +509,7 @@ discard block |
||
508 | 509 | * |
509 | 510 | * @param array $params |
510 | 511 | * |
511 | - * @return string |
|
512 | + * @return DBField |
|
512 | 513 | */ |
513 | 514 | public function render($params = null) { |
514 | 515 | $template = $this->getViewer($this->getAction()); |
@@ -673,7 +674,7 @@ discard block |
||
673 | 674 | * Tests whether a redirection has been requested. If redirect() has been called, it will return |
674 | 675 | * the URL redirected to. Otherwise, it will return null. |
675 | 676 | * |
676 | - * @return null|string |
|
677 | + * @return boolean |
|
677 | 678 | */ |
678 | 679 | public function redirectedTo() { |
679 | 680 | return $this->getResponse() && $this->getResponse()->getHeader('Location'); |
@@ -121,6 +121,7 @@ discard block |
||
121 | 121 | |
122 | 122 | /** |
123 | 123 | * Set the DataModel for this request. |
124 | + * @param DataModel $model |
|
124 | 125 | */ |
125 | 126 | public function setDataModel($model) { |
126 | 127 | $this->model = $model; |
@@ -238,6 +239,9 @@ discard block |
||
238 | 239 | return $this; |
239 | 240 | } |
240 | 241 | |
242 | + /** |
|
243 | + * @param SS_HTTPRequest $request |
|
244 | + */ |
|
241 | 245 | protected function findAction($request) { |
242 | 246 | $handlerClass = ($this->class) ? $this->class : get_class($this); |
243 | 247 | |
@@ -271,7 +275,7 @@ discard block |
||
271 | 275 | * |
272 | 276 | * Must not raise SS_HTTPResponse_Exceptions - instead it should return |
273 | 277 | * |
274 | - * @param $request |
|
278 | + * @param SS_HTTPRequest $request |
|
275 | 279 | * @param $action |
276 | 280 | * @return SS_HTTPResponse |
277 | 281 | */ |
@@ -384,6 +388,7 @@ discard block |
||
384 | 388 | |
385 | 389 | /** |
386 | 390 | * Return the class that defines the given action, so that we know where to check allowed_actions. |
391 | + * @return string|null |
|
387 | 392 | */ |
388 | 393 | protected function definingClassForAction($actionOrigCasing) { |
389 | 394 | $action = strtolower($actionOrigCasing); |
@@ -356,7 +356,7 @@ discard block |
||
356 | 356 | * |
357 | 357 | * @param string $property |
358 | 358 | * the name of the property |
359 | - * @param object $object |
|
359 | + * @param string $object |
|
360 | 360 | * the object to be set |
361 | 361 | */ |
362 | 362 | public function addAutoProperty($property, $object) { |
@@ -450,7 +450,7 @@ discard block |
||
450 | 450 | * The name of the service to update the definition for |
451 | 451 | * @param string $property |
452 | 452 | * The name of the property to update. |
453 | - * @param mixed $value |
|
453 | + * @param string $value |
|
454 | 454 | * The value to set |
455 | 455 | * @param boolean $append |
456 | 456 | * Whether to append (the default) when the property is an array |
@@ -755,6 +755,7 @@ discard block |
||
755 | 755 | * |
756 | 756 | * Will recursively call hasService for each depth of dotting |
757 | 757 | * |
758 | + * @param string $name |
|
758 | 759 | * @return string |
759 | 760 | * The name of the service (as it might be different from the one passed in) |
760 | 761 | */ |
@@ -918,7 +919,6 @@ discard block |
||
918 | 919 | * Additional parameters are passed through as |
919 | 920 | * |
920 | 921 | * @param string $name |
921 | - * @param mixed $arguments,... arguments to pass to the constructor |
|
922 | 922 | * @return mixed A new instance of the specified object |
923 | 923 | */ |
924 | 924 | public function create($name) { |
@@ -932,8 +932,6 @@ discard block |
||
932 | 932 | * |
933 | 933 | * @param string $name |
934 | 934 | * Name of the class to create an object of |
935 | - * @param array $args |
|
936 | - * Arguments to pass to the constructor |
|
937 | 935 | * @return mixed |
938 | 936 | */ |
939 | 937 | public function createWithArgs($name, $constructorArgs) { |
@@ -43,6 +43,7 @@ discard block |
||
43 | 43 | |
44 | 44 | /** |
45 | 45 | * @todo Move this to SS_Database or DB |
46 | + * @param string $class |
|
46 | 47 | */ |
47 | 48 | public static function hasTable($class) { |
48 | 49 | // Cache the list of all table names to reduce on DB traffic |
@@ -80,7 +81,7 @@ discard block |
||
80 | 81 | * |
81 | 82 | * @todo Move this into {@see DataObjectSchema} |
82 | 83 | * |
83 | - * @param string|object $class |
|
84 | + * @param string $class |
|
84 | 85 | * @return array |
85 | 86 | */ |
86 | 87 | public static function dataClassesFor($class) { |
@@ -205,6 +206,7 @@ discard block |
||
205 | 206 | |
206 | 207 | /** |
207 | 208 | * Returns true if the given class implements the given interface |
209 | + * @param string $interfaceName |
|
208 | 210 | */ |
209 | 211 | public static function classImplements($className, $interfaceName) { |
210 | 212 | return in_array($className, self::implementorsOf($interfaceName)); |
@@ -255,6 +257,9 @@ discard block |
||
255 | 257 | |
256 | 258 | private static $method_from_cache = array(); |
257 | 259 | |
260 | + /** |
|
261 | + * @param string $method |
|
262 | + */ |
|
258 | 263 | public static function has_method_from($class, $method, $compclass) { |
259 | 264 | $lClass = strtolower($class); |
260 | 265 | $lMethod = strtolower($method); |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | * |
51 | 51 | * @param array|string $val String to escape, or array of strings |
52 | 52 | * |
53 | - * @return array|string |
|
53 | + * @return string |
|
54 | 54 | */ |
55 | 55 | public static function raw2htmlname($val) { |
56 | 56 | if(is_array($val)) { |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | * table, or column name. Supports encoding of multi identfiers separated by |
177 | 177 | * a delimiter (e.g. ".") |
178 | 178 | * |
179 | - * @param string|array $identifier The identifier to escape. E.g. 'SiteTree.Title' or list of identifiers |
|
179 | + * @param string $identifier The identifier to escape. E.g. 'SiteTree.Title' or list of identifiers |
|
180 | 180 | * to be joined via the separator. |
181 | 181 | * @param string $separator The string that delimits subsequent identifiers |
182 | 182 | * @return string The escaped identifier. E.g. '"SiteTree"."Title"' |
@@ -257,6 +257,7 @@ discard block |
||
257 | 257 | * call this function directly, Please use {@link Convert::xml2array()} |
258 | 258 | * |
259 | 259 | * @param SimpleXMLElement |
260 | + * @param SimpleXMLElement $xml |
|
260 | 261 | * |
261 | 262 | * @return mixed |
262 | 263 | */ |