From 48c10888b34b2c907e3b9d02882398315b5e0349 Mon Sep 17 00:00:00 2001 From: Luca Frosini Date: Thu, 30 Jan 2020 11:04:58 +0100 Subject: [PATCH] Reorganized model as following Element - EntityElement - Entity - Resource - Facet - Context - EntityType - ResourceType (3 lists of PropertyDefinition, LinkedFacet, LinkedResource) - FacetType (1 list of PropertyDefinition) - RelationElement - Relation - IsRelatedTo - ConsistsOf - IsParentOf - RelationType - IsRelatedTo (1 list of PropertyDefinition) - ConsistsOf (1 list of PropertyDefinition) - PropertyElement - Property - Header - PropagationConstraint - Encrypted - PropertyType (1 list of PropertyDefinition) - PropertyDefinition - LinkedEntity - LinkedFacet - LinkedResource --- .../schema/ResourceRegistrySchemaClient.java | 6 +++--- .../schema/ResourceRegistrySchemaClientImpl.java | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClient.java b/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClient.java index a6f0ccf..4e656aa 100644 --- a/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClient.java +++ b/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClient.java @@ -2,7 +2,7 @@ package org.gcube.informationsystem.resourceregistry.schema; import java.util.List; -import org.gcube.informationsystem.base.reference.ISManageable; +import org.gcube.informationsystem.base.reference.Element; import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException; import org.gcube.informationsystem.resourceregistry.api.exceptions.schema.SchemaException; import org.gcube.informationsystem.resourceregistry.api.exceptions.schema.SchemaNotFoundException; @@ -13,14 +13,14 @@ import org.gcube.informationsystem.types.reference.TypeDefinition; */ public interface ResourceRegistrySchemaClient { - public TypeDefinition create(Class clz) + public TypeDefinition create(Class clz) throws SchemaException, ResourceRegistryException; public String create(String baseType, String typeDefinitition) throws SchemaException, ResourceRegistryException; - public List read(Class clz, Boolean polymorphic) + public List read(Class clz, Boolean polymorphic) throws SchemaNotFoundException, ResourceRegistryException; public String read(String type, Boolean polymorphic) diff --git a/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClientImpl.java b/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClientImpl.java index cccdb8e..88278f1 100644 --- a/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClientImpl.java +++ b/src/main/java/org/gcube/informationsystem/resourceregistry/schema/ResourceRegistrySchemaClientImpl.java @@ -8,7 +8,7 @@ import java.util.Map; import org.gcube.common.gxhttp.reference.GXConnection; import org.gcube.common.gxhttp.request.GXHTTPStringRequest; import org.gcube.informationsystem.base.reference.AccessType; -import org.gcube.informationsystem.base.reference.ISManageable; +import org.gcube.informationsystem.base.reference.Element; import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException; import org.gcube.informationsystem.resourceregistry.api.exceptions.context.ContextAlreadyPresentException; import org.gcube.informationsystem.resourceregistry.api.exceptions.context.ContextNotFoundException; @@ -37,7 +37,7 @@ public class ResourceRegistrySchemaClientImpl implements ResourceRegistrySchemaC } @Override - public TypeDefinition create(Class clz) + public TypeDefinition create(Class clz) throws SchemaException, ResourceRegistryException { try { String typeDefinition = TypeBinder.serializeType(clz); @@ -79,7 +79,7 @@ public class ResourceRegistrySchemaClientImpl implements ResourceRegistrySchemaC @Override - public List read(Class clz, Boolean polymorphic) + public List read(Class clz, Boolean polymorphic) throws SchemaNotFoundException, ResourceRegistryException { try { String type = Utility.getType(clz);