PHP Class Doctrine\ODM\OrientDB\Mapper\ClassMetadataFactory

Inheritance: implements Doctrine\Common\Persistence\Mapping\ClassMetadataFactory
Show file Open project: doctrine/orientdb-odm Class Usage Examples

Public Properties

Property Type Description
$multipleAssociations
$singleAssociations

Protected Properties

Property Type Description
$annotationReader
$cache
$classMap
$documentDirectories
$metadata

Public Methods

Method Description
__construct ( Doctrine\ODM\OrientDB\Mapper\Annotations\ReaderInterface $annotationReader, Doctrine\Common\Cache\Cache $cache )
findClassMappingInDirectories ( string $OClass ) : string Tries to find the PHP class mapping Doctrine\OrientDB's $OClass in each of the directories where the documents are stored.
getAllMetadata ( )
getClassAnnotation ( string $class ) : Document Returns the annotation of a class.
getClassByPath ( string $file, string $namespace ) : string Returns the fully qualified name of a class by its path
getDocumentDirectories ( ) : array Returns the directories in which the mapper is going to look for classes mapped for the Doctrine\OrientDB ODM.
getMetadataFor ( $className ) : ClassMetadata
getObjectPropertyAnnotations ( mixed $document ) : array Returns all the annotations in the $document's properties.
getPropertyAnnotation ( ReflectionProperty $property ) : Property Returns the annotation of a property.
hasMetadataFor ( $className )
isTransient ( string $className ) : boolean Whether the class with the specified name should have its metadata loaded.
setDocumentDirectories ( array $directories ) Sets the directories in which the mapper is going to look for classes mapped for the Doctrine\OrientDB ODM.
setMetadataFor ( $className, $metadata )

Protected Methods

Method Description
findClassMappingInDirectory ( string $OClass, string $directory, string $namespace ) : string | null Searches a PHP class mapping Doctrine\OrientDB's $OClass in $directory, which uses the given $namespace.
getAssociationTypes ( ) : Array Returns all the possible association types.
populateMetadata ( ClassMetadata $metadata )

Method Details

__construct() public method

public __construct ( Doctrine\ODM\OrientDB\Mapper\Annotations\ReaderInterface $annotationReader, Doctrine\Common\Cache\Cache $cache )
$annotationReader Doctrine\ODM\OrientDB\Mapper\Annotations\ReaderInterface
$cache Doctrine\Common\Cache\Cache

findClassMappingInDirectories() public method

Tries to find the PHP class mapping Doctrine\OrientDB's $OClass in each of the directories where the documents are stored.
public findClassMappingInDirectories ( string $OClass ) : string
$OClass string
return string

findClassMappingInDirectory() protected method

Searches a PHP class mapping Doctrine\OrientDB's $OClass in $directory, which uses the given $namespace.
protected findClassMappingInDirectory ( string $OClass, string $directory, string $namespace ) : string | null
$OClass string
$directory string
$namespace string
return string | null

getAllMetadata() public method

public getAllMetadata ( )

getAssociationTypes() protected method

e.g. linklist, linkmap, link...
protected getAssociationTypes ( ) : Array
return Array

getClassAnnotation() public method

Returns the annotation of a class.
public getClassAnnotation ( string $class ) : Document
$class string
return Doctrine\ODM\OrientDB\Mapper\Annotations\Document

getClassByPath() public method

Returns the fully qualified name of a class by its path
public getClassByPath ( string $file, string $namespace ) : string
$file string
$namespace string
return string

getDocumentDirectories() public method

Returns the directories in which the mapper is going to look for classes mapped for the Doctrine\OrientDB ODM.
public getDocumentDirectories ( ) : array
return array

getMetadataFor() public method

public getMetadataFor ( $className ) : ClassMetadata
return ClassMetadata

getObjectPropertyAnnotations() public method

Returns all the annotations in the $document's properties.
public getObjectPropertyAnnotations ( mixed $document ) : array
$document mixed
return array

getPropertyAnnotation() public method

Returns the annotation of a property.
public getPropertyAnnotation ( ReflectionProperty $property ) : Property
$property ReflectionProperty
return Doctrine\ODM\OrientDB\Mapper\Annotations\Property

hasMetadataFor() public method

public hasMetadataFor ( $className )

isTransient() public method

This is only the case if it is either mapped directly or as a MappedSuperclass.
public isTransient ( string $className ) : boolean
$className string
return boolean

populateMetadata() protected method

protected populateMetadata ( ClassMetadata $metadata )
$metadata ClassMetadata

setDocumentDirectories() public method

Sets the directories in which the mapper is going to look for classes mapped for the Doctrine\OrientDB ODM.
public setDocumentDirectories ( array $directories )
$directories array

setMetadataFor() public method

public setMetadataFor ( $className, $metadata )

Property Details

$annotationReader protected property

protected $annotationReader

$cache protected property

protected $cache

$classMap protected property

protected $classMap

$documentDirectories protected property

protected $documentDirectories

$metadata protected property

protected $metadata

$multipleAssociations public static property

public static $multipleAssociations

$singleAssociations public static property

public static $singleAssociations