Interface IBoundInstanceModelChoiceGroup
- All Superinterfaces:
IBoundInstance<IBoundObject>,IBoundInstanceModel<IBoundObject>,IBoundModelElement,IBoundModelObject<IBoundObject>,IBoundProperty<IBoundObject>,IChoiceGroupInstance,IContainer,IContainerModel,IContainerModelGrouped,IDefaultable,IFeatureContainerModelGrouped<IBoundInstanceModelGroupedNamed,,IBoundInstanceModelGroupedField, IBoundInstanceModelGroupedAssembly> IFeatureJavaField,IGroupable,IInstance,IInstanceAbsolute,IItemValueHandler<IBoundObject>,IJsonInstance,IJsonNamed,IModelElement,IModelElementVisitable,IModelInstance,IModelInstanceAbsolute,IValued,IValuedMutable
public interface IBoundInstanceModelChoiceGroup
extends IBoundInstanceModel<IBoundObject>, IFeatureContainerModelGrouped<IBoundInstanceModelGroupedNamed,IBoundInstanceModelGroupedField,IBoundInstanceModelGroupedAssembly>, IChoiceGroupInstance
Represents a choice group instance bound to Java field.
-
Field Summary
Fields inherited from interface gov.nist.secauto.metaschema.core.model.IChoiceGroupInstance
DEFAULT_CHOICE_GROUP_GROUP_AS_MAX_OCCURS, DEFAULT_JSON_DISCRIMINATOR_PROPERTY_NAMEFields inherited from interface gov.nist.secauto.metaschema.core.model.IGroupable
DEFAULT_GROUP_AS_MAX_OCCURS, DEFAULT_GROUP_AS_MIN_OCCURS, DEFAULT_JSON_GROUP_AS_BEHAVIOR, DEFAULT_XML_GROUP_AS_BEHAVIOR -
Method Summary
Modifier and TypeMethodDescriptiondefault booleancanHandleXmlQName(IEnhancedQName qname) Determine if the provided XML qualified name is associated with this property.default IBoundObjectdeepCopyItem(IBoundObject item, IBoundObject parentInstance) Create and return a deep copy of the provided item.default IBoundDefinitionModelAssemblyGet the bound grouped model instance associated with the provided XML qualified name.getGroupedModelInstance(Class<?> clazz) Get the bound grouped model instance associated with the provided Java class.getGroupedModelInstance(String discriminator) Get the bound grouped model instance associated with the provided JSON discriminator value.default IBoundInstanceModelGroupedNamedgetItemInstance(Object item) Get the bound grouped model instance associated with the provided item.default StringnewInstance(Field field, IBoundDefinitionModelAssembly containingDefinition) Create a new bound choice group instance.default IBoundObjectreadItem(IBoundObject parent, IItemReadHandler handler) Parse and return an item.default voidwriteItem(IBoundObject item, IItemWriteHandler handler) Write the provided item.Methods inherited from interface gov.nist.secauto.metaschema.databind.model.IBoundInstance
getContainingModule, getValue, setValueMethods inherited from interface gov.nist.secauto.metaschema.databind.model.IBoundInstanceModel
deepCopy, getCollectionInfo, getItemJsonKey, getItemValues, getResolvedDefaultValueMethods inherited from interface gov.nist.secauto.metaschema.core.model.IChoiceGroupInstance
accept, getJsonDiscriminatorProperty, getJsonKeyFlagInstanceName, getMaxOccurs, getModelType, getRemarks, isEffectiveValueWrappedInXml, toCoordinatesMethods inherited from interface gov.nist.secauto.metaschema.core.model.IDefaultable
getDefaultValue, getEffectiveDefaultValueMethods inherited from interface gov.nist.secauto.metaschema.core.model.IFeatureContainerModelGrouped
getAssemblyInstanceByName, getAssemblyInstances, getFieldInstanceByName, getFieldInstances, getModelContainer, getModelInstances, getNamedModelInstanceByName, getNamedModelInstances, hasChildrenMethods inherited from interface gov.nist.secauto.metaschema.databind.model.IFeatureJavaField
getField, getItemType, getTypeMethods inherited from interface gov.nist.secauto.metaschema.core.model.IGroupable
getEffectiveXmlGroupAsQName, getGroupAsName, getJsonGroupAsBehavior, getMinOccurs, getXmlGroupAsBehaviorMethods inherited from interface gov.nist.secauto.metaschema.core.model.IModelInstance
getParentContainer
-
Method Details
-
newInstance
@NonNull static IBoundInstanceModelChoiceGroup newInstance(@NonNull Field field, @NonNull IBoundDefinitionModelAssembly containingDefinition) Create a new bound choice group instance.- Parameters:
field- the Java field the instance is bound tocontainingDefinition- the definition containing the instance- Returns:
- the new instance
-
getJsonName
- Specified by:
getJsonNamein interfaceIChoiceGroupInstance- Specified by:
getJsonNamein interfaceIJsonInstance- Specified by:
getJsonNamein interfaceIJsonNamed
-
getOwningDefinition
- Specified by:
getOwningDefinitionin interfaceIContainerModel- Specified by:
getOwningDefinitionin interfaceIContainerModelGrouped
-
getContainingDefinition
- Specified by:
getContainingDefinitionin interfaceIBoundInstance<IBoundObject>- Specified by:
getContainingDefinitionin interfaceIBoundInstanceModel<IBoundObject>- Specified by:
getContainingDefinitionin interfaceIInstance- Specified by:
getContainingDefinitionin interfaceIModelInstance
-
getGroupedModelInstance
Get the bound grouped model instance associated with the provided Java class.- Parameters:
clazz- the Java class which should be bound to a grouped model instance- Returns:
- the grouped model instance or {code null} if no instance was bound to the requested class
-
getGroupedModelInstance
Get the bound grouped model instance associated with the provided XML qualified name.- Parameters:
name- the XML qualified name which should be bound to a grouped model instance- Returns:
- the grouped model instance or {code null} if no instance was bound to the requested XML qualified name
-
getGroupedModelInstance
Get the bound grouped model instance associated with the provided JSON discriminator value.- Parameters:
discriminator- the JSON discriminator value which should be bound to a grouped model instance- Returns:
- the grouped model instance or {code null} if no instance was bound to the requested JSON discriminator value
-
getItemInstance
Get the bound grouped model instance associated with the provided item.- Specified by:
getItemInstancein interfaceIChoiceGroupInstance- Parameters:
item- the item which should be bound to a grouped model instance- Returns:
- the grouped model instance or {code null} if no instance was bound to the requested item
-
readItem
Description copied from interface:IItemValueHandlerParse and return an item.- Specified by:
readItemin interfaceIItemValueHandler<IBoundObject>- Parameters:
parent- the parent Java object to use for serialization callbacks, ornullif there is no parenthandler- the item parsing handler- Returns:
- the Java object representing the parsed item
- Throws:
IOException- if an error occurred while parsing
-
writeItem
Description copied from interface:IItemValueHandlerWrite the provided item.- Specified by:
writeItemin interfaceIItemValueHandler<IBoundObject>- Parameters:
item- the data to writehandler- the item writing handler- Throws:
IOException- if an error occurred while writing
-
deepCopyItem
default IBoundObject deepCopyItem(IBoundObject item, IBoundObject parentInstance) throws BindingException Description copied from interface:IItemValueHandlerCreate and return a deep copy of the provided item.- Specified by:
deepCopyItemin interfaceIItemValueHandler<IBoundObject>- Parameters:
item- the item to copyparentInstance- an optional parent object to use for serialization callbacks- Returns:
- the new deep copy
- Throws:
BindingException- if an error occurred while analyzing the bound objects
-
canHandleXmlQName
Description copied from interface:IBoundModelObjectDetermine if the provided XML qualified name is associated with this property.- Specified by:
canHandleXmlQNamein interfaceIBoundModelObject<IBoundObject>- Parameters:
qname- the XML qualified name of the property being parsed- Returns:
trueif the instance will handle this name, orfalseotherwise
-