PHP Class LeanMapper\Reflection\Property

Author: Vojtěch Kohout
Afficher le fichier Open project: tharos/leanmapper Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( string $name, EntityReflection $entityReflection, string | null $column, PropertyType $type, boolean $isWritable, boolean $isNullable, boolean $containsCollection, boolean $hasDefaultValue, mixed | null $defaultValue = null, HasOne | HasMany | LeanMapper\Relationship\BelongsToOne | LeanMapper\Relationship\BelongsToMany | null $relationship = null, PropertyMethods $propertyMethods = null, PropertyFilters $propertyFilters = null, PropertyPasses $propertyPasses = null, PropertyValuesEnum $propertyValuesEnum = null, array $customFlags = [] )
containsCollection ( ) : boolean Tells whether property is assumed to contain collection
containsEnumeration ( ) : boolean Tells whether property contains enumeration
getColumn ( ) : string | null Gets name of column holding low-level value
getCustomFlagValue ( string $name ) : string Gets value of requested custom flag
getDefaultValue ( ) : mixed | null Gets default value of property (as defined in annotation)
getEnumValues ( ) : array Gets possible enumeration values
getFilters ( integer $index ) : array | null Gets property filters
getFiltersTargetedArgs ( integer $index ) : array | null Gets filters arguments hard-coded in annotation
getGetter ( ) : string | null Gets getter method
getGetterPass ( ) : string | null Gets getter pass
getName ( ) : string Gets property name
getRelationship ( ) : LeanMapper\Relationship\BelongsToMany | LeanMapper\Relationship\BelongsToOne | HasMany | HasOne | null Returns relationship that property represents
getSetter ( ) : string | null Gets setter method
getSetterPass ( ) : string | null Gets setter pass
getType ( ) : string Gets property type
hasCustomFlag ( string $name ) : boolean Tells whether property has custom flag
hasDefaultValue ( ) : boolean Tells whether property has default value (defined in annotation)
hasRelationship ( ) : boolean Tells whether property represents relationship
isBasicType ( ) : boolean Tells whether property type is basic type (boolean|integer|float|string|array)
isNullable ( ) : boolean Tells whether property can be null
isValueFromEnum ( mixed $value ) : boolean Tells wheter given value is from enumeration
isWritable ( ) : boolean Tells whether property is writable

Private Methods

Méthode Description
checkContainsEnumeration ( )

Method Details

__construct() public méthode

public __construct ( string $name, EntityReflection $entityReflection, string | null $column, PropertyType $type, boolean $isWritable, boolean $isNullable, boolean $containsCollection, boolean $hasDefaultValue, mixed | null $defaultValue = null, HasOne | HasMany | LeanMapper\Relationship\BelongsToOne | LeanMapper\Relationship\BelongsToMany | null $relationship = null, PropertyMethods $propertyMethods = null, PropertyFilters $propertyFilters = null, PropertyPasses $propertyPasses = null, PropertyValuesEnum $propertyValuesEnum = null, array $customFlags = [] )
$name string
$entityReflection EntityReflection
$column string | null
$type PropertyType
$isWritable boolean
$isNullable boolean
$containsCollection boolean
$hasDefaultValue boolean
$defaultValue mixed | null
$relationship LeanMapper\Relationship\HasOne | LeanMapper\Relationship\HasMany | LeanMapper\Relationship\BelongsToOne | LeanMapper\Relationship\BelongsToMany | null
$propertyMethods PropertyMethods
$propertyFilters PropertyFilters
$propertyPasses PropertyPasses
$propertyValuesEnum PropertyValuesEnum
$customFlags array

containsCollection() public méthode

Tells whether property is assumed to contain collection
public containsCollection ( ) : boolean
Résultat boolean

containsEnumeration() public méthode

Tells whether property contains enumeration
public containsEnumeration ( ) : boolean
Résultat boolean

getColumn() public méthode

Gets name of column holding low-level value
public getColumn ( ) : string | null
Résultat string | null

getCustomFlagValue() public méthode

Gets value of requested custom flag
public getCustomFlagValue ( string $name ) : string
$name string
Résultat string

getDefaultValue() public méthode

Gets default value of property (as defined in annotation)
public getDefaultValue ( ) : mixed | null
Résultat mixed | null

getEnumValues() public méthode

Gets possible enumeration values
public getEnumValues ( ) : array
Résultat array

getFilters() public méthode

Gets property filters
public getFilters ( integer $index ) : array | null
$index integer
Résultat array | null

getFiltersTargetedArgs() public méthode

Gets filters arguments hard-coded in annotation
public getFiltersTargetedArgs ( integer $index ) : array | null
$index integer
Résultat array | null

getGetter() public méthode

Gets getter method
public getGetter ( ) : string | null
Résultat string | null

getGetterPass() public méthode

Gets getter pass
public getGetterPass ( ) : string | null
Résultat string | null

getName() public méthode

Gets property name
public getName ( ) : string
Résultat string

getRelationship() public méthode

Returns relationship that property represents
public getRelationship ( ) : LeanMapper\Relationship\BelongsToMany | LeanMapper\Relationship\BelongsToOne | HasMany | HasOne | null
Résultat LeanMapper\Relationship\BelongsToMany | LeanMapper\Relationship\BelongsToOne | LeanMapper\Relationship\HasMany | LeanMapper\Relationship\HasOne | null

getSetter() public méthode

Gets setter method
public getSetter ( ) : string | null
Résultat string | null

getSetterPass() public méthode

Gets setter pass
public getSetterPass ( ) : string | null
Résultat string | null

getType() public méthode

Gets property type
public getType ( ) : string
Résultat string

hasCustomFlag() public méthode

Tells whether property has custom flag
public hasCustomFlag ( string $name ) : boolean
$name string
Résultat boolean

hasDefaultValue() public méthode

Tells whether property has default value (defined in annotation)
public hasDefaultValue ( ) : boolean
Résultat boolean

hasRelationship() public méthode

Tells whether property represents relationship
public hasRelationship ( ) : boolean
Résultat boolean

isBasicType() public méthode

Tells whether property type is basic type (boolean|integer|float|string|array)
public isBasicType ( ) : boolean
Résultat boolean

isNullable() public méthode

Tells whether property can be null
public isNullable ( ) : boolean
Résultat boolean

isValueFromEnum() public méthode

Tells wheter given value is from enumeration
public isValueFromEnum ( mixed $value ) : boolean
$value mixed
Résultat boolean

isWritable() public méthode

Tells whether property is writable
public isWritable ( ) : boolean
Résultat boolean