Class InstancesManager
- java.lang.Object
-
- org.gcube.informationsystem.resourceregistry.rest.BaseRest
-
- org.gcube.informationsystem.resourceregistry.rest.InstancesManager
-
@Path("instances") public class InstancesManager extends BaseRest- Author:
- Luca Frosini (ISTI - CNR)
-
-
Field Summary
Fields Modifier and Type Field Description static StringUUID_PATH_PARAMETER
-
Constructor Summary
Constructors Constructor Description InstancesManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.Responsedelete(String type, String uuid)javax.ws.rs.core.Responseexists(String type, String uuid)StringgetInstanceContexts(String type, String instanceId, String contextId)Stringread(String type, String uuid)StringreadAll(String type, Boolean polymorphic)StringupdateOrCreate(String type, String uuid, String json)-
Methods inherited from class org.gcube.informationsystem.resourceregistry.rest.BaseRest
checkHierarchicalMode, checkIncludeInstancesContexts, isRequesterAllowedToPerformHierarchicalRequests, isRequesterAllowedToRequestInstancesContexts
-
-
-
-
Field Detail
-
UUID_PATH_PARAMETER
public static final String UUID_PATH_PARAMETER
- See Also:
- Constant Field Values
-
-
Method Detail
-
readAll
@GET @Path("/{TYPE_NAME}") @Consumes({"text/plain","application/json;charset=UTF-8"}) @Produces("application/json;charset=UTF-8") public String readAll(@PathParam("TYPE_NAME") String type, @QueryParam("polymorphic") @DefaultValue("true") Boolean polymorphic) throws org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundExceptionorg.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
exists
@HEAD @Path("/{TYPE_NAME}/{UUID}") @Consumes({"text/plain","application/json;charset=UTF-8"}) @Produces("application/json;charset=UTF-8") public javax.ws.rs.core.Response exists(@PathParam("TYPE_NAME") String type, @PathParam("UUID") String uuid) throws org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundExceptionorg.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
read
@GET @Path("/{TYPE_NAME}/{UUID}") @Consumes({"text/plain","application/json;charset=UTF-8"}) @Produces("application/json;charset=UTF-8") public String read(@PathParam("TYPE_NAME") String type, @PathParam("UUID") String uuid) throws org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.NotFoundExceptionorg.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
updateOrCreate
@PUT @Path("/{TYPE_NAME}/{UUID}") @Consumes({"text/plain","application/json;charset=UTF-8"}) @Produces("application/json;charset=UTF-8") public String updateOrCreate(@PathParam("TYPE_NAME") String type, @PathParam("UUID") String uuid, String json) throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
delete
@DELETE @Path("/{TYPE_NAME}/{UUID}") public javax.ws.rs.core.Response delete(@PathParam("TYPE_NAME") String type, @PathParam("UUID") String uuid) throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
getInstanceContexts
@GET @Path("{TYPE_NAME}/{UUID}/contexts") @Produces("application/json;charset=UTF-8") public String getInstanceContexts(@PathParam("TYPE_NAME") String type, @PathParam("UUID") String instanceId, @PathParam("CONTEXT_UUID") String contextId) throws org.gcube.informationsystem.resourceregistry.api.exceptions.entities.resource.ResourceNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.contexts.ContextNotFoundException, org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException- Throws:
org.gcube.informationsystem.resourceregistry.api.exceptions.entities.resource.ResourceNotFoundExceptionorg.gcube.informationsystem.resourceregistry.api.exceptions.contexts.ContextNotFoundExceptionorg.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
-