com.bea.alsb.financial.api
Class SerializationAPI
java.lang.Object
com.bea.alsb.financial.api.SerializationAPI
public final class SerializationAPI
- extends Object
Facade API for serialization operations of a parsed message into Text.
serializeToText
public static String serializeToText(MessageWrapper message,
boolean throwOnError)
throws SerializationException
- Serializes the wrapped message to text. The wrapper will be updated with the
encountered errors if any and throwOnError was
false
, or have its
errors reset otherwise.
- Parameters:
message
- the message to serialize.throwOnError
- true
to throw upon encountering the first error,
false
to keep serializing and collect as many errors as possible before
eventually having to abort.
- Returns:
- the text representing the serialized message.
- Throws:
SerializationException
- for any serialization errors (typically thrown when throwOnError
is true
).