java.lang.Object
com.aquima.interactions.communication.data.serialization.json.ObjectWriter

public class ObjectWriter extends Object
Writes an object to a Json string.

This implementation is immutable and therefore thread safe.

Since:
9.3
Author:
A.Pragt
  • Constructor Details

    • ObjectWriter

      public ObjectWriter(boolean indent)
      Constructs a new instance of the serializer.
      Parameters:
      indent - to use whitespace indentation for pretty printing.
  • Method Details

    • write

      public void write(DataValue dataValue, Writer target) throws IOException
      Writes an object to a Json string.
      Parameters:
      dataValue - The object to serialize, can be null.
      target - The target to write to, cannot be null.
      Throws:
      RuntimeException - In case of a parse exception.
      IOException - In case of problems during data output.