Package org.apache.unomi.rest.endpoints
Class ScopeServiceEndPoint
- java.lang.Object
-
- org.apache.unomi.rest.endpoints.ScopeServiceEndPoint
-
-
Constructor Summary
Constructors Constructor Description ScopeServiceEndPoint()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
delete(String scopeId)
Deletes a scope.Scope
getScope(String scopeId)
Retrieves the scope identified by the specified identifier.List<Scope>
getScopes()
Retrieves all known scopes.javax.ws.rs.core.Response
save(Scope scope)
Persists the specified scope.void
setScopeService(ScopeService scopeService)
-
-
-
Method Detail
-
setScopeService
public void setScopeService(ScopeService scopeService)
-
getScopes
@GET @Path("/") public List<Scope> getScopes()
Retrieves all known scopes.- Returns:
- a List of the scopes
-
save
@POST @Path("/") public javax.ws.rs.core.Response save(Scope scope)
Persists the specified scope.- Parameters:
scope
- the scope to be persisted
-
getScope
@GET @Path("/{scopeId}") public Scope getScope(@PathParam("scopeId") String scopeId)
Retrieves the scope identified by the specified identifier.- Parameters:
scopeId
- the identifier of the scope we want to retrieve- Returns:
- the scope identified by the specified identifier or
null
if no such scope exists.
-
delete
@DELETE @Path("/{scopeId}") public void delete(@PathParam("scopeId") String scopeId)
Deletes a scope.- Parameters:
scopeId
- the identifier of the scope
-
-