class GeneratorConfig implements GeneratorConfigInterface
A class that holds build properties and provide a class loading mechanism for the generator.
Methods
__construct(array|Traversable $props = null)
Construct a new GeneratorConfig. |
||
array |
getBuildProperties()
Returns the build properties. |
|
setBuildProperties(array|Traversable $props)
Parses the passed-in properties, renaming and saving eligible properties in this object. |
||
mixed |
getBuildProperty(string $name)
Returns a specific Propel (renamed) property from the build. |
|
setBuildProperty(string $name, mixed $value)
Sets a specific propel (renamed) property from the build. |
||
string |
getClassName(string $propname)
Resolves and returns the class name based on the specified property value. |
|
string |
getBuilderClassName(string $type)
Resolves and returns the builder class name. |
|
PlatformInterface |
getConfiguredPlatform(ConnectionInterface $con = null, string $database = null)
Creates and configures a new Platform class. |
|
SchemaParserInterface |
getConfiguredSchemaParser(ConnectionInterface $con = null)
Creates and configures a new SchemaParser class for specified platform. |
|
DataModelBuilder |
getConfiguredBuilder(Table $table, string $type)
Returns a configured data model builder class for specified table and based on type ('ddl', 'sql', etc.). |
|
Pluralizer |
getConfiguredPluralizer()
Returns a configured Pluralizer class. |
|
setBuildConnections($buildConnections) | ||
array|null |
getBuildConnections(string $directory = '.')
Returns all connections from the buildtime config. |
|
getBuildConnection($databaseName = null) | ||
getConnection($database) |
Details
at line 46
public
__construct(array|Traversable $props = null)
Construct a new GeneratorConfig.
at line 58
public array
getBuildProperties()
Returns the build properties.
at line 71
public
setBuildProperties(array|Traversable $props)
Parses the passed-in properties, renaming and saving eligible properties in this object.
Renames the propel.xxx properties to just xxx and renames any xxx.yyy properties
to xxxYyy as PHP doesn't like the xxx.yyy syntax.
at line 94
public mixed
getBuildProperty(string $name)
Returns a specific Propel (renamed) property from the build.
at line 105
public
setBuildProperty(string $name, mixed $value)
Sets a specific propel (renamed) property from the build.
at line 119
public string
getClassName(string $propname)
Resolves and returns the class name based on the specified property value.
The name of the property holds the class path as a dot-path
notation.
at line 152
public string
getBuilderClassName(string $type)
Resolves and returns the builder class name.
at line 166
public PlatformInterface
getConfiguredPlatform(ConnectionInterface $con = null, string $database = null)
Creates and configures a new Platform class.
at line 198
public SchemaParserInterface
getConfiguredSchemaParser(ConnectionInterface $con = null)
Creates and configures a new SchemaParser class for specified platform.
at line 222
public DataModelBuilder
getConfiguredBuilder(Table $table, string $type)
Returns a configured data model builder class for specified table and based on type ('ddl', 'sql', etc.).
at line 239
public Pluralizer
getConfiguredPluralizer()
Returns a configured Pluralizer class.
at line 247
public
setBuildConnections($buildConnections)
at line 259
public array|null
getBuildConnections(string $directory = '.')
Returns all connections from the buildtime config.