package org.gcube.informationsystem.resourceregistry.schema; import org.gcube.informationsystem.resourceregistry.api.exceptions.schema.SchemaException; import org.gcube.informationsystem.resourceregistry.api.exceptions.schema.SchemaNotFoundException; /** * @author Luca Frosini (ISTI - CNR) * * For JSON schema see * http://orientdb.com/docs/last/OrientDB-REST.html#class * */ public interface SchemaManagement { public String registerEntitySchema(String jsonSchema) throws SchemaException; public String getEntitySchema(String entityType) throws SchemaNotFoundException; public String updateEntitySchema(String entityType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteEntitySchema(String entityType) throws SchemaNotFoundException; public String getEntityTypes(String entityType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerFacetSchema(String jsonSchema) throws SchemaException; public String getFacetSchema(String facetType) throws SchemaNotFoundException; public String updateFacetSchema(String facetType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteFacetSchema(String facetType) throws SchemaNotFoundException; public String getFacetTypes(String facetType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerResourceSchema(String jsonSchema) throws SchemaException; public String getResourceSchema(String resourceType) throws SchemaNotFoundException; public String updateResourceSchema(String resourceType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteResourceSchema(String resourceType) throws SchemaNotFoundException; public String getResourceTypes(String resourceType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerEmbeddedTypeSchema(String jsonSchema) throws SchemaException; public String getEmbeddedTypeSchema(String embeddedType) throws SchemaNotFoundException; public String updateEmbeddedTypeSchema(String embeddedType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteEmbeddedTypeSchema(String embeddedType) throws SchemaNotFoundException; public String getEmbeddedTypes(String embeddedType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerRelationSchema(String jsonSchema) throws SchemaException; public String getRelationSchema(String relationType) throws SchemaNotFoundException; public String updateRelationSchema(String relationType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteRelationSchema(String relationType) throws SchemaNotFoundException; public String getRelationTypes(String relationType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerConsistsOfSchema(String jsonSchema) throws SchemaException; public String getConsistsOfSchema(String consistsOfType) throws SchemaNotFoundException; public String updateConsistsOfSchema(String consistsOfType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteConsistsOfSchema(String consistsOfType) throws SchemaException; public String getConsistsOfTypes(String consistsOfType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; public String registerIsRelatedToSchema(String jsonSchema) throws SchemaException; public String getIsRelatedToSchema(String isRelatedToType) throws SchemaNotFoundException; public String updateIsRelatedToSchema(String isRelatedToType, String jsonSchema) throws SchemaNotFoundException, SchemaException; public String deleteIsRelatedToSchema(String isRelatedToType) throws SchemaException; public String getIsRelatedToTypes(String isRelatedToType, boolean includeSchema) throws SchemaNotFoundException, SchemaException; }