| Methods |
public
|
__construct(?string $name, NodeInterface $parent = null, string $pathSeparator = self::DEFAULT_PATH_SEPARATOR)
|
#
|
public
|
setAttribute(string $key, mixed $value): void
|
#
|
public
|
getAttribute(string $key, mixed $default = null): mixed
|
#
|
public
|
hasAttribute(string $key): bool
|
#
|
public
|
getAttributes(): array
|
#
|
public
|
setAttributes(array $attributes): void
|
#
|
public
|
removeAttribute(string $key): void
|
#
|
public
|
setInfo(string $info): void
Sets an info message.
|
#
|
public
|
getInfo(): ?string
Returns info message.
|
#
|
public
|
setExample(string|array $example): void
Sets the example configuration for this node.
Sets the example configuration for this node.
|
#
|
public
|
getExample(): string|array|null
Retrieves the example configuration for this node.
Retrieves the example configuration for this node.
|
#
|
public
|
addEquivalentValue(mixed $originalValue, mixed $equivalentValue): void
Adds an equivalent value.
Adds an equivalent value.
|
#
|
public
|
setRequired(bool $boolean): void
Set this node as required.
Set this node as required.
|
#
|
public
|
setDeprecated(
string $package,
string $version,
string $message = 'The child node "%node%" at path "%path%" is deprecated.',
): void
Sets this node as deprecated.
Sets this node as deprecated.
You can use %node% and %path% placeholders in your message to display,
respectively, the node name and its complete path.
Parameters
| $package |
The name of the composer package that is triggering the deprecation
|
| $version |
The version of the package that introduced the deprecation
|
| $message |
the deprecation message to use
|
|
#
|
public
|
setAllowOverwrite(bool $allow): void
Sets if this node can be overridden.
Sets if this node can be overridden.
|
#
|
public
|
setNormalizationClosures(Closure[] $closures): void
Sets the closures used for normalization.
Sets the closures used for normalization.
Parameters
| $closures |
An array of Closures used for normalization
|
|
#
|
public
|
setNormalizedTypes(array $types): void
Sets the list of types supported by normalization.
Sets the list of types supported by normalization.
see ExprBuilder::TYPE_* constants.
|
#
|
public
|
getNormalizedTypes(): array
Gets the list of types supported by normalization.
Gets the list of types supported by normalization.
see ExprBuilder::TYPE_* constants.
|
#
|
public
|
setFinalValidationClosures(Closure[] $closures): void
Sets the closures used for final validation.
Sets the closures used for final validation.
Parameters
| $closures |
An array of Closures used for final validation
|
|
#
|
public
|
isRequired(): bool
Returns true when the node is required.
Returns true when the node is required.
Implements
|
#
|
public
|
isDeprecated(): bool
Checks if this node is deprecated.
Checks if this node is deprecated.
|
#
|
public
|
getDeprecation(string $node, string $path): array
Parameters
| $node |
The configuration node name
|
| $path |
The path of the node
|
|
#
|
public
|
getName(): string
Returns the name of the node.
Returns the name of the node.
Implements
|
#
|
public
|
getPath(): string
Returns the path of the node.
Returns the path of the node.
Implements
|
#
|
final
public
|
merge(mixed $leftSide, mixed $rightSide): mixed
Merges two values together.
Merges two values together.
Implements
|
#
|
final
public
|
normalize(mixed $value): mixed
Normalizes a value.
|
#
|
protected
|
preNormalize(mixed $value): mixed
Normalizes the value before any other normalization is applied.
Normalizes the value before any other normalization is applied.
Overriden by
|
#
|
public
|
getParent(): ?NodeInterface
Returns parent node for this node.
Returns parent node for this node.
|
#
|
final
public
|
finalize(mixed $value): mixed
Finalizes a value.
|
#
|
abstract
protected
|
validateType(mixed $value): void
Validates the type of a Node.
Validates the type of a Node.
Throws
Implemented by
|
#
|
abstract
protected
|
normalizeValue(mixed $value): mixed
Normalizes the value.
|
#
|
abstract
protected
|
mergeValues(mixed $leftSide, mixed $rightSide): mixed
Merges two values together.
Merges two values together.
Implemented by
|
#
|
abstract
protected
|
finalizeValue(mixed $value): mixed
Finalizes a value.
|
#
|
protected
|
allowPlaceholders(): bool
Tests if placeholder values are allowed for this node.
Tests if placeholder values are allowed for this node.
Overriden by
|
#
|
protected
|
isHandlingPlaceholder(): bool
Tests if a placeholder is being handled currently.
Tests if a placeholder is being handled currently.
|
#
|
protected
|
getValidPlaceholderTypes(): array
Gets allowed dynamic types for this node.
Gets allowed dynamic types for this node.
Overriden by
|
#
|
private
static
|
resolvePlaceholderValue(mixed $value): mixed
|
#
|
private
|
doValidateType(mixed $value): void
|
#
|