/** * Returns a value holder for the class or interface type declared for this * parameter or <b>null</b> when no parameter type hint was declared. * * @return PHP_Depend_Code_ASTClassOrInterfaceReference * @since 0.9.5 * @deprecated since 0.9.12 */ public function getClassReference() { fwrite(STDERR, __METHOD__ . '() is deprecated since 0.9.12.' . PHP_EOL); return $this->_formalParameter->getFirstChildOfType(PHP_Depend_Code_ASTClassOrInterfaceReference::CLAZZ); }
/** * Returns the class type of this parameter. This method will return * <b>null</b> for all scalar type, only classes or interfaces are used. * * @return PHP_Depend_Code_AbstractClassOrInterface * @since 0.9.5 */ public function getClass() { $classReference = $this->_formalParameter->getFirstChildOfType(PHP_Depend_Code_ASTClassOrInterfaceReference::CLAZZ); if ($classReference === null) { return null; } return $classReference->getType(); }
/** * This method will return <b>true</b> when the parameter was declared with * the array type hint, otherwise the it will return <b>false</b>. * * @return boolean * @since 0.9.5 */ public function isArray() { $arrayType = $this->_formalParameter->getFirstChildOfType(PHP_Depend_Code_ASTArrayType::CLAZZ); return $arrayType !== null; }