Devtools
Global Zemit Configuration
- Full name:
\Zemit\Bootstrap\Devtools
- Parent class:
\Zemit\Bootstrap\Config
Methods
__construct
Config Constructor
public __construct(array $data = [], bool $insensitive = true): mixed
Parameters:
Parameter | Type | Description |
---|---|---|
$data | array | |
$insensitive | bool |
Inherited methods
defineConst
public defineConst(): void
__construct
Config Constructor
public __construct(array $data = [], bool $insensitive = false): mixed
Parameters:
Parameter | Type | Description |
---|---|---|
$data | array | |
$insensitive | bool |
pathToArray
Return the element as an array
public pathToArray(string $path, ?array $defaultValue = null, ?string $delimiter = null): ?array
Parameters:
Parameter | Type | Description |
---|---|---|
$path | string | |
$defaultValue | ?array | |
$delimiter | ?string |
merge
public merge(mixed $toMerge, bool $append = false): \Phalcon\Config\ConfigInterface
Parameters:
Parameter | Type | Description |
---|---|---|
$toMerge | mixed | |
$append | bool |
internalMergeAppend
final protected internalMergeAppend(array $source, array $target): array
- This method is final.
Parameters:
Parameter | Type | Description |
---|---|---|
$source | array | |
$target | array |
getDateTime
Get a modified DateTime.
public getDateTime(string $modifier, \DateTimeImmutable|null $dateTime = null): \DateTimeImmutable
Note: This is a helper to enhance strict typings and safely use DateTime within config
Parameters:
Parameter | Type | Description |
---|---|---|
$modifier | string | The modifier string to modify the DateTime. |
$dateTime | **\DateTimeImmutable | null** |
Return Value:
The modified DateTime object.
Throws:
If the modification of the DateTime fails.
getModelInstance
Return a new model instance from class name
public getModelInstance(string $class): \Zemit\Mvc\ModelInterface
Parameters:
Parameter | Type | Description |
---|---|---|
$class | string |
getModelClass
Return the mapped model class name from $this->models->$class
public getModelClass(string $class): string
Parameters:
Parameter | Type | Description |
---|---|---|
$class | string |
setModelClass
Map a new model class
public setModelClass(string $class, string $expected): void
Parameters:
Parameter | Type | Description |
---|---|---|
$class | string | |
$expected | string |
resetModelClass
Map a new model class
public resetModelClass(string $class): void
Parameters:
Parameter | Type | Description |
---|---|---|
$class | string |