Class ConsistsOfSchemaManagement
java.lang.Object
org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.ElementManagement<com.orientechnologies.orient.core.record.OEdge,org.gcube.informationsystem.types.reference.relations.RelationSchema<SET,TET>>
org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.RelationElementManagement<ResourceSchemaManagement,T,org.gcube.informationsystem.types.reference.entities.ResourceSchema,TT>
org.gcube.informationsystem.resourceregistry.persistence.orientdb.types.relations.AbstractRelationSchemaManagement<FacetSchemaManagement,org.gcube.informationsystem.types.reference.entities.FacetSchema>
org.gcube.informationsystem.resourceregistry.persistence.orientdb.types.relations.ConsistsOfSchemaManagement
- All Implemented Interfaces:
TypeDefinitionManagement
public class ConsistsOfSchemaManagement
extends AbstractRelationSchemaManagement<FacetSchemaManagement,org.gcube.informationsystem.types.reference.entities.FacetSchema>
Manages the ConsistsOfSchema relation type definition in the database schema.
- Author:
- Luca Frosini (ISTI - CNR)
-
Field Summary
Fields inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.types.relations.AbstractRelationSchemaManagement
nameFields inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.RelationElementManagement
IN, includeSource, includeTarget, OUT, sourceEntityClass, sourceEntityManagement, targetEntityClass, targetEntityManagementFields inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.ElementManagement
accessType, affectedInstances, AT, cachedType, complete, DELETED, DOLLAR, dryRun, element, elementClass, entryPoint, ignoreKeys, ignoreStartWithKeys, jsonNode, limit, logger, maskMetadata, metadataPolicy, oClass, oDatabaseDocument, offset, operation, polymorphic, preservePassedMetadata, reload, sanityCheckDeferred, self, typeName, UNDERSCORE, updateMode, uuid, workingEnvironment -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new, uninitializedConsistsOfSchemaManagementinstance.ConsistsOfSchemaManagement(TypeEnvironment typeEnvironment, com.orientechnologies.orient.core.db.document.ODatabaseDocument oDatabaseDocument) Creates a newConsistsOfSchemaManagementinstance bound to the specified environment and database session. -
Method Summary
Modifier and TypeMethodDescriptionprotected FacetSchemaManagementCreates a new management instance for the target entity of the relation (subclass hook).voidPerforms runtime validation of mandatory and not-null schema constraints that cannot be enforced directly by OrientDB in distributed mode.Methods inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.types.relations.AbstractRelationSchemaManagement
checksourceAndTargetEntityCompliancy, createCompleteJsonNode, getAffectedInstances, getElement, getName, getSpecificAlreadyPresentException, getSpecificNotFoundException, getWorkingEnvironment, newSourceEntityManagement, reallyCreate, reallyDelete, reallyGetAll, reallyUpdate, retrieveElement, setNameMethods inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.RelationElementManagement
getSourceEntityManagement, getTargetEntityManagement, includeSource, includeTarget, setSourceEntityManagement, setTargetEntityManagementMethods inherited from class org.gcube.informationsystem.resourceregistry.persistence.orientdb.base.ElementManagement
all, applyPrivacyMask, applyPrivacyMask, checkERMatch, checkJsonNode, checkUUIDMatch, checkUUIDNotAlreadyInUse, cleanCachedSerialization, concludeTransaction, create, createOrUpdate, createOrUpdateElementWithResult, delete, exists, getAccessType, getAllProperties, getCachedType, getCurrentODatabaseDocumentFromThreadLocal, getLimit, getMandatoryErrorMessage, getMandatoryErrorMessage, getMetadataPolicy, getOClass, getOffset, getPropertyForJson, getPropertyMap, getTypeName, getUpdateMode, getUUID, internalCreate, internalCreateOrUdate, internalDelete, internalUpdate, isDryRun, isMaskMetadata, isPolymorphic, isPreservePassedMetadata, isReload, isSanityCheckDeferred, read, requireExplicitUUID, retrieveElementFromAnyContext, serializeAsAffectedInstance, serializeAsJsonNode, serializeSelfAsJsonNode, setAsEntryPoint, setDryRun, setElement, setElementType, setJson, setJsonNode, setLimit, setMaskMetadata, setMetadataPolicy, setOClass, setODatabaseDocument, setOffset, setOperation, setPolymorphic, setPreservePassedMetadata, setProperty, setReload, setRequireExplicitUUID, setSanityCheckDeferred, setUpdateMode, setUUID, setWorkingEnvironment, typeSatified, update, updateProperties
-
Constructor Details
-
ConsistsOfSchemaManagement
public ConsistsOfSchemaManagement()Creates a new, uninitializedConsistsOfSchemaManagementinstance. -
ConsistsOfSchemaManagement
public ConsistsOfSchemaManagement(TypeEnvironment typeEnvironment, com.orientechnologies.orient.core.db.document.ODatabaseDocument oDatabaseDocument) throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException Creates a newConsistsOfSchemaManagementinstance bound to the specified environment and database session.- Parameters:
typeEnvironment- the Type environment to useoDatabaseDocument- the active OrientDB database session- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- if initialization fails
-
-
Method Details
-
newTargetEntityManagement
protected FacetSchemaManagement newTargetEntityManagement() throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryExceptionDescription copied from class:RelationElementManagementCreates a new management instance for the target entity of the relation (subclass hook).- Specified by:
newTargetEntityManagementin classRelationElementManagement<ResourceSchemaManagement,FacetSchemaManagement, org.gcube.informationsystem.types.reference.entities.ResourceSchema, org.gcube.informationsystem.types.reference.entities.FacetSchema> - Returns:
- the target entity management instance
- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- on database or lookup error
-
sanityCheck
public void sanityCheck() throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaViolationException, org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryExceptionDescription copied from class:ElementManagementPerforms runtime validation of mandatory and not-null schema constraints that cannot be enforced directly by OrientDB in distributed mode.- Overrides:
sanityCheckin classElementManagement<com.orientechnologies.orient.core.record.OEdge,org.gcube.informationsystem.types.reference.relations.RelationSchema<org.gcube.informationsystem.types.reference.entities.ResourceSchema, org.gcube.informationsystem.types.reference.entities.FacetSchema>> - Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaViolationException- if a schema constraint is violatedorg.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- on database lookup failure
-