java.lang.Object
org.xbib.content.core.AbstractXContentGenerator
org.xbib.content.xml.XmlXContentGenerator
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable,org.xbib.content.XContentGenerator
public class XmlXContentGenerator
extends org.xbib.content.core.AbstractXContentGenerator
Content generator for XML formatted content.
-
Field Summary
Fields inherited from class org.xbib.content.core.AbstractXContentGenerator
generator -
Constructor Summary
ConstructorsConstructorDescriptionXmlXContentGenerator(com.fasterxml.jackson.dataformat.xml.ser.ToXmlGenerator generator) XmlXContentGenerator(com.fasterxml.jackson.dataformat.xml.ser.ToXmlGenerator generator, XmlXParams params) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()org.xbib.content.XContentcontent()voidcopy(org.xbib.content.XContentBuilder builder, OutputStream outputStream) voidcopyCurrentStructure(org.xbib.content.XContentParser parser) voidflush()setParams(XmlXParams params) voidvoidwriteFieldName(String name) voidwriteRawField(String fieldName, byte[] content, int offset, int length, OutputStream outputStream) voidwriteRawField(String fieldName, byte[] content, OutputStream outputStream) voidvoidwriteString(char[] text, int offset, int len) voidwriteString(String text) voidwriteValue(org.xbib.content.XContentBuilder builder) Methods inherited from class org.xbib.content.core.AbstractXContentGenerator
setGenerator, writeArrayFieldStart, writeBinary, writeBinary, writeBinaryField, writeBoolean, writeBooleanField, writeEndArray, writeEndObject, writeNull, writeNullField, writeNumber, writeNumber, writeNumber, writeNumber, writeNumber, writeNumber, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeObjectFieldStart, writeStartArray, writeStringField, writeUTF8String
-
Constructor Details
-
XmlXContentGenerator
public XmlXContentGenerator(com.fasterxml.jackson.dataformat.xml.ser.ToXmlGenerator generator) -
XmlXContentGenerator
public XmlXContentGenerator(com.fasterxml.jackson.dataformat.xml.ser.ToXmlGenerator generator, XmlXParams params)
-
-
Method Details
-
getParams
-
setParams
- Throws:
IOException
-
content
public org.xbib.content.XContent content() -
usePrettyPrint
public void usePrettyPrint() -
writeStartObject
- Specified by:
writeStartObjectin interfaceorg.xbib.content.XContentGenerator- Overrides:
writeStartObjectin classorg.xbib.content.core.AbstractXContentGenerator- Throws:
IOException
-
writeFieldName
- Specified by:
writeFieldNamein interfaceorg.xbib.content.XContentGenerator- Overrides:
writeFieldNamein classorg.xbib.content.core.AbstractXContentGenerator- Throws:
IOException
-
writeString
- Specified by:
writeStringin interfaceorg.xbib.content.XContentGenerator- Overrides:
writeStringin classorg.xbib.content.core.AbstractXContentGenerator- Throws:
IOException
-
writeString
- Specified by:
writeStringin interfaceorg.xbib.content.XContentGenerator- Overrides:
writeStringin classorg.xbib.content.core.AbstractXContentGenerator- Throws:
IOException
-
writeRawField
public void writeRawField(String fieldName, byte[] content, OutputStream outputStream) throws IOException - Throws:
IOException
-
writeRawField
public void writeRawField(String fieldName, byte[] content, int offset, int length, OutputStream outputStream) throws IOException - Throws:
IOException
-
writeValue
- Throws:
IOException
-
copy
public void copy(org.xbib.content.XContentBuilder builder, OutputStream outputStream) throws IOException - Throws:
IOException
-
copyCurrentStructure
- Throws:
IOException
-
flush
- Throws:
IOException
-
close
- Throws:
IOException
-