Свойство | Тип | Описание | |
---|---|---|---|
$constants | Array of constants | ||
$containingFileGenerator | Zend\Code\Generator\FileGenerator | ||
$docBlock | Zend\Code\Generator\DocBlockGenerator | ||
$extendedClass | string | ||
$flags | boolean | ||
$implementedInterfaces | Array of string names | ||
$methods | Array of methods | ||
$name | string | ||
$namespaceName | string | ||
$properties | Array of properties | ||
$traitUsageGenerator | Object to encapsulate trait usage logic |
Метод | Описание | |
---|---|---|
__construct ( string $name = null, string $namespaceName = null, array | string $flags = null, string $extends = null, array $interfaces = [], array $properties = [], array $methods = [], Zend\Code\Generator\DocBlockGenerator $docBlock = null ) | ||
addConstant ( string $name, string | integer | null | float | array $value ) : self | Add Constant | |
addConstantFromGenerator ( Zend\Code\Generator\PropertyGenerator $constant ) : self | Add constant from PropertyGenerator | |
addConstants ( array $constants ) : self | ||
addFlag ( string $flag ) : self | ||
addMethod ( string $name, array $parameters = [], integer $flags = MethodGenerator::FLAG_PUBLIC, string $body = null, string $docBlock = null ) : self | Add Method from scalars | |
addMethodFromGenerator ( |
Add Method from MethodGenerator | |
addMethods ( array $methods ) : self | ||
addProperties ( array $properties ) : self | ||
addProperty ( string $name, string | array $defaultValue = null, integer $flags = PropertyGenerator::FLAG_PUBLIC ) : self | Add Property from scalars | |
addPropertyFromGenerator ( Zend\Code\Generator\PropertyGenerator $property ) : self | Add property from PropertyGenerator | |
addTrait ( $trait ) | ||
addTraitAlias ( $method, $alias, $visibility = null ) | ||
addTraitOverride ( $method, $traitsToReplace ) | ||
addTraits ( array $traits ) | ||
addUse ( string $use, string | null $useAlias = null ) : self | Add a class to "use" classes | |
fromArray ( array $array ) : self | Generate from array | |
fromReflection ( Zend\Code\Reflection\ClassReflection $classReflection ) : self | Build a Code Generation Php Object from a Class Reflection | |
generate ( ) | ||
getConstant ( string $constantName ) : Zend\Code\Generator\PropertyGenerator | false | ||
getConstants ( ) : Zend\Code\Generator\PropertyGenerator[] | ||
getContainingFileGenerator ( ) : Zend\Code\Generator\FileGenerator | ||
getDocBlock ( ) : Zend\Code\Generator\DocBlockGenerator | ||
getExtendedClass ( ) : string | ||
getImplementedInterfaces ( ) : array | ||
getMethod ( string $methodName ) : |
||
getMethods ( ) : |
||
getName ( ) : string | ||
getNamespaceName ( ) : string | ||
getProperties ( ) : Zend\Code\Generator\PropertyGenerator[] | ||
getProperty ( string $propertyName ) : Zend\Code\Generator\PropertyGenerator | false | ||
getTraitAliases ( ) | ||
getTraitOverrides ( ) | ||
getTraits ( ) | ||
getUses ( ) : array | Returns the "use" classes | |
hasConstant ( string $constantName ) : boolean | ||
hasExtentedClass ( ) : boolean | ||
hasImplementedInterface ( string $implementedInterface ) : boolean | ||
hasMethod ( string $methodName ) : boolean | ||
hasProperty ( string $propertyName ) : boolean | ||
hasTrait ( $traitName ) | ||
hasUse ( string $use ) : self | ||
hasUseAlias ( string $use ) : boolean | ||
isAbstract ( ) : boolean | ||
isFinal ( ) : boolean | ||
isSourceDirty ( ) : boolean | ||
removeConstant ( string $constantName ) : self | ||
removeExtentedClass ( ) : self | ||
removeFlag ( string $flag ) : self | ||
removeImplementedInterface ( $implementedInterface ) : self | ||
removeMethod ( string $methodName ) : self | ||
removeProperty ( string $propertyName ) : self | ||
removeTrait ( $traitName ) | ||
removeTraitOverride ( $method, $overridesToRemove = null ) | ||
removeUse ( string $use ) : self | ||
removeUseAlias ( $use ) : self | ||
setAbstract ( boolean $isAbstract ) : self | ||
setContainingFileGenerator ( Zend\Code\Generator\FileGenerator $fileGenerator ) : self | ||
setDocBlock ( Zend\Code\Generator\DocBlockGenerator $docBlock ) : self | ||
setExtendedClass ( string $extendedClass ) : self | ||
setFinal ( boolean $isFinal ) : self | ||
setFlags ( array | string $flags ) : self | ||
setImplementedInterfaces ( array $implementedInterfaces ) : self | ||
setName ( string $name ) : self | ||
setNamespaceName ( string $namespaceName ) : self |
Метод | Описание | |
---|---|---|
generateShortOrCompleteClassname ( string $fqnClassName ) : string | ||
validateConstantValue ( mixed $value ) : void |
public __construct ( string $name = null, string $namespaceName = null, array | string $flags = null, string $extends = null, array $interfaces = [], array $properties = [], array $methods = [], Zend\Code\Generator\DocBlockGenerator $docBlock = null ) | ||
$name | string | |
$namespaceName | string | |
$flags | array | string | |
$extends | string | |
$interfaces | array | |
$properties | array | |
$methods | array | |
$docBlock | Zend\Code\Generator\DocBlockGenerator |
public addConstantFromGenerator ( Zend\Code\Generator\PropertyGenerator $constant ) : self | ||
$constant | Zend\Code\Generator\PropertyGenerator | |
Результат | self |
public addConstants ( array $constants ) : self | ||
$constants | array | |
Результат | self |
public addMethodFromGenerator ( |
||
$method | ||
Результат | self |
public addMethods ( array $methods ) : self | ||
$methods | array | |
Результат | self |
public addProperties ( array $properties ) : self | ||
$properties | array | |
Результат | self |
public addPropertyFromGenerator ( Zend\Code\Generator\PropertyGenerator $property ) : self | ||
$property | Zend\Code\Generator\PropertyGenerator | |
Результат | self |
public static fromReflection ( Zend\Code\Reflection\ClassReflection $classReflection ) : self | ||
$classReflection | Zend\Code\Reflection\ClassReflection | |
Результат | self |
public getConstant ( string $constantName ) : Zend\Code\Generator\PropertyGenerator | false | ||
$constantName | string | |
Результат | Zend\Code\Generator\PropertyGenerator | false |
public getConstants ( ) : Zend\Code\Generator\PropertyGenerator[] | ||
Результат | Zend\Code\Generator\PropertyGenerator[] | indexed by constant name |
public getContainingFileGenerator ( ) : Zend\Code\Generator\FileGenerator | ||
Результат | Zend\Code\Generator\FileGenerator |
public getDocBlock ( ) : Zend\Code\Generator\DocBlockGenerator | ||
Результат | Zend\Code\Generator\DocBlockGenerator |
public getImplementedInterfaces ( ) : array | ||
Результат | array |
public getProperties ( ) : Zend\Code\Generator\PropertyGenerator[] | ||
Результат | Zend\Code\Generator\PropertyGenerator[] |
public getProperty ( string $propertyName ) : Zend\Code\Generator\PropertyGenerator | false | ||
$propertyName | string | |
Результат | Zend\Code\Generator\PropertyGenerator | false |
public hasConstant ( string $constantName ) : boolean | ||
$constantName | string | |
Результат | boolean |
public hasImplementedInterface ( string $implementedInterface ) : boolean | ||
$implementedInterface | string | |
Результат | boolean |
public hasProperty ( string $propertyName ) : boolean | ||
$propertyName | string | |
Результат | boolean |
public hasUseAlias ( string $use ) : boolean | ||
$use | string | |
Результат | boolean |
public removeConstant ( string $constantName ) : self | ||
$constantName | string | |
Результат | self |
public removeImplementedInterface ( $implementedInterface ) : self | ||
$implementedInterface | ||
Результат | self |
public removeMethod ( string $methodName ) : self | ||
$methodName | string | |
Результат | self |
public removeProperty ( string $propertyName ) : self | ||
$propertyName | string | |
Результат | self |
public removeTraitOverride ( $method, $overridesToRemove = null ) |
public setAbstract ( boolean $isAbstract ) : self | ||
$isAbstract | boolean | |
Результат | self |
public setContainingFileGenerator ( Zend\Code\Generator\FileGenerator $fileGenerator ) : self | ||
$fileGenerator | Zend\Code\Generator\FileGenerator | |
Результат | self |
public setDocBlock ( Zend\Code\Generator\DocBlockGenerator $docBlock ) : self | ||
$docBlock | Zend\Code\Generator\DocBlockGenerator | |
Результат | self |
public setExtendedClass ( string $extendedClass ) : self | ||
$extendedClass | string | |
Результат | self |
public setImplementedInterfaces ( array $implementedInterfaces ) : self | ||
$implementedInterfaces | array | |
Результат | self |
public setNamespaceName ( string $namespaceName ) : self | ||
$namespaceName | string | |
Результат | self |
protected FileGenerator,Zend\Code\Generator $containingFileGenerator | ||
Результат | Zend\Code\Generator\FileGenerator |
protected DocBlockGenerator,Zend\Code\Generator $docBlock | ||
Результат | Zend\Code\Generator\DocBlockGenerator |