class MappingDriverChain implements MappingDriver (View source)

The DriverChain allows you to add multiple other mapping drivers for certain namespaces.

Methods

getDefaultDriver()

Gets the default driver.

void
setDefaultDriver(MappingDriver $driver)

Set the default driver.

void
addDriver(MappingDriver $nestedDriver, $namespace)

Adds a nested driver.

getDrivers()

Gets the array of nested drivers.

void
loadMetadataForClass($className, ClassMetadata $metadata)

Loads the metadata for the specified class into the provided container.

string[]
getAllClassNames()

Gets the names of all mapped classes known to this driver.

bool
isTransient(string $className)

Returns whether the class with the specified name should have its metadata loaded.

Details

MappingDriver|null getDefaultDriver()

Gets the default driver.

Return Value

MappingDriver|null

void setDefaultDriver(MappingDriver $driver)

Set the default driver.

Parameters

MappingDriver $driver

Return Value

void

void addDriver(MappingDriver $nestedDriver, $namespace)

Adds a nested driver.

Parameters

MappingDriver $nestedDriver
$namespace

Return Value

void

MappingDriver[] getDrivers()

Gets the array of nested drivers.

Return Value

MappingDriver[] $drivers

void loadMetadataForClass($className, ClassMetadata $metadata)

Loads the metadata for the specified class into the provided container.

Parameters

$className
ClassMetadata $metadata

Return Value

void

string[] getAllClassNames()

Gets the names of all mapped classes known to this driver.

Return Value

string[] The names of all mapped classes known to this driver.

bool isTransient(string $className)

Returns whether the class with the specified name should have its metadata loaded.

This is only the case if it is either mapped as an Entity or a MappedSuperclass.

Parameters

string $className

Return Value

bool