Class DefaultJsonProblemHandler
java.lang.Object
gov.nist.secauto.metaschema.databind.io.AbstractProblemHandler
gov.nist.secauto.metaschema.databind.io.json.DefaultJsonProblemHandler
- All Implemented Interfaces:
IProblemHandler,IJsonProblemHandler
public class DefaultJsonProblemHandler
extends AbstractProblemHandler
implements IJsonProblemHandler
This problem handler implementation handles common issues when parsing
JSON-based Metaschema module instances.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanhandleUnknownProperty(IBoundDefinitionModelComplex classBinding, IBoundObject targetObject, String fieldName, IJsonParsingContext parsingContext) Callback used to handle a JSON property that is unknown to the model being parsed.Methods inherited from class gov.nist.secauto.metaschema.databind.io.AbstractProblemHandler
applyDefaults, handleMissingInstancesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface gov.nist.secauto.metaschema.databind.io.IProblemHandler
handleMissingInstances
-
Constructor Details
-
DefaultJsonProblemHandler
public DefaultJsonProblemHandler()
-
-
Method Details
-
handleUnknownProperty
public boolean handleUnknownProperty(IBoundDefinitionModelComplex classBinding, IBoundObject targetObject, String fieldName, IJsonParsingContext parsingContext) throws IOException Description copied from interface:IJsonProblemHandlerCallback used to handle a JSON property that is unknown to the model being parsed.- Specified by:
handleUnknownPropertyin interfaceIJsonProblemHandler- Parameters:
classBinding- the bound class currently describing the data being parsedtargetObject- the Java object for theparentDefinitionfieldName- the unknown JSON field nameparsingContext- the JSON parsing context used for parsing- Returns:
trueif the attribute was handled by this method, orfalseotherwise- Throws:
IOException- if an error occurred while handling the unrecognized data
-