Property | Type | Description | |
---|---|---|---|
$aliases | array | ||
$contenttypes | array | ||
$defaultAliases | array | ||
$fallbackEntity | A default entity for any table not matched | ||
$initialized | boolean | ||
$metadata | metadata mappings | ||
$namingStrategy | Bolt\Storage\NamingStrategy | ||
$schemaManager | |||
$taxonomies | taxonomy configuration | ||
$typemap | array | ||
$unmapped | array | Keeps a reference of which metadata is not mapped to a specific entity. |
Method | Description | |
---|---|---|
__construct ( |
Constructor. | |
getAliases ( ) : array | Getter for aliases | |
getAllClassNames ( ) | ||
getClassMetadata ( string $className ) : Doctrine\Common\Persistence\Mapping\ClassMetadata | false | Returns the metadata for a given class name. | |
getContentTypeFromAlias ( $alias, boolean $forceSlug = false ) : string | Given a tablename or slug get the correct Bolt keyname from the config | |
getFieldMetadata ( $contenttype, $column, $field = null ) | ||
getFieldTypeFor ( string $name, Doctrine\DBAL\Schema\Column $column, null $field = null ) : string | Get the field type for a given column. | |
getRepeaterMapping ( array $config ) : array | This is a helper method to get a correct mapping from an array config. It's designed to take raw array config to generate a correct format mapping for repeaters. | |
getTaxonomyConfig ( ) : array | ||
getUnmapped ( ) : array | Gets a list of tables that are not mapped to specific entities. | |
initialize ( ) | Reads the schema from Bolt\Storage\Database\Schema\Manager and creates mapping data | |
initializeDefaultAliases ( ) | This seeds the defaultAliases array with the correctly prefixed mappings | |
initializeShortAliases ( ) | Setup some short aliases so non prefixed keys can be used to get metadata | |
isTransient ( string $className ) : boolean | Not implemented, always returns false. | |
loadMetadataForClass ( $className, Doctrine\Common\Persistence\Mapping\ClassMetadata $metadata = null ) | ||
loadMetadataForFields ( array $fields ) | ||
resolveClassName ( string $alias ) : string | Method will try to find an entity class name to handle data, alternatively falling back to $this->fallbackEntity | |
setContentFields ( $contentKey, $className, $table ) | ||
setDefaultAlias ( string $alias, string $entity ) : void | Adds an alias mapping from an internal name to a Fully Qualified Entity. | |
setIncomingRelations ( $contentKey, $className ) | ||
setRelations ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | Set the relationship. | |
setRepeaters ( string $contentKey, string $className, array $inputData = null ) : array | null | ||
setTaxonomies ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | Set the taxonomy. | |
setTemplatefields ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | Setup a templatefields field if needed. |
Method | Description | |
---|---|---|
loadMetadataForTable ( Doctrine\DBAL\Schema\Table $table ) | Load the metadata for a table. | |
normalizeClassName ( $className ) : string | Performs basic normalisation on a searched for class name to make sure it conforms to lookup format. |
public __construct ( |
||
$schemaManager | ||
$contenttypes | ||
$taxonomies | ||
$typemap | array | |
$namingStrategy | Bolt\Storage\NamingStrategy |
public getClassMetadata ( string $className ) : Doctrine\Common\Persistence\Mapping\ClassMetadata | false | ||
$className | string | |
return | Doctrine\Common\Persistence\Mapping\ClassMetadata | false | The class metadata. |
public getContentTypeFromAlias ( $alias, boolean $forceSlug = false ) : string | ||
$alias | ||
$forceSlug | boolean | |
return | string | $key |
public getRepeaterMapping ( array $config ) : array | ||
$config | array | |
return | array |
public getUnmapped ( ) : array | ||
return | array |
public initialize ( ) |
public initializeDefaultAliases ( ) |
public initializeShortAliases ( ) |
public isTransient ( string $className ) : boolean | ||
$className | string | |
return | boolean |
public loadMetadataForClass ( $className, Doctrine\Common\Persistence\Mapping\ClassMetadata $metadata = null ) | ||
$metadata | Doctrine\Common\Persistence\Mapping\ClassMetadata |
protected loadMetadataForTable ( Doctrine\DBAL\Schema\Table $table ) | ||
$table | Doctrine\DBAL\Schema\Table |
protected normalizeClassName ( $className ) : string | ||
$className | ||
return | string |
public resolveClassName ( string $alias ) : string | ||
$alias | string | |
return | string | Fully Qualified Class Name |
public setIncomingRelations ( $contentKey, $className ) | ||
$contentKey | ||
$className |
public setRelations ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | ||
$contentKey | string | |
$className | string | |
$table | Doctrine\DBAL\Schema\Table |
public setTaxonomies ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | ||
$contentKey | string | |
$className | string | |
$table | Doctrine\DBAL\Schema\Table |
public setTemplatefields ( string $contentKey, string $className, Doctrine\DBAL\Schema\Table $table ) | ||
$contentKey | string | |
$className | string | |
$table | Doctrine\DBAL\Schema\Table |
protected $fallbackEntity |
protected NamingStrategy,Bolt\Storage $namingStrategy | ||
return | Bolt\Storage\NamingStrategy |
protected Manager,Bolt\Storage\Database\Schema $schemaManager | ||
return |
protected array $unmapped | ||
return | array |