Package com.blackrook.json
Class JSONWriter.Options
java.lang.Object
com.blackrook.json.JSONWriter.Options
- Enclosing class:
- JSONWriter
The JSON export options to pass to the writer methods.
- Since:
- 1.2.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
void
setConverterSet
(JSONConverterSet converterSet) Replaces the underlying converter set.void
setIndentation
(String indentation) Sets the indentation string to use for pretty-printing indentation.void
setOmittingNullMembers
(boolean nullOmitting) Sets if the writer omits null values from being exported from objects.
-
Constructor Details
-
Options
public Options()
-
-
Method Details
-
getIndentation
- Returns:
- the indentation string to use for pretty-printing indentation.
-
setIndentation
Sets the indentation string to use for pretty-printing indentation.- Parameters:
indentation
- the indentation string to use.
-
isOmittingNullMembers
public boolean isOmittingNullMembers()- Returns:
- true if this omits object type members with a null values, false if not.
-
setOmittingNullMembers
public void setOmittingNullMembers(boolean nullOmitting) Sets if the writer omits null values from being exported from objects.- Parameters:
nullOmitting
- true if so, false if not.
-
setConverterSet
Replaces the underlying converter set.- Parameters:
converterSet
- the converter set to use.- Since:
- 1.3.0
-