Class TomlGenerator
java.lang.Object
com.fasterxml.jackson.core.JsonGenerator
com.fasterxml.jackson.core.base.GeneratorBase
com.fasterxml.jackson.dataformat.toml.TomlGenerator
- All Implemented Interfaces:
com.fasterxml.jackson.core.Versioned
,Closeable
,Flushable
,AutoCloseable
final class TomlGenerator
extends com.fasterxml.jackson.core.base.GeneratorBase
-
Nested Class Summary
Nested classes/interfaces inherited from class com.fasterxml.jackson.core.JsonGenerator
com.fasterxml.jackson.core.JsonGenerator.Feature
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final StringBuilder
protected final com.fasterxml.jackson.core.io.IOContext
protected final Writer
UnderlyingWriter
used for output.protected char[]
Intermediate buffer in which contents are buffered before being written using_out
.protected final int
Offset to index after the last valid index in_outputBuffer
.protected int
Pointer to the next available location in_outputBuffer
protected TomlWriteContext
Current context, in form we can use it (GeneratorBase has untyped reference; left as null)private final int
protected static final int
Fields inherited from class com.fasterxml.jackson.core.base.GeneratorBase
_cfgNumbersAsStrings, _closed, _features, _objectCodec, _writeContext, DERIVED_FEATURES_MASK, MAX_BIG_DECIMAL_SCALE, SURR1_FIRST, SURR1_LAST, SURR2_FIRST, SURR2_LAST, WRITE_BINARY, WRITE_BOOLEAN, WRITE_NULL, WRITE_NUMBER, WRITE_RAW, WRITE_STRING
Fields inherited from class com.fasterxml.jackson.core.JsonGenerator
_cfgPrettyPrinter, DEFAULT_BINARY_WRITE_CAPABILITIES, DEFAULT_TEXTUAL_WRITE_CAPABILITIES, DEFAULT_WRITE_CAPABILITIES
-
Constructor Summary
ConstructorsConstructorDescriptionTomlGenerator
(com.fasterxml.jackson.core.io.IOContext ioCtxt, int stdFeatures, int tomlFeatures, com.fasterxml.jackson.core.ObjectCodec codec, Writer out) -
Method Summary
Modifier and TypeMethodDescriptionprivate void
_appendPropertyName
(StringBuilder path, String name) protected void
protected void
protected void
_verifyValueWrite
(String typeMsg) protected void
_verifyValueWrite
(String typeMsg, boolean forceMaterializeKey) protected void
_writeRaw
(char c) protected void
_writeRaw
(char[] text, int offset, int len) protected void
protected void
_writeRaw
(StringBuilder text) protected void
_writeRawLong
(String text) protected void
_writeRawLong
(StringBuilder text) private void
_writeStringImpl
(int categoryMask, char[] text, int offset, int len) private void
_writeStringImpl
(int categoryMask, String name) void
boolean
boolean
void
close()
void
flush()
com.fasterxml.jackson.core.Version
version()
void
writeBinary
(com.fasterxml.jackson.core.Base64Variant b64variant, byte[] data, int offset, int len) void
writeBoolean
(boolean state) private void
void
void
void
writeFieldName
(String name) void
void
writeNumber
(double d) void
writeNumber
(float f) void
writeNumber
(int i) void
writeNumber
(long l) void
writeNumber
(short v) void
writeNumber
(String encodedValue) void
writeNumber
(BigDecimal dec) void
void
void
writeRaw
(char c) void
writeRaw
(char[] text, int offset, int len) void
writeRaw
(com.fasterxml.jackson.core.SerializableString text) void
void
void
writeRawUTF8String
(byte[] text, int offset, int len) void
void
writeStartArray
(Object currValue) void
void
writeStartObject
(Object forValue) void
writeString
(char[] text, int offset, int len) void
writeString
(String text) void
writeUTF8String
(byte[] text, int offset, int len) private void
Methods inherited from class com.fasterxml.jackson.core.base.GeneratorBase
_asString, _checkRangeBoundsForByteArray, _checkRangeBoundsForCharArray, _checkRangeBoundsForString, _checkStdFeatureChanges, _constructDefaultPrettyPrinter, _decodeSurrogate, disable, enable, getCodec, getCurrentValue, getFeatureMask, getOutputContext, isClosed, isEnabled, overrideStdFeatures, setCodec, setCurrentValue, setFeatureMask, useDefaultPrettyPrinter, writeBinary, writeFieldName, writeObject, writeRawValue, writeRawValue, writeRawValue, writeRawValue, writeString, writeTree
Methods inherited from class com.fasterxml.jackson.core.JsonGenerator
_copyCurrentContents, _copyCurrentFloatValue, _copyCurrentFloatValueExact, _copyCurrentIntValue, _copyCurrentStringValue, _reportError, _reportUnsupportedOperation, _throwInternal, _verifyOffsets, _writeSimpleObject, canOmitFields, canUseSchema, canWriteBinaryNatively, canWriteFormattedNumbers, configure, copyCurrentEvent, copyCurrentEventExact, copyCurrentStructure, getCharacterEscapes, getFormatFeatures, getHighestEscapedChar, getOutputBuffered, getOutputTarget, getPrettyPrinter, getSchema, getWriteCapabilities, isEnabled, overrideFormatFeatures, setCharacterEscapes, setHighestNonEscapedChar, setPrettyPrinter, setRootValueSeparator, setSchema, writeArray, writeArray, writeArray, writeArray, writeArrayFieldStart, writeBinary, writeBinary, writeBinary, writeBinaryField, writeBooleanField, writeEmbeddedObject, writeFieldId, writeNullField, writeNumber, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeObjectField, writeObjectFieldStart, writeObjectId, writeObjectRef, writeOmittedField, writePOJOField, writeStartArray, writeStartArray, writeStartObject, writeString, writeStringField, writeTypeId, writeTypePrefix, writeTypeSuffix
-
Field Details
-
SHORT_WRITE
protected static final int SHORT_WRITE- See Also:
-
_ioContext
protected final com.fasterxml.jackson.core.io.IOContext _ioContext -
_out
UnderlyingWriter
used for output. -
_tomlFeatures
private final int _tomlFeatures -
_streamWriteContext
Current context, in form we can use it (GeneratorBase has untyped reference; left as null) -
_outputBuffer
protected char[] _outputBufferIntermediate buffer in which contents are buffered before being written using_out
. -
_outputTail
protected int _outputTailPointer to the next available location in_outputBuffer
-
_outputEnd
protected final int _outputEndOffset to index after the last valid index in_outputBuffer
. Typically same as length of the buffer. -
_basePath
-
-
Constructor Details
-
TomlGenerator
public TomlGenerator(com.fasterxml.jackson.core.io.IOContext ioCtxt, int stdFeatures, int tomlFeatures, com.fasterxml.jackson.core.ObjectCodec codec, Writer out)
-
-
Method Details
-
version
public com.fasterxml.jackson.core.Version version()- Specified by:
version
in interfacecom.fasterxml.jackson.core.Versioned
- Overrides:
version
in classcom.fasterxml.jackson.core.base.GeneratorBase
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classcom.fasterxml.jackson.core.base.GeneratorBase
- Throws:
IOException
-
flush
- Specified by:
flush
in interfaceFlushable
- Specified by:
flush
in classcom.fasterxml.jackson.core.base.GeneratorBase
- Throws:
IOException
-
_releaseBuffers
protected void _releaseBuffers()- Specified by:
_releaseBuffers
in classcom.fasterxml.jackson.core.base.GeneratorBase
-
_flushBuffer
- Throws:
IOException
-
_writeRaw
- Throws:
IOException
-
_writeRaw
- Throws:
IOException
-
_writeRaw
- Throws:
IOException
-
_writeRaw
- Throws:
IOException
-
_writeRawLong
- Throws:
IOException
-
_writeRawLong
- Throws:
IOException
-
currentValue
- Overrides:
currentValue
in classcom.fasterxml.jackson.core.JsonGenerator
-
assignCurrentValue
- Overrides:
assignCurrentValue
in classcom.fasterxml.jackson.core.JsonGenerator
-
canWriteObjectId
public boolean canWriteObjectId()- Overrides:
canWriteObjectId
in classcom.fasterxml.jackson.core.JsonGenerator
-
canWriteTypeId
public boolean canWriteTypeId()- Overrides:
canWriteTypeId
in classcom.fasterxml.jackson.core.JsonGenerator
-
writeFieldName
- Specified by:
writeFieldName
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeStartArray
- Specified by:
writeStartArray
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeStartArray
- Overrides:
writeStartArray
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeEndArray
- Specified by:
writeEndArray
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeStartObject
- Specified by:
writeStartObject
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeStartObject
- Overrides:
writeStartObject
in classcom.fasterxml.jackson.core.base.GeneratorBase
- Throws:
IOException
-
writeEndObject
- Specified by:
writeEndObject
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeString
- Specified by:
writeString
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeString
- Specified by:
writeString
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRawUTF8String
- Specified by:
writeRawUTF8String
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeUTF8String
- Specified by:
writeUTF8String
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRaw
- Specified by:
writeRaw
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRaw
- Specified by:
writeRaw
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRaw
- Specified by:
writeRaw
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRaw
- Specified by:
writeRaw
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeRaw
- Overrides:
writeRaw
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeBinary
public void writeBinary(com.fasterxml.jackson.core.Base64Variant b64variant, byte[] data, int offset, int len) throws IOException - Specified by:
writeBinary
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeBoolean
- Specified by:
writeBoolean
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Overrides:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNumber
- Specified by:
writeNumber
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
writeNull
- Specified by:
writeNull
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-
_verifyValueWrite
- Specified by:
_verifyValueWrite
in classcom.fasterxml.jackson.core.base.GeneratorBase
- Throws:
IOException
-
_verifyValueWrite
- Throws:
IOException
-
writeCurrentPath
- Throws:
IOException
-
writeValueEnd
- Throws:
IOException
-
_appendPropertyName
- Throws:
IOException
-
_writeStringImpl
- Throws:
IOException
-
_writeStringImpl
private void _writeStringImpl(int categoryMask, char[] text, int offset, int len) throws IOException - Throws:
IOException
-
writePOJO
- Overrides:
writePOJO
in classcom.fasterxml.jackson.core.JsonGenerator
- Throws:
IOException
-