Class CatalogueResolver
- java.lang.Object
-
- org.gcube.datatransfer.resolver.services.CatalogueResolver
-
@Path("{entityContext:ctlg(-(o|g|p|d))?}") public class CatalogueResolver extends ObjectThe CatalogueResolver is able to get/resolve a link to a "Catalogue Entity" stored in one of the D4Science Catalogue's instances. A Catalogue Entity is either a "group" or an "organization" or a "product" of D4Science Data Catalogue. See more at https://gcube.wiki.gcube-system.org/gcube/URI_Resolver#CATALOGUE_Resolver- Author:
- Francesco Mangiacrapa at ISTI-CNR (francesco.mangiacrapa@isti.cnr.it) Nov 16, 2018
-
-
Constructor Summary
Constructors Constructor Description CatalogueResolver()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static ItemCatalogueURLsgetItemCatalogueURLs(javax.servlet.http.HttpServletRequest req, String scopeName, String entityContext, String entityName)Gets the item catalogue UR ls.javax.ws.rs.core.ResponsepostCatalogue(javax.servlet.http.HttpServletRequest req, CatalogueRequest jsonRequest)Create a Catalogue Linkjavax.ws.rs.core.ResponseresolveCatalogue(javax.servlet.http.HttpServletRequest req, String entityName, String vreName, String entityContext)Resolve an entity of the Catalogue
-
-
-
Method Detail
-
resolveCatalogue
@GET @Path("/{vreName}/{entityName}") public javax.ws.rs.core.Response resolveCatalogue(@Context javax.servlet.http.HttpServletRequest req, @PathParam("entityName") String entityName, @PathParam("vreName") String vreName, @PathParam("entityContext") String entityContext) throws javax.ws.rs.WebApplicationExceptionResolve an entity of the Catalogue- Parameters:
req- the reqentityName- the entity namevreName- the vre nameentityContext- the entity context- Returns:
- the response
- Throws:
javax.ws.rs.WebApplicationException- the web application exception
-
postCatalogue
@POST @Path("") @Consumes("application/json") @Produces("text/plain") public javax.ws.rs.core.Response postCatalogue(@Context javax.servlet.http.HttpServletRequest req, CatalogueRequest jsonRequest) throws javax.ws.rs.WebApplicationExceptionCreate a Catalogue Link- Parameters:
req- the reqjsonRequest- the json request- Returns:
- the response
- Throws:
javax.ws.rs.WebApplicationException- the web application exception
-
getItemCatalogueURLs
protected static ItemCatalogueURLs getItemCatalogueURLs(javax.servlet.http.HttpServletRequest req, String scopeName, String entityContext, String entityName) throws Exception
Gets the item catalogue UR ls.- Parameters:
req- the reqscopeName- the scope nameentityContext- the entity contextentityName- the entity name- Returns:
- the item catalogue UR ls
- Throws:
Exception- the exception
-
-