Top Inners Fields Constructors Methods
com.fasterxml.jackson.dataformat.toml

pack-priv Class Parser

extends Object
Class Inheritance
Imports
com.fasterxml.jackson.core.StreamReadFeature, com.fasterxml.jackson.core.exc.StreamConstraintsException, com.fasterxml.jackson.core.io.IOContext, .NumberInput, com.fasterxml.jackson.core.util.VersionUtil, com.fasterxml.jackson.databind.JsonNode, com.fasterxml.jackson.databind.node.ArrayNode, .JsonNodeFactory, .ObjectNode, .ValueNode, java.io.IOException, .Reader, java.math.BigDecimal, java.time.LocalDate, .LocalDateTime, .LocalTime, .OffsetDateTime, java.time.temporal.Temporal

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
private static class
private static class
private static class

Field Summary

Modifier and TypeField and Description
private final TomlStreamReadException.ErrorContext
private static final JsonNodeFactory
private final Lexer
private static final int
private TomlToken
private final int
private final TomlFactory

Constructor Summary

AccessConstructor and Description
private
Parser(TomlFactory tomlFactory, IOContext ioContext, TomlStreamReadException.ErrorContext errorContext, int options, Reader reader)

Method Summary

Modifier and TypeMethod and Description
pack-priv int
private Parser.TomlArrayNode
private Parser.TomlObjectNode
public static ObjectNode
parse(final IOContext ioContext, final int options, final Reader reader)
Deprecated

public static ObjectNode

Returns:

parsed ObjectNode
parse
(final TomlFactory
factory with configuration
tomlFactory
,
final IOContext
I/O context
ioContext
,
final Reader
character stream
reader
)

public ObjectNode
private Parser.FieldRef
parseAndEnterKey(Parser.TomlObjectNode outer, boolean forTable)

private ArrayNode
parseArray(int nextState)

private JsonNode
parseDateTime(int nextState)

private JsonNode
parseFloat(int nextState)

private ObjectNode
parseInlineTable(int nextState)

private JsonNode
parseInt(int nextState)

private ValueNode
parseIntFromBuffer(char[] buffer, int start, int length)

private void
parseKeyVal(Parser.TomlObjectNode target, int nextState)

private JsonNode
parseValue(int nextState)

private TomlToken
peek()

private TomlToken
poll(int nextState)

Note

Polling also lexes the next token, so methods like Lexer#yytext() will not work afterwards

private void
pollExpected(TomlToken expected, int nextState)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

errorContextback to summary
private final TomlStreamReadException.ErrorContext errorContext
factoryback to summary
private static final JsonNodeFactory factory
lexerback to summary
private final Lexer lexer
MAX_CHARS_TO_REPORTback to summary
private static final int MAX_CHARS_TO_REPORT
nextback to summary
private TomlToken next
optionsback to summary
private final int options
tomlFactoryback to summary
private final TomlFactory tomlFactory

Constructor Detail

Parserback to summary
private Parser(TomlFactory tomlFactory, IOContext ioContext, TomlStreamReadException.ErrorContext errorContext, int options, Reader reader) throws IOException

Method Detail

getNestingDepthback to summary
pack-priv int getNestingDepth()
getOrCreateArrayback to summary
private Parser.TomlArrayNode getOrCreateArray(ObjectNode node, String field) throws TomlStreamReadException
getOrCreateObjectback to summary
private Parser.TomlObjectNode getOrCreateObject(ObjectNode node, String field) throws TomlStreamReadException
parseback to summary
public static ObjectNode parse(final IOContext ioContext, final int options, final Reader reader) throws IOException

Deprecated

Annotations
@Deprecated
parseback to summary
public static ObjectNode parse(final TomlFactory tomlFactory, final IOContext ioContext, final Reader reader) throws IOException
Parameters
tomlFactory:TomlFactory

factory with configuration

ioContext:IOContext

I/O context

reader:Reader

character stream

Returns:ObjectNode

parsed ObjectNode

Exceptions
IOException:
if there are I/O issues
Since
v2.15
parseback to summary
public ObjectNode parse() throws IOException
parseAndEnterKeyback to summary
private Parser.FieldRef parseAndEnterKey(Parser.TomlObjectNode outer, boolean forTable) throws IOException
parseArrayback to summary
private ArrayNode parseArray(int nextState) throws IOException
parseDateTimeback to summary
private JsonNode parseDateTime(int nextState) throws IOException
parseFloatback to summary
private JsonNode parseFloat(int nextState) throws IOException
parseInlineTableback to summary
private ObjectNode parseInlineTable(int nextState) throws IOException
parseIntback to summary
private JsonNode parseInt(int nextState) throws IOException
parseIntFromBufferback to summary
private ValueNode parseIntFromBuffer(char[] buffer, int start, int length) throws TomlStreamReadException
parseKeyValback to summary
private void parseKeyVal(Parser.TomlObjectNode target, int nextState) throws IOException
parseValueback to summary
private JsonNode parseValue(int nextState) throws IOException
peekback to summary
private TomlToken peek() throws TomlStreamReadException
pollback to summary
private TomlToken poll(int nextState) throws IOException

Note

Polling also lexes the next token, so methods like Lexer#yytext() will not work afterwards

pollExpectedback to summary
private void pollExpected(TomlToken expected, int nextState) throws IOException
com.fasterxml.jackson.dataformat.toml back to summary

private Class Parser.FieldRef

extends Object
Class Inheritance

Field Summary

Modifier and TypeField and Description
pack-priv final String
pack-priv final Parser.TomlObjectNode

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

keyback to summary
pack-priv final String key
objectback to summary
pack-priv final Parser.TomlObjectNode object

Constructor Detail

FieldRefback to summary
pack-priv FieldRef(Parser.TomlObjectNode object, String key)
com.fasterxml.jackson.dataformat.toml back to summary

private Class Parser.JsonNodeFactoryImpl

extends JsonNodeFactory
Class Inheritance
Annotations
@SuppressWarnings:serial

Field Summary

Inherited from com.fasterxml.jackson.databind.node.JsonNodeFactory:
instanceMAX_ELEMENT_INDEX_FOR_INSERT

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public ArrayNode
public ArrayNode
arrayNode(int capacity)

Overrides com.fasterxml.jackson.databind.node.JsonNodeFactory.arrayNode.

Implements com.fasterxml.jackson.databind.node.JsonNodeCreator.arrayNode.

Factory method for constructing a JSON Array node with an initial capacity

public ObjectNode
objectNode()

Overrides com.fasterxml.jackson.databind.node.JsonNodeFactory.objectNode.

Implements com.fasterxml.jackson.databind.node.JsonNodeCreator.objectNode.

Factory method for constructing an empty JSON Object ("struct") node

Inherited from com.fasterxml.jackson.databind.node.JsonNodeFactory:
_inIntRangebinaryNodebinaryNodebooleanNodegetMaxElementIndexForInsertmissingNodenullNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodenumberNodepojoNoderawValueNodetextNodewillStripTrailingBigDecimalZeroeswithExactBigDecimals

Constructor Detail

JsonNodeFactoryImplback to summary
public JsonNodeFactoryImpl()

Method Detail

arrayNodeback to summary
public ArrayNode arrayNode()

Overrides com.fasterxml.jackson.databind.node.JsonNodeFactory.arrayNode.

Implements com.fasterxml.jackson.databind.node.JsonNodeCreator.arrayNode.

Doc from com.fasterxml.jackson.databind.node.JsonNodeFactory.arrayNode.

Factory method for constructing an empty JSON Array node

Annotations
@Override
arrayNodeback to summary
public ArrayNode arrayNode(int capacity)

Overrides com.fasterxml.jackson.databind.node.JsonNodeFactory.arrayNode.

Implements com.fasterxml.jackson.databind.node.JsonNodeCreator.arrayNode.

Doc from com.fasterxml.jackson.databind.node.JsonNodeFactory.arrayNode.

Factory method for constructing a JSON Array node with an initial capacity

Annotations
@Override
objectNodeback to summary
public ObjectNode objectNode()

Overrides com.fasterxml.jackson.databind.node.JsonNodeFactory.objectNode.

Implements com.fasterxml.jackson.databind.node.JsonNodeCreator.objectNode.

Doc from com.fasterxml.jackson.databind.node.JsonNodeFactory.objectNode.

Factory method for constructing an empty JSON Object ("struct") node

Annotations
@Override
com.fasterxml.jackson.dataformat.toml back to summary

private Class Parser.TomlArrayNode

extends ArrayNode
Class Inheritance
Annotations
@SuppressWarnings:serial

Field Summary

Modifier and TypeField and Description
pack-priv boolean

Constructor Summary

AccessConstructor and Description
pack-priv
pack-priv
TomlArrayNode(JsonNodeFactory nf, int capacity)

Method Summary

Inherited from com.fasterxml.jackson.databind.node.ArrayNode:
_add_at_childrenEqual_insert_set_withArray_withArrayAddTailElement_withObject_withObjectAddTailElement_withXxxSetArrayElementaddaddaddaddaddaddaddaddaddaddaddaddaddaddaddaddaddaddAlladdAlladdArrayaddNulladdObjectaddPOJOaddRawValueasTokendeepCopyelementsequalsequalsfindParentfindParentsfindValuefindValuesfindValuesAsTextgetgetgetNodeTypehashCodeinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertinsertArrayinsertNullinsertObjectinsertPOJOinsertRawValueisArrayisEmptyisEmptypathpathremoveremoveAllrequiredserializeserializeWithTypesetsetsetsetsetsetsetsetsetsetsetsetsetsetsetsetsetsetNullsetPOJOsetRawValuesizewithwithArray

Field Detail

closedback to summary
pack-priv boolean closed

Constructor Detail

TomlArrayNodeback to summary
pack-priv TomlArrayNode(JsonNodeFactory nf)
TomlArrayNodeback to summary
pack-priv TomlArrayNode(JsonNodeFactory nf, int capacity)
com.fasterxml.jackson.dataformat.toml back to summary

private Class Parser.TomlObjectNode

extends ObjectNode
Class Inheritance
Annotations
@SuppressWarnings:serial

Field Summary

Modifier and TypeField and Description
pack-priv boolean
pack-priv boolean
Inherited from com.fasterxml.jackson.databind.node.ObjectNode:
_children

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Inherited from com.fasterxml.jackson.databind.node.ObjectNode:
_at_childrenEqual_contentsToSerialize_put_withArray_withArrayAddTailProperty_withObject_withObjectAddTailPropertyasTokendeepCopyelementsequalsequalsfieldNamesfieldsfindParentfindParentsfindValuefindValuesfindValuesAsTextgetgetgetNodeTypehashCodeisEmptyisEmptyisObjectpathpathpropertiesputputputputputputputputputputputputputputputputputputAllputAllputArrayputIfAbsentputNullputObjectputPOJOputRawValueremoveremoveremoveAllreplacerequiredretainretainserializeserializeFilteredContentsserializeWithTypesetsetAllsetAllsizewithwithArraywithArrayPropertywithObjectwithObjectPropertywithoutwithout

Field Detail

closedback to summary
pack-priv boolean closed
definedback to summary
pack-priv boolean defined

Constructor Detail

TomlObjectNodeback to summary
pack-priv TomlObjectNode(JsonNodeFactory nc)