Class FolderResource
java.lang.Object
org.silverpeas.core.web.rs.RESTWebService
org.silverpeas.components.kmelia.web.FolderResource
- All Implemented Interfaces:
org.silverpeas.core.web.rs.ProtectedWebResource,org.silverpeas.core.web.rs.WebAuthenticationValidation,org.silverpeas.core.web.rs.WebAuthorizationValidation,org.silverpeas.core.web.SilverpeasWebResource
@WebService
@Authorized
@Path("folders/{componentId}")
public class FolderResource
extends org.silverpeas.core.web.rs.RESTWebService
A REST Web resource representing a given node. It is a web service that provides access to a
node referenced by its URL.
-
Nested Class Summary
-
Field Summary
Fields inherited from class org.silverpeas.core.web.rs.RESTWebService
RESPONSE_HEADER_ARRAYSIZEFields inherited from interface org.silverpeas.core.web.SilverpeasWebResource
BASE_PATH -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.ResponsecreateNode(String path, org.silverpeas.core.webapi.node.NodeEntity nodeEntity) Creates a node corresponding to the given node entity and whose parent matches the specified path.List<org.silverpeas.core.webapi.node.NodeEntity>getChildren(String path, String language) Get all children of any node of the application.org.silverpeas.core.webapi.node.NodeEntityGet any node of the application and its children.List<org.silverpeas.core.webapi.node.NodeEntity>Get all children of any node of the application.protected Stringorg.silverpeas.core.webapi.node.NodeEntityGet the root of the application and its children.org.silverpeas.core.webapi.node.NodeEntitygetTreeview(String path, String language) Get all children of any node of the application.Methods inherited from class org.silverpeas.core.web.rs.RESTWebService
createWebResourceUri, fromPage, getBundle, getBundleLocation, getHighestUserRole, getHttpRequest, getHttpServletRequest, getHttpServletResponse, getLanguage, getOrganisationController, getSilverpeasContext, getUri, getUser, getUserPreferences, getUserRoles, identifiedBy, identifiedBy, initContext, initWebResourceUri, isUserDefined, processMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.silverpeas.core.web.rs.ProtectedWebResource
validateUserAuthorizationMethods inherited from interface org.silverpeas.core.web.rs.WebAuthenticationValidation
validateUserAuthentication
-
Constructor Details
-
FolderResource
public FolderResource()
-
-
Method Details
-
getRoot
@GET @Produces("application/json") public org.silverpeas.core.webapi.node.NodeEntity getRoot(@QueryParam("lang") String language) Get the root of the application and its children.- Returns:
- the application root and its children
-
getNode
@GET @Path("{path: \\d+(/\\d+)*}") @Produces("application/json") public org.silverpeas.core.webapi.node.NodeEntity getNode(@PathParam("path") String path, @QueryParam("lang") String language) Get any node of the application and its children.- Returns:
- NodeEntity representing asking node
-
getPath
@GET @Path("{path: \\d+(/\\d+)*/path}") @Produces("application/json") public List<org.silverpeas.core.webapi.node.NodeEntity> getPath(@PathParam("path") String path, @QueryParam("lang") String language) Get all children of any node of the application.- Returns:
- a list of NodeEntity representing children
-
getChildren
@GET @Path("{path: \\d+(/\\d+)*/children}") @Produces("application/json") public List<org.silverpeas.core.webapi.node.NodeEntity> getChildren(@PathParam("path") String path, @QueryParam("lang") String language) Get all children of any node of the application.- Returns:
- a list of NodeEntity representing children
-
createNode
@Path("{path: \\d+(/\\d+)*}") @POST @Produces("application/json") @Consumes("application/json") public jakarta.ws.rs.core.Response createNode(@PathParam("path") String path, org.silverpeas.core.webapi.node.NodeEntity nodeEntity) Creates a node corresponding to the given node entity and whose parent matches the specified path.- Parameters:
path- The path of the parent node.nodeEntity- The description of the node to create.- Returns:
- a response containing the entity describing the newly created node.
-
getTreeview
@GET @Path("{path: \\d+/treeview}") @Produces("application/json") public org.silverpeas.core.webapi.node.NodeEntity getTreeview(@PathParam("path") String path, @QueryParam("lang") String language) Get all children of any node of the application.- Returns:
- an array of NodeEntity representing children
-
getResourceBasePath
- Specified by:
getResourceBasePathin classorg.silverpeas.core.web.rs.RESTWebService
-
getComponentId
-