PHP Class Doctrine\OXM\Mapping\Driver\AnnotationDriver

Since: 2.0
Author: Richard Fullmer ([email protected])
Inheritance: implements Doctrine\OXM\Mapping\Driver\Driver
Show file Open project: doctrine/oxm Class Usage Examples

Protected Properties

Property Type Description
$classNames
$fileExtension string The file extension of mapping documents.
$paths array The paths where to look for mapping files.

Public Methods

Method Description
__construct ( AnnotationReader $reader, string | array $paths = null ) Initializes a new AnnotationDriver that uses the given AnnotationReader for reading docblock annotations.
addPaths ( array $paths ) Append lookup paths to metadata driver.
create ( array | string $paths = [], AnnotationReader $reader = null ) : AnnotationDriver Factory method for the Annotation Driver
getAllClassNames ( ) {@inheritDoc}
getFileExtension ( ) : void Get the file extension used to look for mapping files under
getPaths ( ) : array Retrieve the defined metadata lookup paths.
isTransient ( string $className ) : boolean Whether the class with the specified name is transient. Only non-transient classes, that is entities and mapped superclasses, should have their metadata loaded.
loadMetadataForClass ( $className, ClassMetadataInfo $metadata )
setFileExtension ( string $fileExtension ) : void Set the file extension used to look for mapping files under

Method Details

__construct() public method

Initializes a new AnnotationDriver that uses the given AnnotationReader for reading docblock annotations.
public __construct ( AnnotationReader $reader, string | array $paths = null )
$reader Doctrine\Common\Annotations\AnnotationReader The AnnotationReader to use.
$paths string | array One or multiple paths where mapping classes can be found.

addPaths() public method

Append lookup paths to metadata driver.
public addPaths ( array $paths )
$paths array

create() public static method

Factory method for the Annotation Driver
public static create ( array | string $paths = [], AnnotationReader $reader = null ) : AnnotationDriver
$paths array | string
$reader Doctrine\Common\Annotations\AnnotationReader
return AnnotationDriver

getAllClassNames() public method

{@inheritDoc}
public getAllClassNames ( )

getFileExtension() public method

Get the file extension used to look for mapping files under
public getFileExtension ( ) : void
return void

getPaths() public method

Retrieve the defined metadata lookup paths.
public getPaths ( ) : array
return array

isTransient() public method

A class is non-transient if it is annotated with either @XmlEntity or
public isTransient ( string $className ) : boolean
$className string
return boolean

loadMetadataForClass() public method

public loadMetadataForClass ( $className, ClassMetadataInfo $metadata )
$metadata Doctrine\OXM\Mapping\ClassMetadataInfo

setFileExtension() public method

Set the file extension used to look for mapping files under
public setFileExtension ( string $fileExtension ) : void
$fileExtension string The file extension to set
return void

Property Details

$classNames protected property

protected $classNames

$fileExtension protected property

The file extension of mapping documents.
protected string $fileExtension
return string

$paths protected property

The paths where to look for mapping files.
protected array $paths
return array