Package com.saperion.rs
Class WeblinkService
java.lang.Object
com.saperion.rs.RestService
com.saperion.rs.AbstractWeblinkService
com.saperion.rs.WeblinkService
This JAX-RS resource represents the content service. URL: /weblink.
- Author:
- dam
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.Responsegenerate(jakarta.ws.rs.core.UriInfo info, jakarta.servlet.http.HttpServletRequest request, WeblinkParameter params) Generates weblink url.jakarta.ws.rs.core.ResponsegetContent(jakarta.ws.rs.core.UriInfo info, jakarta.servlet.http.HttpServletRequest request, WeblinkParameter params) Retrieves the requested document element and returns it as a download attachment.jakarta.ws.rs.core.ResponsegetContentWithoutFilename(jakarta.ws.rs.core.UriInfo info, jakarta.servlet.http.HttpServletRequest request, WeblinkParameter params) Retrieves the requested document element and returns it as a download attachment.Methods inherited from class com.saperion.rs.AbstractWeblinkService
appendToFilename, getContent, getFilenameFromDocElement, getHDoc, getTypedId, logAndThrowWebException, sendBadRequestMessageMethods inherited from class com.saperion.rs.RestService
checkConnection, getConnection
-
Constructor Details
-
WeblinkService
public WeblinkService()
-
-
Method Details
-
generate
@GET @Path("/url") @Produces("application/octet-stream") public jakarta.ws.rs.core.Response generate(@Context jakarta.ws.rs.core.UriInfo info, @Context jakarta.servlet.http.HttpServletRequest request, @Context WeblinkParameter params) Generates weblink url.- Parameters:
info- the UriInforequest- the HttpServletRequestparams- the WeblinkParameter injected byWeblinkParameterFactory- Returns:
- the response
-
getContentWithoutFilename
@GET @Path("/{archive}/{field}/{id}/{element}") @Produces("application/octet-stream") public jakarta.ws.rs.core.Response getContentWithoutFilename(@Context jakarta.ws.rs.core.UriInfo info, @Context jakarta.servlet.http.HttpServletRequest request, @Context WeblinkParameter params) Retrieves the requested document element and returns it as a download attachment. Filename of downloaded attachment is generated by the element fullname.- Parameters:
info- the inforequest- the requestparams- the params- Returns:
- the content without filename
-
getContent
@GET @Path("/{archive}/{field}/{id}/{element}/{filename}") @Produces("application/octet-stream") public jakarta.ws.rs.core.Response getContent(@Context jakarta.ws.rs.core.UriInfo info, @Context jakarta.servlet.http.HttpServletRequest request, @Context WeblinkParameter params) Retrieves the requested document element and returns it as a download attachment.- Parameters:
info- the inforequest- injected HttpServletRequestparams- the params- Returns:
- processing dependent Response.
-