|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface EntityRequestHandler
Handles the URL/request processing for an entity in a central location
| Field Summary | |
|---|---|
static String |
BATCH
The reserved word used to trigger batch operations |
static String |
COMPENSATE_METHOD
This is the special indicator used to denote that POST should be translated to a PUT or DELETE in order to compensate for browser limitations, Example: /people/1? |
static String |
DESCRIBE
The reserved word used to trigger entity descriptions |
static String |
FAKE_ID
The id used in generated URLs |
static String |
HEADER_ENTITY_ID
This is the name of the header which will contain the id of newly created entities |
static String |
HEADER_ENTITY_REFERENCE
This is the name of the header which will contain the reference of created/updated entities |
static String |
HEADER_ENTITY_URL
This is the name of the header that will contain created/updated entities SHOW URL |
static String |
SLASH_BATCH
|
static String |
SLASH_DESCRIBE
|
| Method Summary | |
|---|---|
String |
handleEntityAccess(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res,
String path)
Handles the servlet request response cycle for all direct servlet accesses, logically, we only want to let this request continue on if the entity exists AND there is an http access provider to handle it AND the user can access it (there is some auth completed already or no auth is required) |
String |
handleEntityError(javax.servlet.http.HttpServletRequest req,
Throwable error)
Handles an error which occurs by sending an email and logging extra info about the failure |
| Field Detail |
|---|
static final String DESCRIBE
static final String SLASH_DESCRIBE
static final String BATCH
static final String SLASH_BATCH
static final String HEADER_ENTITY_ID
static final String HEADER_ENTITY_REFERENCE
static final String HEADER_ENTITY_URL
static final String FAKE_ID
static final String COMPENSATE_METHOD
| Method Detail |
|---|
String handleEntityAccess(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res,
String path)
req - the servlet requestres - the servlet responsepath - the path from the request (if null it will be generated from the req)
EntityException - if entity could not be found or failure parsing
String handleEntityError(javax.servlet.http.HttpServletRequest req,
Throwable error)
req - the current requesterror - the current error that occurred
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||