@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | /** |
176 | 176 | * Add a piece of data to the view. |
177 | 177 | * |
178 | - * @param string|array $key |
|
178 | + * @param string $key |
|
179 | 179 | * @param mixed $value |
180 | 180 | * @return $this |
181 | 181 | */ |
@@ -382,7 +382,7 @@ discard block |
||
382 | 382 | * Remove a piece of bound data from the view. |
383 | 383 | * |
384 | 384 | * @param string $key |
385 | - * @return bool |
|
385 | + * @return boolean|null |
|
386 | 386 | */ |
387 | 387 | public function __unset($key) |
388 | 388 | { |
@@ -317,6 +317,9 @@ |
||
317 | 317 | return $this->listDirectoryContents($directory, $recursive); |
318 | 318 | } |
319 | 319 | |
320 | + /** |
|
321 | + * @param string $directory |
|
322 | + */ |
|
320 | 323 | abstract protected function listDirectoryContents($directory, $recursive = false); |
321 | 324 | |
322 | 325 | /** |
@@ -36,7 +36,7 @@ |
||
36 | 36 | * |
37 | 37 | * @param string $path |
38 | 38 | * |
39 | - * @return array|false |
|
39 | + * @return resource |
|
40 | 40 | * |
41 | 41 | * @see League\Flysystem\ReadInterface::read() |
42 | 42 | */ |
@@ -15,6 +15,7 @@ |
||
15 | 15 | * Set the Filesystem object. |
16 | 16 | * |
17 | 17 | * @param FilesystemInterface $filesystem |
18 | + * @return void |
|
18 | 19 | */ |
19 | 20 | public function setFilesystem(FilesystemInterface $filesystem); |
20 | 21 | } |
@@ -20,11 +20,18 @@ |
||
20 | 20 | static::$safeStorage[$this->hash] = []; |
21 | 21 | } |
22 | 22 | |
23 | + /** |
|
24 | + * @param string $key |
|
25 | + * @param string $value |
|
26 | + */ |
|
23 | 27 | public function storeSafely($key, $value) |
24 | 28 | { |
25 | 29 | static::$safeStorage[$this->hash][$key] = $value; |
26 | 30 | } |
27 | 31 | |
32 | + /** |
|
33 | + * @param string $key |
|
34 | + */ |
|
28 | 35 | public function retrieveSafely($key) |
29 | 36 | { |
30 | 37 | if (array_key_exists($key, static::$safeStorage[$this->hash])) { |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | * Guess MIME Type based on the path of the file and it's content. |
177 | 177 | * |
178 | 178 | * @param string $path |
179 | - * @param string|resource $content |
|
179 | + * @param string $content |
|
180 | 180 | * |
181 | 181 | * @return string|null MIME Type or NULL if no extension detected |
182 | 182 | */ |
@@ -254,6 +254,9 @@ discard block |
||
254 | 254 | } |
255 | 255 | } |
256 | 256 | |
257 | + /** |
|
258 | + * @param resource $resource |
|
259 | + */ |
|
257 | 260 | public static function isSeekableStream($resource) |
258 | 261 | { |
259 | 262 | $metadata = stream_get_meta_data($resource); |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | * By default it will handle errors, exceptions and fatal errors |
54 | 54 | * |
55 | 55 | * @param LoggerInterface $logger |
56 | - * @param array|false $errorLevelMap an array of E_* constant to LogLevel::* constant mapping, or false to disable error handling |
|
56 | + * @param boolean $errorLevelMap an array of E_* constant to LogLevel::* constant mapping, or false to disable error handling |
|
57 | 57 | * @param int|false $exceptionLevel a LogLevel::* constant, or false to disable exception handling |
58 | 58 | * @param int|false $fatalLevel a LogLevel::* constant, or false to disable fatal error handling |
59 | 59 | * @return ErrorHandler |
@@ -77,6 +77,9 @@ discard block |
||
77 | 77 | return $handler; |
78 | 78 | } |
79 | 79 | |
80 | + /** |
|
81 | + * @param integer $level |
|
82 | + */ |
|
80 | 83 | public function registerExceptionHandler($level = null, $callPrevious = true) |
81 | 84 | { |
82 | 85 | $prev = set_exception_handler(array($this, 'handleException')); |
@@ -97,6 +100,9 @@ discard block |
||
97 | 100 | $this->handleOnlyReportedErrors = $handleOnlyReportedErrors; |
98 | 101 | } |
99 | 102 | |
103 | + /** |
|
104 | + * @param integer $level |
|
105 | + */ |
|
100 | 106 | public function registerFatalHandler($level = null, $reservedMemorySize = 20) |
101 | 107 | { |
102 | 108 | register_shutdown_function(array($this, 'handleFatalError')); |
@@ -147,6 +153,8 @@ discard block |
||
147 | 153 | |
148 | 154 | /** |
149 | 155 | * @private |
156 | + * @param integer $code |
|
157 | + * @param string $message |
|
150 | 158 | */ |
151 | 159 | public function handleError($code, $message, $file = '', $line = 0, $context = array()) |
152 | 160 | { |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | * Formats a log record. |
80 | 80 | * |
81 | 81 | * @param array $record A record to format |
82 | - * @return mixed The formatted record |
|
82 | + * @return string The formatted record |
|
83 | 83 | */ |
84 | 84 | public function format(array $record) |
85 | 85 | { |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | * Formats a set of log records. |
114 | 114 | * |
115 | 115 | * @param array $records A set of records to format |
116 | - * @return mixed The formatted set of records |
|
116 | + * @return string The formatted set of records |
|
117 | 117 | */ |
118 | 118 | public function formatBatch(array $records) |
119 | 119 | { |
@@ -125,6 +125,9 @@ discard block |
||
125 | 125 | return $message; |
126 | 126 | } |
127 | 127 | |
128 | + /** |
|
129 | + * @return string |
|
130 | + */ |
|
128 | 131 | protected function convertToString($data) |
129 | 132 | { |
130 | 133 | if (null === $data || is_scalar($data)) { |
@@ -74,6 +74,9 @@ discard block |
||
74 | 74 | return $record; |
75 | 75 | } |
76 | 76 | |
77 | + /** |
|
78 | + * @param integer $nestingLevel |
|
79 | + */ |
|
77 | 80 | protected function formatObject($value, $nestingLevel) |
78 | 81 | { |
79 | 82 | $objectVars = get_object_vars($value); |
@@ -82,6 +85,9 @@ discard block |
||
82 | 85 | return $this->formatArray($objectVars, $nestingLevel); |
83 | 86 | } |
84 | 87 | |
88 | + /** |
|
89 | + * @param integer $nestingLevel |
|
90 | + */ |
|
85 | 91 | protected function formatException(\Exception $exception, $nestingLevel) |
86 | 92 | { |
87 | 93 | $formattedException = array( |
@@ -100,6 +106,9 @@ discard block |
||
100 | 106 | return $this->formatArray($formattedException, $nestingLevel); |
101 | 107 | } |
102 | 108 | |
109 | + /** |
|
110 | + * @param integer $nestingLevel |
|
111 | + */ |
|
103 | 112 | protected function formatDate(\DateTime $value, $nestingLevel) |
104 | 113 | { |
105 | 114 | return new \MongoDate($value->getTimestamp()); |