Class JacksonJsonNodeSink
- java.lang.Object
-
- io.wcm.caravan.io.jsontransform.sink.JacksonJsonNodeSink
-
- All Implemented Interfaces:
Sink
,Closeable
,AutoCloseable
@ProviderType public final class JacksonJsonNodeSink extends Object implements Sink
Converts the JSON stream elements intoJsonNode
s.
-
-
Constructor Summary
Constructors Constructor Description JacksonJsonNodeSink(com.fasterxml.jackson.core.JsonFactory factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
com.fasterxml.jackson.databind.JsonNode
getJsonNode()
boolean
hasOutput()
void
write(JsonElement element)
Takes an JSON element and writes it some where in any format.
-
-
-
Method Detail
-
getJsonNode
public com.fasterxml.jackson.databind.JsonNode getJsonNode()
- Returns:
- The root node
-
close
public void close() throws IOException
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
write
public void write(JsonElement element) throws IOException
Description copied from interface:Sink
Takes an JSON element and writes it some where in any format.- Specified by:
write
in interfaceSink
- Parameters:
element
- JSON element- Throws:
IOException
- Writing error
-
-