Package org.openrefine.importers
Class JsonImporter.JSONTreeReader
- java.lang.Object
-
- org.openrefine.importers.JsonImporter.JSONTreeReader
-
- All Implemented Interfaces:
TreeReader
- Enclosing class:
- JsonImporter
public static class JsonImporter.JSONTreeReader extends Object implements TreeReader
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.openrefine.importers.tree.TreeReader
TreeReader.Token
-
-
Constructor Summary
Constructors Constructor Description JSONTreeReader(InputStream is)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TreeReader.Tokencurrent()intgetAttributeCount()Does nothing.StringgetAttributeLocalName(int index)Does nothing.StringgetAttributePrefix(int index)Does nothing.StringgetAttributeValue(int index)Does nothing.StringgetFieldName()StringgetFieldValue()StringgetPrefix()Does nothing.SerializablegetValue()booleanhasNext()protected TreeReader.TokenmapToToken(com.fasterxml.jackson.core.JsonToken token)TreeReader.Tokennext()
-
-
-
Constructor Detail
-
JSONTreeReader
public JSONTreeReader(InputStream is)
-
-
Method Detail
-
getAttributeCount
public int getAttributeCount()
Does nothing. All Json is treated as elements- Specified by:
getAttributeCountin interfaceTreeReader
-
getAttributeLocalName
public String getAttributeLocalName(int index)
Does nothing. All Json is treated as elements- Specified by:
getAttributeLocalNamein interfaceTreeReader
-
getAttributePrefix
public String getAttributePrefix(int index)
Does nothing. All Json is treated as elements- Specified by:
getAttributePrefixin interfaceTreeReader
-
getAttributeValue
public String getAttributeValue(int index)
Does nothing. All Json is treated as elements- Specified by:
getAttributeValuein interfaceTreeReader
-
current
public TreeReader.Token current()
- Specified by:
currentin interfaceTreeReader
-
getFieldName
public String getFieldName() throws TreeReaderException
- Specified by:
getFieldNamein interfaceTreeReader- Throws:
TreeReaderException
-
getPrefix
public String getPrefix()
Does nothing. Json does not have prefixes- Specified by:
getPrefixin interfaceTreeReader
-
getFieldValue
public String getFieldValue() throws TreeReaderException
- Specified by:
getFieldValuein interfaceTreeReader- Throws:
TreeReaderException
-
getValue
public Serializable getValue() throws TreeReaderException
- Specified by:
getValuein interfaceTreeReader- Throws:
TreeReaderException
-
hasNext
public boolean hasNext()
- Specified by:
hasNextin interfaceTreeReader
-
next
public TreeReader.Token next() throws TreeReaderException
- Specified by:
nextin interfaceTreeReader- Throws:
TreeReaderException
-
mapToToken
protected TreeReader.Token mapToToken(com.fasterxml.jackson.core.JsonToken token)
-
-