Documentation

ColocatedMappingDriver

The ColocatedMappingDriver reads the mapping metadata located near the code.

Table of Contents

Properties

$classNames  : array<int, string>|null
Cache for getAllClassNames().
$excludePaths  : array<int, string>
The paths excluded from path where to look for mapping files.
$fileExtension  : string
The file extension of mapping documents.
$paths  : array<int, string>
The paths where to look for mapping files.

Methods

addExcludePaths()  : void
Append exclude lookup paths to metadata driver.
addPaths()  : void
Appends lookup paths to metadata driver.
getAllClassNames()  : array<string|int, string>
Gets the names of all mapped classes known to this driver.
getExcludePaths()  : array<int, string>
Retrieve the defined metadata lookup exclude paths.
getFileExtension()  : string
Gets the file extension used to look for mapping files under.
getPaths()  : array<int, string>
Retrieves the defined metadata lookup paths.
isTransient()  : bool
{@inheritDoc}
setFileExtension()  : void
Sets the file extension used to look for mapping files under.

Properties

$classNames

Cache for getAllClassNames().

protected array<int, string>|null $classNames
Tags
psalm-var

list|null

$excludePaths

The paths excluded from path where to look for mapping files.

protected array<int, string> $excludePaths = []

$fileExtension

The file extension of mapping documents.

protected string $fileExtension = '.php'

Methods

addExcludePaths()

Append exclude lookup paths to metadata driver.

public addExcludePaths(array<string|int, string> $paths) : void
Parameters
$paths : array<string|int, string>

addPaths()

Appends lookup paths to metadata driver.

public addPaths(array<int, string> $paths) : void
Parameters
$paths : array<int, string>

getAllClassNames()

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

public getAllClassNames() : array<string|int, string>
Tags
psalm-return

list

Return values
array<string|int, string>

The names of all mapped classes known to this driver.

getExcludePaths()

Retrieve the defined metadata lookup exclude paths.

public getExcludePaths() : array<int, string>
Return values
array<int, string>

getFileExtension()

Gets the file extension used to look for mapping files under.

public getFileExtension() : string
Return values
string

getPaths()

Retrieves the defined metadata lookup paths.

public getPaths() : array<int, string>
Return values
array<int, string>

isTransient()

{@inheritDoc}

public abstract isTransient(string $className) : bool

Returns whether the class with the specified name is transient. Only non-transient classes, that is entities and mapped superclasses, should have their metadata loaded.

Parameters
$className : string
Tags
psalm-param

class-string $className

Return values
bool

setFileExtension()

Sets the file extension used to look for mapping files under.

public setFileExtension(string $fileExtension) : void
Parameters
$fileExtension : string

        
On this page

Search results