Class YamlConfigurationWriter
java.lang.Object
org.infinispan.commons.configuration.io.AbstractConfigurationWriter
org.infinispan.commons.configuration.io.yaml.YamlConfigurationWriter
- All Implemented Interfaces:
AutoCloseable, ConfigurationWriter
- Since:
- 12.1
- Author:
- Tristan Tarrant <tristan@infinispan.org>
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractConfigurationWriter
AbstractConfigurationWriter.TagNested classes/interfaces inherited from interface ConfigurationWriter
ConfigurationWriter.Builder -
Field Summary
FieldsFields inherited from class AbstractConfigurationWriter
clearTextSecrets, currentIndent, namespaces, naming, prettyPrint, tagStack, writer -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanhasFeature(ConfigurationFormatFeature feature) voidvoidwriteAttribute(String name, Iterable<String> values) voidwriteAttribute(String name, String value) voidwriteCharacters(String chars) voidwriteComment(String comment) voidwriteDefaultNamespace(String namespace) voidwriteEmptyElement(String name) voidvoidvoidvoidvoidvoidwriteMapItem(String element, String name, String key) Writes a complex map entry.voidwriteMapItem(String element, String name, String key, String value) Writes a simple map entry.voidwriteNamespace(String prefix, String namespace) voidwriteStartArrayElement(String name) Writes an array element.voidvoidwriteStartElement(String name) voidwriteStartElement(String prefix, String namespace, String name) voidwriteStartListElement(String name, boolean explicit) Starts a list element.voidwriteStartListElement(String prefix, String namespace, String name, boolean explicit) voidwriteStartMap(String name) Methods inherited from class AbstractConfigurationWriter
clearTextSecrets, close, indent, nl, outdent, tab, writeArrayElement, writeAttribute, writeAttribute, writeAttribute, writeAttribute, writeEmptyElement, writeEndListElement, writeMapItem, writeMapItem, writeStartArrayElement, writeStartElement, writeStartElement, writeStartListElement, writeStartListElement, writeStartMap
-
Field Details
-
INDENT
public static final int INDENT- See Also:
-
-
Constructor Details
-
YamlConfigurationWriter
-
-
Method Details
-
writeStartDocument
public void writeStartDocument() -
writeStartElement
-
writeStartElement
-
writeStartArrayElement
Description copied from interface:ConfigurationWriterWrites an array element. This will be treated as follows by the various implementations:- XML <outer></outer>
- YAML
name:
- item1 - item2 - JSON name: [ item1, item2 ]
- Parameters:
name-
-
writeEndArrayElement
public void writeEndArrayElement() -
writeStartListElement
Description copied from interface:ConfigurationWriterStarts a list element.- Parameters:
name-explicit-
-
writeStartListElement
-
writeNamespace
-
writeDefaultNamespace
-
writeEndElement
public void writeEndElement() -
writeEndDocument
public void writeEndDocument() -
writeAttribute
-
writeAttribute
-
writeArrayElement
-
writeCharacters
-
writeEmptyElement
-
writeComment
-
writeStartMap
-
writeMapItem
Description copied from interface:ConfigurationWriterWrites a simple map entry.- XML:
<element name="key">value<element> - JSON:
{ key: value } - YAML:
key: value
The key name is not translated by the underlying serialization implementation and is used as is
- Parameters:
element- Used only by XMLname- Used only by XMLkey-value-
- XML:
-
writeMapItem
Description copied from interface:ConfigurationWriterWrites a complex map entry.- XML:
<element name="key">...<element> - JSON:
{ key: { ... } } - YAML:
key:
The key name is not translated by the underlying serialization implementation and is used as is
- Parameters:
element- Used only by XMLname- Used only by XMLkey-
- XML:
-
writeEndMapItem
public void writeEndMapItem() -
writeEndMap
public void writeEndMap() -
hasFeature
-