public class JsonReader extends XmlReader
XmlReader.DuplicateFieldPolicy
DataEndpoint.State
currentRecord, fields, hasCascadingFields, reader, recordBreaks
fieldLineage, recordLineage
lastRecord, PRODUCT, PRODUCT_VERSION, VENDOR, XML_INPUT_FACTORY_KEY
BUFFER_SIZE, captureElapsedTime, DEFAULT_READ_BUFFER_SIZE
id, log, name, TIMESTAMP_FORMAT
Constructor and Description |
---|
JsonReader(File file) |
JsonReader(Reader reader) |
Modifier and Type | Method and Description |
---|---|
DataException |
addExceptionProperties(DataException exception)
Adds this endpoint's current state to a
DataException . |
JsonReader |
addField(String name,
String locationPathAsString)
Identifies a new field using XPath in the XML stream.
|
JsonReader |
addField(String name,
String locationPathAsString,
boolean cascadeValues)
Identifies a new field using XPath in the XML stream.
|
JsonReader |
addField(String name,
String locationPathAsString,
String cascadeResetLocationPath)
Identifies a new field using XPath in the XML stream.
|
JsonReader |
addField(XmlField field) |
protected Record |
addLineage(Record record) |
JsonReader |
addRecordBreak(String locationPathAsString) |
boolean |
isUseBigDecimal() |
JsonReader |
setAddTextToParent(boolean addTextToParent)
Indicates if each child node's text should be concatenated to its parent during parsing (defaults to false).
|
JsonReader |
setAutoCloseReader(boolean autoCloseReader) |
JsonReader |
setDebug(boolean debug) |
JsonReader |
setDescription(String description) |
JsonReader |
setDuplicateFieldPolicy(XmlReader.DuplicateFieldPolicy duplicateFieldPolicy) |
JsonReader |
setIgnoreNamespaces(boolean ignoreNamespaces)
Indicates if namespaces on elements and attributes are ignored when matching expressions (default to true).
|
JsonReader |
setSaveLineage(boolean saveLineage) |
JsonReader |
setUseBigDecimal(boolean useBigDecimal) |
JsonReader |
useBigDecimal(boolean useBigDecimal)
Deprecated.
Use
setUseBigDecimal(boolean) method instead. |
addFieldValue, close, createRecord, expandAndPushRecords, expandListFieldsAsFields, getDuplicateFieldPolicy, getFieldValues, getXmlNodeReader, isAddTextToParent, isAutoCloseReader, isDebug, isIgnoreNamespaces, isLineageSupported, isRecordBreak, open, readImpl, saveAncestorAttributeFieldValues, saveAncestorNodeFieldValues, saveFieldValues, setRecordField
available, getBufferSize, getNestedEndpoint, getNestedReader, getRootEndpoint, getRootReader, isExhausted, isSaveLineage, peek, pop, push, read, skip
decrementRecordCount, enableJmx, getLastRecord, getRecordCount, getRecordCountAsBigInteger, getRecordCountAsString, incrementRecordCount, isRecordCountBigInteger, resetRecordCount, toString
addElapsedtime, assertClosed, assertNotOpened, assertOpened, finalize, getClosedOn, getDescription, getElapsedTime, getElapsedTimeAsString, getOpenedOn, getOpenElapsedTime, getOpenElapsedTimeAsString, getSelfTime, getSelfTimeAsString, getState, isCaptureElapsedTime, isClosed, isOpen, setCaptureElapsedTime
public JsonReader(File file)
public JsonReader(Reader reader)
public boolean isUseBigDecimal()
@Deprecated public JsonReader useBigDecimal(boolean useBigDecimal)
setUseBigDecimal(boolean)
method instead.public JsonReader setUseBigDecimal(boolean useBigDecimal)
public JsonReader setAutoCloseReader(boolean autoCloseReader)
setAutoCloseReader
in class XmlReader
public JsonReader setDebug(boolean debug)
public JsonReader setAddTextToParent(boolean addTextToParent)
XmlReader
true
will
result in higher memory consumption.setAddTextToParent
in class XmlReader
public JsonReader addRecordBreak(String locationPathAsString)
addRecordBreak
in class XmlReader
public JsonReader addField(XmlField field)
public JsonReader addField(String name, String locationPathAsString, boolean cascadeValues)
XmlReader
public JsonReader addField(String name, String locationPathAsString, String cascadeResetLocationPath)
XmlReader
cascadeResetLocationPath
is not null and not empty, it will indicate when this
field should be cleared, otherwise this field will return the last value seen when no new matches are available.public JsonReader addField(String name, String locationPathAsString)
XmlReader
public JsonReader setDuplicateFieldPolicy(XmlReader.DuplicateFieldPolicy duplicateFieldPolicy)
setDuplicateFieldPolicy
in class XmlReader
public JsonReader setIgnoreNamespaces(boolean ignoreNamespaces)
XmlReader
setIgnoreNamespaces
in class XmlReader
public JsonReader setSaveLineage(boolean saveLineage)
setSaveLineage
in class XmlReader
public JsonReader setDescription(String description)
setDescription
in class XmlReader
protected Record addLineage(Record record)
addLineage
in class XmlReader
public DataException addExceptionProperties(DataException exception)
Endpoint
DataException
. Since this method is called whenever an
exception is thrown, subclasses should override it to add their specific information.addExceptionProperties
in class XmlReader
Copyright (c) 2006-2024 North Concepts Inc. All Rights Reserved.