java.lang.Object
org.gcube.informationsystem.resourceregistry.types.TypeManagement

public class TypeManagement extends Object
Author:
Luca Frosini (ISTI - CNR)
  • Field Details

    • typeName

      protected String typeName
    • json

      protected String json
    • type

      protected org.gcube.informationsystem.types.reference.Type type
    • skipVersionCheckOnUpdate

      protected boolean skipVersionCheckOnUpdate
    • skipTypeDefinitionCreation

      protected boolean skipTypeDefinitionCreation
    • typeList

      public static Set<String> typeList
  • Constructor Details

    • TypeManagement

      public TypeManagement()
  • Method Details

    • isSkipVersionCheckOnUpdate

      public boolean isSkipVersionCheckOnUpdate()
    • setSkipVersionCheckOnUpdate

      public void setSkipVersionCheckOnUpdate(boolean skipVersionCheckOnUpdate)
    • isSkipTypeDefinitionCreation

      public boolean isSkipTypeDefinitionCreation()
    • setSkipTypeDefinitionCreation

      public void setSkipTypeDefinitionCreation(boolean skipTypeDefinitionCreation)
    • setJson

      public void setJson(String json) throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
    • getOClass

      protected com.orientechnologies.orient.core.metadata.schema.OClass getOClass(com.orientechnologies.orient.core.metadata.schema.OSchema oSchema, String typeName) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • getTypeName

      public String getTypeName()
    • setTypeName

      public void setTypeName(String typeName)
    • setTypeAndTypeName

      public void setTypeAndTypeName(Class<? extends org.gcube.informationsystem.base.reference.Element> clz) throws Exception
      Throws:
      Exception
    • getType

      public org.gcube.informationsystem.types.reference.Type getType()
    • getTypeManagement

      public static ElementManagement<?,?> getTypeManagement(com.orientechnologies.orient.core.metadata.schema.OClass oClass)
    • getSuperclassesAndCheckCompliancy

      protected List<com.orientechnologies.orient.core.metadata.schema.OClass> getSuperclassesAndCheckCompliancy(com.orientechnologies.orient.core.db.document.ODatabaseDocument oDatabaseDocument, org.gcube.informationsystem.types.reference.Type type, String baseType) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
    • registerTypeSchema

      protected void registerTypeSchema() throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaAlreadyPresentException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaAlreadyPresentException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • updateTypeSchema

      protected void updateTypeSchema(org.gcube.informationsystem.types.reference.Type actualTypeDefinition, org.gcube.informationsystem.types.reference.Type newTypeDefinition, org.gcube.informationsystem.base.reference.AccessType baseElementAccessType) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • getSchema

      protected List<org.gcube.informationsystem.types.reference.Type> getSchema(boolean includeSubtypes) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • create

      public String create() throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaAlreadyPresentException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaAlreadyPresentException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • read

      public List<org.gcube.informationsystem.types.reference.Type> read(boolean includeSubtypes) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • update

      public String update() throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
    • delete

      protected boolean delete(org.gcube.informationsystem.base.reference.AccessType accessType) throws org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException, org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException
      Throws:
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaException
      org.gcube.informationsystem.resourceregistry.api.exceptions.types.SchemaNotFoundException