Module dev.metaschema.core
Package dev.metaschema.core.model
Class AbstractContainerModelSupport<MI extends IModelInstance,NMI extends INamedModelInstance,FI extends IFieldInstance,AI extends IAssemblyInstance>
java.lang.Object
dev.metaschema.core.model.AbstractContainerModelSupport<MI,NMI,FI,AI>
- Type Parameters:
MI- the model instance Java typeNMI- the named model instance Java typeFI- the field instance Java typeAI- the assembly instance Java type
- All Implemented Interfaces:
IContainerModelSupport<MI,NMI, FI, AI>
public abstract class AbstractContainerModelSupport<MI extends IModelInstance,NMI extends INamedModelInstance,FI extends IFieldInstance,AI extends IAssemblyInstance>
extends Object
implements IContainerModelSupport<MI,NMI,FI,AI>
Supports model instance operations on assembly model instances.
This implementation uses underlying LinkedHashMap instances to
preserve ordering.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet a mapping of all assembly instances, mapped from their effective name to the instance.Get a mapping of all field instances, mapped from their effective name to the instance.Get a mapping of all named model instances, mapped from their effective name to the instance.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface dev.metaschema.core.model.IContainerModelSupport
getModelInstances
-
Constructor Details
-
AbstractContainerModelSupport
public AbstractContainerModelSupport()Construct an empty, mutable container. -
AbstractContainerModelSupport
protected AbstractContainerModelSupport(@NonNull Map<Integer, NMI> namedModelInstances, @NonNull Map<Integer, FI> fieldInstances, @NonNull Map<Integer, AI> assemblyInstances) Construct an new container using the provided collections.- Parameters:
namedModelInstances- a collection of named model instancesfieldInstances- a collection of field instancesassemblyInstances- a collection of assembly instances
-
-
Method Details
-
getNamedModelInstanceMap
Description copied from interface:IContainerModelSupportGet a mapping of all named model instances, mapped from their effective name to the instance.- Specified by:
getNamedModelInstanceMapin interfaceIContainerModelSupport<MI extends IModelInstance,NMI extends INamedModelInstance, FI extends IFieldInstance, AI extends IAssemblyInstance> - Returns:
- the mapping
-
getFieldInstanceMap
Description copied from interface:IContainerModelSupportGet a mapping of all field instances, mapped from their effective name to the instance.- Specified by:
getFieldInstanceMapin interfaceIContainerModelSupport<MI extends IModelInstance,NMI extends INamedModelInstance, FI extends IFieldInstance, AI extends IAssemblyInstance> - Returns:
- the mapping
-
getAssemblyInstanceMap
Description copied from interface:IContainerModelSupportGet a mapping of all assembly instances, mapped from their effective name to the instance.- Specified by:
getAssemblyInstanceMapin interfaceIContainerModelSupport<MI extends IModelInstance,NMI extends INamedModelInstance, FI extends IFieldInstance, AI extends IAssemblyInstance> - Returns:
- the mapping
-