- java.lang.Object
-
- xyz.tozymc.configuration.option.TcConfigOptions
-
- xyz.tozymc.configuration.file.option.FileConfigOptions
-
- xyz.tozymc.configuration.yaml.option.YamlConfigOptions
-
public class YamlConfigOptions extends xyz.tozymc.configuration.file.option.FileConfigOptionsVarious options forYamlConfig.- Since:
- 1.0
-
-
Constructor Summary
Constructors Constructor Description YamlConfigOptions(@NotNull xyz.tozymc.configuration.file.FileConfig config)Creates newYamlConfigOptionsforYamlConfig.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull YamlConfigconfig()@NotNull org.yaml.snakeyaml.DumperOptionsdumperOptions()org.yaml.snakeyaml.DumperOptions.FlowStyleflowStyle()Gets flow style for YAML document, default isDumperOptions.FlowStyle.BLOCK.@NotNull YamlConfigOptionsflowStyle(org.yaml.snakeyaml.DumperOptions.FlowStyle flowStyle)Sets flow style for YAML document, default isDumperOptions.FlowStyle.BLOCK.intindent()Gets the indent of between parent and child element.@NotNull YamlConfigOptionsindent(int indent)Sets the indent of between parent and child element.booleanprettyFlow()Checks if YAML document using pretty flow style.@NotNull YamlConfigOptionsprettyFlow(boolean prettyFlow)Force the emitter to produce a pretty YAML document when using the flow style.-
Methods inherited from class xyz.tozymc.configuration.file.option.FileConfigOptions
reloadType, reloadType
-
-
-
-
Constructor Detail
-
YamlConfigOptions
public YamlConfigOptions(@NotNull @NotNull xyz.tozymc.configuration.file.FileConfig config)
Creates newYamlConfigOptionsforYamlConfig.- Parameters:
config- Configuration that owned this options.
-
-
Method Detail
-
indent
public int indent()
Gets the indent of between parent and child element.- Returns:
- The indent of between parent and child element.
-
indent
@NotNull public @NotNull YamlConfigOptions indent(int indent)
Sets the indent of between parent and child element.- Parameters:
indent- indent of between parent and child element.- Returns:
- This object, for chaining.
-
prettyFlow
public boolean prettyFlow()
Checks if YAML document using pretty flow style.- Returns:
- True if YAML document using pretty flow style.
-
prettyFlow
@NotNull public @NotNull YamlConfigOptions prettyFlow(boolean prettyFlow)
Force the emitter to produce a pretty YAML document when using the flow style.- Parameters:
prettyFlow- True produce pretty flow YAML document.- Returns:
- This object, for chaining.
-
flowStyle
public org.yaml.snakeyaml.DumperOptions.FlowStyle flowStyle()
Gets flow style for YAML document, default isDumperOptions.FlowStyle.BLOCK.- Returns:
- Flow style for YAML document.
-
flowStyle
@NotNull public @NotNull YamlConfigOptions flowStyle(org.yaml.snakeyaml.DumperOptions.FlowStyle flowStyle)
Sets flow style for YAML document, default isDumperOptions.FlowStyle.BLOCK.- Parameters:
flowStyle- Flow style for YAML document.- Returns:
- This object, for chaining.
-
config
@NotNull public @NotNull YamlConfig config()
- Overrides:
configin classxyz.tozymc.configuration.file.option.FileConfigOptions
-
-