PHP Class Neos\Flow\Reflection\ClassSchema

Afficher le fichier Open project: neos/flow-development-collection Class Usage Examples

Protected Properties

Свойство Type Description
$className string Name of the class this schema is referring to
$identityProperties array The properties forming the identity of an object
$lazyLoadable boolean Whether instances of the class can be lazy-loadable
$modelType integer Model type of the class this schema is referring to
$properties array Properties of the class which need to be persisted
$repositoryClassName string

Méthodes publiques

Méthode Description
__construct ( string $className ) Constructs this class schema
addProperty ( string $name, string $type, boolean $lazy = false, boolean $transient = false ) : void Adds (defines) a specific property and its type.
getClassName ( ) : string Returns the class name this schema is referring to
getIdentityProperties ( ) : array Gets the properties (names and types) forming the identity of an object.
getModelType ( ) : integer Returns the model type of the class this schema is referring to.
getProperties ( ) : array Returns all properties defined in this schema
getProperty ( string $propertyName ) : array Returns the given property defined in this schema. Check with hasProperty($propertyName) before!
getRepositoryClassName ( ) : string
hasProperty ( string $propertyName ) : boolean If the class schema has a certain property.
isAggregateRoot ( ) : boolean Whether the class is accessible through a repository and therefore an aggregate root.
isLazyLoadableObject ( ) : boolean Marks the class as being lazy-loadable.
isMultiValuedProperty ( string $propertyName ) : boolean Checks if the given property defined in this schema is multi-valued (i.e.
isPropertyLazy ( string $propertyName ) : boolean If a certain class schema property is to be lazy loaded
isPropertyTransient ( string $propertyName ) : boolean If a certain class schema property is to disregarded for persistence
markAsIdentityProperty ( string $propertyName ) : void Marks the given property as one of properties forming the identity of an object. The property must already be registered in the class schema.
setLazyLoadableObject ( boolean $lazyLoadable ) : void Marks the class as being lazy-loadable.
setModelType ( integer $modelType ) : void Sets the model type of the class this schema is referring to.
setRepositoryClassName ( string $repositoryClassName ) : void Set the class name of the repository managing an entity.

Method Details

__construct() public méthode

Constructs this class schema
public __construct ( string $className )
$className string Name of the class this schema is referring to

addProperty() public méthode

Adds (defines) a specific property and its type.
public addProperty ( string $name, string $type, boolean $lazy = false, boolean $transient = false ) : void
$name string Name of the property
$type string Type of the property
$lazy boolean Whether the property should be lazy-loaded when reconstituting
$transient boolean Whether the property should not be considered for persistence
Résultat void

getClassName() public méthode

Returns the class name this schema is referring to
public getClassName ( ) : string
Résultat string The class name

getIdentityProperties() public méthode

Gets the properties (names and types) forming the identity of an object.
See also: markAsIdentityProperty()
public getIdentityProperties ( ) : array
Résultat array

getModelType() public méthode

Returns the model type of the class this schema is referring to.
public getModelType ( ) : integer
Résultat integer The model type, one of the MODELTYPE_* constants.

getProperties() public méthode

Returns all properties defined in this schema
public getProperties ( ) : array
Résultat array

getProperty() public méthode

Returns the given property defined in this schema. Check with hasProperty($propertyName) before!
public getProperty ( string $propertyName ) : array
$propertyName string
Résultat array

getRepositoryClassName() public méthode

public getRepositoryClassName ( ) : string
Résultat string

hasProperty() public méthode

If the class schema has a certain property.
public hasProperty ( string $propertyName ) : boolean
$propertyName string Name of the property
Résultat boolean

isAggregateRoot() public méthode

Whether the class is accessible through a repository and therefore an aggregate root.
public isAggregateRoot ( ) : boolean
Résultat boolean TRUE

isLazyLoadableObject() public méthode

Marks the class as being lazy-loadable.
public isLazyLoadableObject ( ) : boolean
Résultat boolean

isMultiValuedProperty() public méthode

array or SplObjectStorage).
public isMultiValuedProperty ( string $propertyName ) : boolean
$propertyName string
Résultat boolean

isPropertyLazy() public méthode

If a certain class schema property is to be lazy loaded
public isPropertyLazy ( string $propertyName ) : boolean
$propertyName string Name of the property
Résultat boolean

isPropertyTransient() public méthode

If a certain class schema property is to disregarded for persistence
public isPropertyTransient ( string $propertyName ) : boolean
$propertyName string Name of the property
Résultat boolean

markAsIdentityProperty() public méthode

Marks the given property as one of properties forming the identity of an object. The property must already be registered in the class schema.
public markAsIdentityProperty ( string $propertyName ) : void
$propertyName string
Résultat void

setLazyLoadableObject() public méthode

Marks the class as being lazy-loadable.
public setLazyLoadableObject ( boolean $lazyLoadable ) : void
$lazyLoadable boolean
Résultat void

setModelType() public méthode

Sets the model type of the class this schema is referring to.
public setModelType ( integer $modelType ) : void
$modelType integer The model type, one of the MODELTYPE_* constants.
Résultat void

setRepositoryClassName() public méthode

Set the class name of the repository managing an entity.
public setRepositoryClassName ( string $repositoryClassName ) : void
$repositoryClassName string
Résultat void

Property Details

$className protected_oe property

Name of the class this schema is referring to
protected string $className
Résultat string

$identityProperties protected_oe property

The properties forming the identity of an object
protected array $identityProperties
Résultat array

$lazyLoadable protected_oe property

Whether instances of the class can be lazy-loadable
protected bool $lazyLoadable
Résultat boolean

$modelType protected_oe property

Model type of the class this schema is referring to
protected int $modelType
Résultat integer

$properties protected_oe property

Properties of the class which need to be persisted
protected array $properties
Résultat array

$repositoryClassName protected_oe property

protected string $repositoryClassName
Résultat string