package org.gcube.informationsystem.resourceregistry.publisher.proxy; import java.util.UUID; import org.gcube.informationsystem.model.entity.Facet; import org.gcube.informationsystem.model.entity.Resource; import org.gcube.informationsystem.model.relation.ConsistsOf; import org.gcube.informationsystem.model.relation.IsRelatedTo; import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException; import org.gcube.informationsystem.resourceregistry.api.exceptions.context.ContextNotFoundException; import org.gcube.informationsystem.resourceregistry.api.exceptions.entity.FacetNotFoundException; import org.gcube.informationsystem.resourceregistry.api.exceptions.entity.ResourceNotFoundException; /** * @author Luca Frosini (ISTI - CNR) */ public interface ResourceRegistryPublisher { public F createFacet(Class facetClass, F facet); public F updateFacet(Class facetClass, F facet); public boolean deleteFacet(F facet); public R createResource(Class resourceClass, R resource); public boolean deleteResource(R resource); public > C createConsistsOf( Class consistsOfClass, C consistsOf); public > boolean deleteConsistsOf( C consistsOf); public > I createIsRelatedTo( Class isRelatedToClass, I isRelatedTo); public > boolean deleteIsRelatedTo( I isRelatedTo); public boolean addResourceToContext(UUID uuid) throws ResourceNotFoundException, ContextNotFoundException, ResourceRegistryException; public boolean addResourceToContext(R resource) throws ResourceNotFoundException, ContextNotFoundException, ResourceRegistryException; public boolean addFacetToContext(UUID uuid) throws FacetNotFoundException, ContextNotFoundException, ResourceRegistryException; public boolean addFacetToContext(F facet) throws FacetNotFoundException, ContextNotFoundException, ResourceRegistryException; }