| @@ 166-175 (lines=10) @@ | ||
| 163 | return $this->reflection->getTraits(); |
|
| 164 | } |
|
| 165 | ||
| 166 | public function hasConstant($name) |
|
| 167 | { |
|
| 168 | if (!is_string($name)) { |
|
| 169 | throw Exception\ReflectionExceptionFactory::invalidArgument( |
|
| 170 | sprintf("Parameter 1 of %s must be a string.", __METHOD__) |
|
| 171 | ); |
|
| 172 | } |
|
| 173 | ||
| 174 | return $this->reflection->hasConstant($name); |
|
| 175 | } |
|
| 176 | ||
| 177 | public function hasMethod($name) |
|
| 178 | { |
|
| @@ 177-186 (lines=10) @@ | ||
| 174 | return $this->reflection->hasConstant($name); |
|
| 175 | } |
|
| 176 | ||
| 177 | public function hasMethod($name) |
|
| 178 | { |
|
| 179 | if (!is_string($name)) { |
|
| 180 | throw Exception\ReflectionExceptionFactory::invalidArgument( |
|
| 181 | sprintf("Parameter 1 of %s must be a string.", __METHOD__) |
|
| 182 | ); |
|
| 183 | } |
|
| 184 | ||
| 185 | return $this->reflection->hasMethod($name); |
|
| 186 | } |
|
| 187 | ||
| 188 | public function hasProperty($name) |
|
| 189 | { |
|
| @@ 188-197 (lines=10) @@ | ||
| 185 | return $this->reflection->hasMethod($name); |
|
| 186 | } |
|
| 187 | ||
| 188 | public function hasProperty($name) |
|
| 189 | { |
|
| 190 | if (!is_string($name)) { |
|
| 191 | throw Exception\ReflectionExceptionFactory::invalidArgument( |
|
| 192 | sprintf("Parameter 1 of %s must be a string.", __METHOD__) |
|
| 193 | ); |
|
| 194 | } |
|
| 195 | ||
| 196 | return $this->reflection->hasProperty($name); |
|
| 197 | } |
|
| 198 | ||
| 199 | public function implementsInterface($interface) |
|
| 200 | { |
|
| @@ 199-208 (lines=10) @@ | ||
| 196 | return $this->reflection->hasProperty($name); |
|
| 197 | } |
|
| 198 | ||
| 199 | public function implementsInterface($interface) |
|
| 200 | { |
|
| 201 | if (!is_string($interface)) { |
|
| 202 | throw Exception\ReflectionExceptionFactory::invalidArgument( |
|
| 203 | sprintf("Parameter 1 of %s must be a string.", __METHOD__) |
|
| 204 | ); |
|
| 205 | } |
|
| 206 | ||
| 207 | return $this->reflection->implementsInterface($interface); |
|
| 208 | } |
|
| 209 | ||
| 210 | public function inNamespace() |
|
| 211 | { |
|
| @@ 261-270 (lines=10) @@ | ||
| 258 | return $this->reflection->isIterateable(); |
|
| 259 | } |
|
| 260 | ||
| 261 | public function isSubclassOf($class) |
|
| 262 | { |
|
| 263 | if (!is_string($class)) { |
|
| 264 | throw Exception\ReflectionExceptionFactory::invalidArgument( |
|
| 265 | sprintf("Parameter 1 of %s must be a string.", __METHOD__) |
|
| 266 | ); |
|
| 267 | } |
|
| 268 | ||
| 269 | return $this->reflection->isSubclassOf($class); |
|
| 270 | } |
|
| 271 | ||
| 272 | public function isTrait() |
|
| 273 | { |
|