JsonPayloadUtil
as that class
can be properly overridden by a connector developer.@Deprecated public class JsonPayloadUtil extends BasePayload
Constructor and Description |
---|
JsonPayloadUtil()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
static Payload |
toPayload(Object obj)
Deprecated.
Creates a new payload that will use a default
ObjectMapper to
write the provided object to an OutputStream using
BasePayload.writeTo(OutputStream) . |
static Payload |
toPayload(Object obj,
ObjectMapper mapper)
Deprecated.
Creates a new payload that will using the provided
ObjectMapper
to write the provided object to an OutputStream using
BasePayload.writeTo(OutputStream) . |
static Payload |
toPayload(TreeNode node)
Deprecated.
Creates a new payload that will use a default
ObjectMapper to
write the provided TreeNode to an OutputStream using
BasePayload.writeTo(OutputStream) . |
close, getMetadata, readFrom, writeTo
public static Payload toPayload(Object obj)
ObjectMapper
to
write the provided object to an OutputStream
using
BasePayload.writeTo(OutputStream)
. The ObjectMapper
used by this
method does not allow access modifiers to be overridden and will not fail
when writing empty beans.obj
- the object to writenull
, null
otherwisepublic static Payload toPayload(Object obj, ObjectMapper mapper)
ObjectMapper
to write the provided object to an OutputStream
using
BasePayload.writeTo(OutputStream)
.obj
- the object to writemapper
- the mapper used to write the objectnull
, null
otherwisepublic static Payload toPayload(TreeNode node)
ObjectMapper
to
write the provided TreeNode
to an OutputStream
using
BasePayload.writeTo(OutputStream)
. The ObjectMapper
used by this
method does not allow access modifiers to be overridden and will not fail
when writing empty beans.node
- the object to writenull
, null
otherwise