Copied!

A helper providing autocompletion for available YamlEncoder options.

Note that the "indentation" setting is not offered in this builder because
it can only be set during the construction of the YamlEncoder, but not per
call.

CloneableFinalInstantiable
Methods
public toArray() : array
public withContext(Symfony\Component\Serializer\Context\ContextBuilderInterface|array $context) : static
public withFlags(?int $flags) : static
 

Configures \Symfony\Component\Yaml\Dumper::dump flags bitmask.

  • see \Symfony\Component\Yaml\Yaml
public withIndentLevel(?int $indentLevel) : static
 

Configures the indentation level.

Must be positive.

public withInlineThreshold(?int $inlineThreshold) : static
 

Configures the threshold to switch to inline YAML.

public withPreservedEmptyObjects(?bool $preserveEmptyObjects) : static
 

Configures whether to perserve empty objects "{}" or to convert them to null.

Methods
protected with(string $key, ?mixed $value) : static
Properties
private array $context
© 2023 Bruce Wells
Search Namespaces \ Classes
Configuration