Package com.fasterxml.jackson.jr.ob.impl
Class EnumReader
- java.lang.Object
-
- com.fasterxml.jackson.jr.ob.impl.ValueReader
-
- com.fasterxml.jackson.jr.ob.impl.EnumReader
-
public class EnumReader extends ValueReader
Reader for Enum values: needed because we need a simpleMap
for efficient conversion from id (gotten withEnum.toString()
to value.In future we could consider alternatively allowing use of
Enum.name()
for id.
-
-
Constructor Summary
Constructors Constructor Description EnumReader(Object[] byIndex, Map<String,Object> byName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
read(JSONReader reader, com.fasterxml.jackson.core.JsonParser p)
Object
readNext(JSONReader reader, com.fasterxml.jackson.core.JsonParser p)
-
Methods inherited from class com.fasterxml.jackson.jr.ob.impl.ValueReader
_tokenDesc, _tokenDesc
-
-
-
-
Method Detail
-
readNext
public Object readNext(JSONReader reader, com.fasterxml.jackson.core.JsonParser p) throws IOException
- Specified by:
readNext
in classValueReader
- Throws:
IOException
-
read
public Object read(JSONReader reader, com.fasterxml.jackson.core.JsonParser p) throws IOException
- Specified by:
read
in classValueReader
- Throws:
IOException
-
-