|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.lucene.gdata.server.GDataRequest
public class GDataRequest
The GDataRequest Class wraps the incoming HttpServletRequest. Needed information coming with the HttpServletRequest can be accessed directly. It represents an abstraction on the plain HttpServletRequest. Every GData specific data coming from the client will be available and can be accessed via the GDataRequest.
GDataRequest instances will be passed to any action requested by the client. This class also holds the logic to retrieve important information like response format, the requested feed instance and query parameters.
Nested Class Summary | |
---|---|
static class |
GDataRequest.GDataRequestType
Indicates the request type |
static class |
GDataRequest.OutputFormat
This enum represents the OutputFormat of the GDATA Server |
Constructor Summary | |
---|---|
GDataRequest(javax.servlet.http.HttpServletRequest requst,
GDataRequest.GDataRequestType type)
Creates a new FeedRequest |
Method Summary | |
---|---|
javax.servlet.http.Cookie |
getAuthCookie()
|
String |
getAuthToken()
|
ProvidedService |
getConfigurator()
|
String |
getContextPath()
Returns the requested path including the domain name and the requested resource http://www.apache.org/path/resource/ |
javax.servlet.http.Cookie[] |
getCookies()
|
String |
getEntryId()
|
String |
getEntryVersion()
|
String |
getFeedId()
|
javax.servlet.http.HttpServletRequest |
getHttpServletRequest()
|
int |
getItemsPerPage()
|
String |
getModifiedSince()
|
String |
getNextId()
The href id of the next page of the requested resource. |
String |
getPreviousId()
The previous id is the feeds href pointing to the previous result of the requested resource |
Map<String,String[]> |
getQueryParameter()
Returns the HttpServletRequest parameter map containing all
GET request parameters. |
Enumeration<String> |
getQueryParameterNames()
The HttpServletRequest request parameter names |
String |
getQueryString()
This will return the current query string including all parameters. |
Reader |
getReader()
A Reader instance to read form the client input stream |
String |
getRemoteAddress()
|
GDataRequest.OutputFormat |
getRequestedResponseFormat()
Either Atom or RSS |
String |
getSelfId()
The self id is the feeds href pointing to the requested resource |
int |
getStartIndex()
Start index represents the number of the first entry of the query - result. |
protected String |
getTranslatedQuery()
|
GDataRequest.GDataRequestType |
getType()
GDataRequest.GDataRequestType |
void |
initializeRequest()
Initialize the GDataRequest. |
boolean |
isEntryRequested()
* If the request is a GDataRequest.GDataRequestType.GET request and there is
an entry id specified, the requested resource is an entry. |
boolean |
isFeedRequested()
If the request is a GDataRequest.GDataRequestType.GET request and there is no
entry id specified, the requested resource is a feed. |
boolean |
isSearchRequested()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GDataRequest(javax.servlet.http.HttpServletRequest requst, GDataRequest.GDataRequestType type)
requst
- -
the incoming HttpServletReqeusttype
- -
the request typeMethod Detail |
---|
public void initializeRequest() throws GDataRequestException
GDataRequestException
public String getFeedId()
public String getEntryId()
null
public String getEntryVersion()
null
public Reader getReader() throws IOException
Reader
IOException
- -
if an I/O Exception occurspublic Map<String,String[]> getQueryParameter()
HttpServletRequest
parameter map containing all
GET request parameters.
public Enumeration<String> getQueryParameterNames()
HttpServletRequest
request parameter names
public GDataRequest.OutputFormat getRequestedResponseFormat()
public int getItemsPerPage()
public int getStartIndex()
public String getSelfId()
public String getPreviousId()
public String getNextId()
public String getQueryString()
max-resul
parameter will be added if not
specified.
max-resul
indicates the number of results returned to the
client. The default value is 25.
public String getContextPath()
public GDataRequest.GDataRequestType getType()
GDataRequest.GDataRequestType
public boolean isFeedRequested()
GDataRequest.GDataRequestType.GET
request and there is no
entry id specified, the requested resource is a feed.
true
if an only if the requested resource is a
feedpublic boolean isEntryRequested()
GDataRequest.GDataRequestType.GET
request and there is
an entry id specified, the requested resource is an entry.
true
if an only if the requested resource is an
entrypublic boolean isSearchRequested()
true
if an only if the user request is a search request, otherwise false
public ProvidedService getConfigurator()
public String getRemoteAddress()
public String getAuthToken()
public javax.servlet.http.Cookie[] getCookies()
public javax.servlet.http.Cookie getAuthCookie()
null
if no auth cookie is setpublic String getModifiedSince()
public javax.servlet.http.HttpServletRequest getHttpServletRequest()
protected String getTranslatedQuery()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |