org.apache.abdera.protocol.server.impl
Class HttpServletRequestContext

java.lang.Object
  extended by org.apache.abdera.protocol.util.AbstractRequest
      extended by org.apache.abdera.protocol.server.impl.AbstractRequestContext
          extended by org.apache.abdera.protocol.server.impl.HttpServletRequestContext
All Implemented Interfaces:
Request, RequestContext, ProtocolConstants

public class HttpServletRequestContext
extends AbstractRequestContext
implements RequestContext


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.abdera.protocol.server.RequestContext
RequestContext.Property, RequestContext.Scope
 
Field Summary
 
Fields inherited from class org.apache.abdera.protocol.server.impl.AbstractRequestContext
baseUri, context, document, method, principal, requestUri, subject, target
 
Fields inherited from class org.apache.abdera.protocol.util.AbstractRequest
flags, max_age, max_stale, min_fresh
 
Fields inherited from interface org.apache.abdera.protocol.util.ProtocolConstants
NOCACHE, NOSTORE, NOTRANSFORM, ONLYIFCACHED, PRIVATE, PROXYREVALIDATE, PUBLIC, REVALIDATE
 
Constructor Summary
HttpServletRequestContext(ServiceContext context, javax.servlet.http.HttpServletRequest request)
           
 
Method Summary
 java.lang.Object getAttribute(RequestContext.Scope scope, java.lang.String name)
           
 java.lang.String[] getAttributeNames(RequestContext.Scope scope)
           
 java.lang.String getContextPath()
           
 java.util.Date getDateHeader(java.lang.String name)
           
 java.lang.String getHeader(java.lang.String name)
           
 java.lang.String[] getHeaderNames()
           
 java.util.List<java.lang.String> getHeaders(java.lang.String name)
           
 java.io.InputStream getInputStream()
           
 java.lang.String getParameter(java.lang.String name)
           
 java.lang.String[] getParameterNames()
           
 java.util.List<java.lang.String> getParameters(java.lang.String name)
           
 java.lang.Object getProperty(RequestContext.Property property)
           
 java.io.Reader getReader()
           
 javax.servlet.http.HttpServletRequest getRequest()
           
 javax.servlet.http.HttpSession getSession()
           
 javax.servlet.http.HttpSession getSession(boolean create)
           
 boolean isUserInRole(java.lang.String role)
           
 void setAttribute(RequestContext.Scope scope, java.lang.String name, java.lang.Object value)
           
 
Methods inherited from class org.apache.abdera.protocol.server.impl.AbstractRequestContext
getAbdera, getBaseUri, getDocument, getDocument, getDocument, getDocument, getMethod, getPrincipal, getResolvedUri, getServiceContext, getSubject, getTarget, getTargetPath, getUri
 
Methods inherited from class org.apache.abdera.protocol.util.AbstractRequest
getAccept, getAcceptCharset, getAcceptEncoding, getAcceptLanguage, getAuthorization, getCacheControl, getContentType, getDecodedHeader, getDecodedHeaders, getIfMatch, getIfModifiedSince, getIfNoneMatch, getIfUnmodifiedSince, getMaxAge, getMaxStale, getMinFresh, getSlug, isNoCache, isNoStore, isNoTransform, isOnlyIfCached, setMaxAge, setMaxStale, setMinFresh, setNoCache, setNoStore, setNoTransform, setOnlyIfCached
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.abdera.protocol.server.RequestContext
getAbdera, getBaseUri, getDocument, getDocument, getDocument, getDocument, getMethod, getPrincipal, getResolvedUri, getServiceContext, getSubject, getTarget, getTargetPath, getUri
 
Methods inherited from interface org.apache.abdera.protocol.Request
getAccept, getAcceptCharset, getAcceptEncoding, getAcceptLanguage, getAuthorization, getCacheControl, getContentType, getDecodedHeader, getDecodedHeaders, getIfMatch, getIfModifiedSince, getIfNoneMatch, getIfUnmodifiedSince, getMaxAge, getMaxStale, getMinFresh, getSlug, isNoCache, isNoStore, isNoTransform, isOnlyIfCached
 

Constructor Detail

HttpServletRequestContext

public HttpServletRequestContext(ServiceContext context,
                                 javax.servlet.http.HttpServletRequest request)
Method Detail

getProperty

public java.lang.Object getProperty(RequestContext.Property property)
Specified by:
getProperty in interface RequestContext

getReader

public java.io.Reader getReader()
                         throws java.io.IOException
Specified by:
getReader in interface RequestContext
Throws:
java.io.IOException

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Specified by:
getInputStream in interface RequestContext
Throws:
java.io.IOException

getRequest

public javax.servlet.http.HttpServletRequest getRequest()

getSession

public javax.servlet.http.HttpSession getSession()

getSession

public javax.servlet.http.HttpSession getSession(boolean create)

setAttribute

public void setAttribute(RequestContext.Scope scope,
                         java.lang.String name,
                         java.lang.Object value)
Specified by:
setAttribute in interface RequestContext

getAttribute

public java.lang.Object getAttribute(RequestContext.Scope scope,
                                     java.lang.String name)
Specified by:
getAttribute in interface RequestContext

getAttributeNames

public java.lang.String[] getAttributeNames(RequestContext.Scope scope)
Specified by:
getAttributeNames in interface RequestContext

getParameter

public java.lang.String getParameter(java.lang.String name)
Specified by:
getParameter in interface RequestContext

getParameterNames

public java.lang.String[] getParameterNames()
Specified by:
getParameterNames in interface RequestContext

getParameters

public java.util.List<java.lang.String> getParameters(java.lang.String name)
Specified by:
getParameters in interface RequestContext

getDateHeader

public java.util.Date getDateHeader(java.lang.String name)
Specified by:
getDateHeader in interface Request

getHeader

public java.lang.String getHeader(java.lang.String name)
Specified by:
getHeader in interface Request

getHeaderNames

public java.lang.String[] getHeaderNames()
Specified by:
getHeaderNames in interface Request

getHeaders

public java.util.List<java.lang.String> getHeaders(java.lang.String name)
Specified by:
getHeaders in interface Request

isUserInRole

public boolean isUserInRole(java.lang.String role)
Specified by:
isUserInRole in interface RequestContext

getContextPath

public java.lang.String getContextPath()
Specified by:
getContextPath in interface RequestContext