Class PropertiesWriter
java.lang.Object
io.micronaut.serde.properties.util.PropertiesWriter
Writes a JSON tree as a Java
.properties document.
Array index and bracketed output is controlled by SerdePropertiesConfiguration.
- Since:
- 3.1.0
-
Constructor Summary
ConstructorsConstructorDescriptionPropertiesWriter(SerdePropertiesConfiguration propertiesConfiguration) Creates a properties writer. -
Method Summary
Modifier and TypeMethodDescriptionvoidwrite(OutputStream outputStream, io.micronaut.json.tree.JsonNode tree) Writes the given JSON tree to the output stream as a flattened.propertiesdocument.
-
Constructor Details
-
PropertiesWriter
Creates a properties writer.- Parameters:
propertiesConfiguration- The properties format configuration
-
-
Method Details
-
write
public void write(OutputStream outputStream, io.micronaut.json.tree.JsonNode tree) throws IOException Writes the given JSON tree to the output stream as a flattened.propertiesdocument.- Parameters:
outputStream- The destination streamtree- The tree to flatten into properties output- Throws:
IOException- If the properties output cannot be written
-