Class JsonValueParser<T>
- java.lang.Object
-
- com.evolveum.midpoint.prism.impl.lex.json.JsonValueParser<T>
-
- All Implemented Interfaces:
ValueParser<T>
public class JsonValueParser<T> extends Object implements ValueParser<T>
-
-
Constructor Summary
Constructors Constructor Description JsonValueParser(com.fasterxml.jackson.core.JsonParser parser, com.fasterxml.jackson.databind.JsonNode node)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.fasterxml.jackson.core.JsonParsergetParser()Map<String,String>getPotentiallyRelevantNamespaces()Returns namespaces that could be relevant when serializing unparsed string value of this item.StringgetStringValue()Returns the value represented as string - in the best format that we can.booleanisEmpty()Tparse(QName typeName, XNodeProcessorEvaluationMode mode)StringtoString()
-
-
-
Method Detail
-
getParser
@NotNull public com.fasterxml.jackson.core.JsonParser getParser()
-
parse
public T parse(QName typeName, XNodeProcessorEvaluationMode mode) throws SchemaException
- Specified by:
parsein interfaceValueParser<T>- Throws:
SchemaException
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfaceValueParser<T>
-
getStringValue
public String getStringValue()
Description copied from interface:ValueParserReturns the value represented as string - in the best format that we can. This has to work even without knowing the exact data type. Therefore there is no guarantee that the returned value will be precise. This method is used as a "last instance" if everything else fails. Invocation of this method will not change the state of the xnode, e.g. it will NOT cause it to be parsed. It can be invoked without any side effects.- Specified by:
getStringValuein interfaceValueParser<T>
-
getPotentiallyRelevantNamespaces
public Map<String,String> getPotentiallyRelevantNamespaces()
Description copied from interface:ValueParserReturns namespaces that could be relevant when serializing unparsed string value of this item. Used to preserve xmlns declarations for QNames and ItemPaths in unparsed data. (MID-2196)- Specified by:
getPotentiallyRelevantNamespacesin interfaceValueParser<T>- Returns:
- May return null if not supported or no namespace declarations are present.
-
-