|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.restlet.Handler
org.restlet.resource.Resource
org.hackystat.sensorbase.resource.sensorbase.SensorBaseResource
org.hackystat.sensorbase.resource.projects.UserProjectResource
public class UserProjectResource
The resource for processing GET/PUT/DELETE host/projects/{email}/{projectname}. Returns a representation of the Project resource associated with this user.
Field Summary |
---|
Fields inherited from class org.hackystat.sensorbase.resource.sensorbase.SensorBaseResource |
---|
authUser, project, projectManager, projectName, responseMsg, sdtManager, sensorDataManager, server, uriUser, user, userManager |
Constructor Summary | |
---|---|
UserProjectResource(org.restlet.Context context,
org.restlet.data.Request request,
org.restlet.data.Response response)
Provides the following representational variants: TEXT_XML. |
Method Summary | |
---|---|
boolean |
allowDelete()
Indicate the DELETE method is supported. |
boolean |
allowPut()
Indicate the PUT method is supported. |
void |
removeRepresentations()
Implement the DELETE method that deletes an existing Project for a given User. |
org.restlet.resource.Representation |
represent(org.restlet.resource.Variant variant)
Returns an XML representation of the Project associated with this User. |
void |
storeRepresentation(org.restlet.resource.Representation entity)
Implement the PUT method that creates a new Project or updates an existing Project. |
Methods inherited from class org.hackystat.sensorbase.resource.sensorbase.SensorBaseResource |
---|
getStringRepresentation, setStatusBadTimestamp, setStatusInternalError, setStatusMiscError, validateAuthUserIsAdmin, validateAuthUserIsAdminOrUriUser, validateProjectOwner, validateProjectViewer, validateUriProjectName, validateUriUserIsUser |
Methods inherited from class org.restlet.resource.Resource |
---|
acceptRepresentation, allowGet, allowPost, delete, getPreferredRepresentation, getPreferredVariant, getRepresentation, getVariants, handleDelete, handleGet, handlePost, handlePut, init, isAvailable, isModifiable, isNegotiateContent, isReadable, post, put, represent, setAvailable, setModifiable, setNegotiateContent, setReadable, setVariants |
Methods inherited from class org.restlet.Handler |
---|
allowHead, allowOptions, generateRef, getAllowedMethods, getApplication, getContext, getLogger, getMatrix, getQuery, getRequest, getResponse, handleHead, handleOptions, setContext, setRequest, setResponse, updateAllowedMethods |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UserProjectResource(org.restlet.Context context, org.restlet.data.Request request, org.restlet.data.Response response)
context
- The context.request
- The request object.response
- The response object.Method Detail |
---|
public org.restlet.resource.Representation represent(org.restlet.resource.Variant variant)
represent
in class SensorBaseResource
variant
- The representational variant requested, or null if conditions are violated.
public boolean allowPut()
allowPut
in class org.restlet.resource.Resource
public void storeRepresentation(org.restlet.resource.Representation entity)
storeRepresentation
in class org.restlet.resource.Resource
entity
- The XML representation of the new Project.public boolean allowDelete()
allowDelete
in class org.restlet.resource.Resource
public void removeRepresentations()
removeRepresentations
in class org.restlet.resource.Resource
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |