Java Doc for WrapperRequest.java in  » Web-Services » restlet-1.0.8 » org » restlet » util » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Services » restlet 1.0.8 » org.restlet.util 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.restlet.data.Request
   org.restlet.util.WrapperRequest

WrapperRequest
public class WrapperRequest extends Request (Code)
Request wrapper. Useful for application developer who need to enrich the request with application related properties and behavior.
See Also:    The decorator (aka * wrapper) pattern
author:
   Jerome Louvel (contact@noelios.com)



Constructor Summary
public  WrapperRequest(Request wrappedRequest)
     Constructor.

Method Summary
public  Map<String, Object>getAttributes()
     Returns a modifiable attributes map that can be used by developers to save information relative to the message.
public  ChallengeResponsegetChallengeResponse()
     Returns the authentication response sent by a client to an origin server.
public  ClientInfogetClientInfo()
     Returns the client-specific information.
public  ConditionsgetConditions()
     Returns the conditions applying to this call.
public  Series<Cookie>getCookies()
     Returns the cookies provided by the client.
public  RepresentationgetEntity()
     Returns the entity representation.
public  DomRepresentationgetEntityAsDom()
    
public  FormgetEntityAsForm()
     Returns the entity as a DOM representation.
Note that this triggers the parsing of the entity into a reusable DOM document stored in memory.
This method and the related getEntity*() methods can only be invoked once.
public  ObjectgetEntityAsObject()
     Returns the entity as a higher-level object.
public  SaxRepresentationgetEntityAsSax()
     Returns the entity as a SAX representation.
Note that this kind of representation can only be parsed once.
public  ReferencegetHostRef()
     Returns the host reference.
public  MethodgetMethod()
     Returns the method.
public  ProtocolgetProtocol()
     Returns the protocol by first returning the baseRef.schemeProtocol property if it is set, or the resourceRef.schemeProtocol property otherwise.
public  ReferencegetReferrerRef()
     Returns the referrer reference if available.
public  ReferencegetResourceRef()
     Returns the reference of the target resource.
public  ReferencegetRootRef()
     Returns the application root reference.
protected  RequestgetWrappedRequest()
     Returns the wrapped request.
public  booleanisConfidential()
     Indicates if the call came over a confidential channel such as an SSL-secured connection.
public  booleanisEntityAvailable()
     Indicates if a content is available and can be sent.
public  voidsetChallengeResponse(ChallengeResponse response)
     Sets the authentication response sent by a client to an origin server.
public  voidsetConfidential(boolean confidential)
     Indicates if the call came over a confidential channel such as an SSL-secured connection.
public  voidsetEntity(Object object)
     Sets the entity from a higher-level object.
public  voidsetEntity(Representation entity)
     Sets the entity representation.
public  voidsetEntity(String value, MediaType mediaType)
     Sets a textual entity.
public  voidsetHostRef(Reference hostRef)
     Sets the host reference.
public  voidsetHostRef(String hostUri)
     Sets the host reference using an URI string.
public  voidsetMethod(Method method)
     Sets the method called.
public  voidsetReferrerRef(Reference referrerRef)
     Sets the referrer reference if available.
public  voidsetReferrerRef(String referrerUri)
     Sets the referrer reference if available using an URI string.
public  voidsetResourceRef(Reference resourceRef)
     Sets the target resource reference.
public  voidsetResourceRef(String resourceUri)
     Sets the target resource reference using an URI string.
public  voidsetRootRef(Reference rootRef)
     Sets the application root reference.


Constructor Detail
WrapperRequest
public WrapperRequest(Request wrappedRequest)(Code)
Constructor.
Parameters:
  wrappedRequest - The wrapped request.




Method Detail
The modifiable attributes map.
getAttributes
public Map<String, Object> getAttributes()(Code)
Returns a modifiable attributes map that can be used by developers to save information relative to the message. This is an easier alternative to the creation of a wrapper instance around the whole message.

In addition, this map is a shared space between the developer and the connectors. In this case, it is used to exchange information that is not uniform across all protocols and couldn't therefore be directly included in the API. For this purpose, all attribute names starting with "org.restlet" are reserved. Currently the following attributes are used:
Attribute name Class name Description
org.restlet.http.headers org.restlet.data.Form Server HTTP connectors must provide all request headers and client HTTP connectors must provide all response headers, exactly as they were received. In addition, developers can also use this attribute to specify non-standard headers that should be added to the request or to the response.
Adding standard HTTP headers is forbidden because it could conflict with the connector's internal behavior, limit portability or prevent future optimizations.



getChallengeResponse
public ChallengeResponse getChallengeResponse()(Code)
Returns the authentication response sent by a client to an origin server. The authentication response sent by a client to an origin server.



getClientInfo
public ClientInfo getClientInfo()(Code)
Returns the client-specific information. The client-specific information.



getConditions
public Conditions getConditions()(Code)
Returns the conditions applying to this call. The conditions applying to this call.



getCookies
public Series<Cookie> getCookies()(Code)
Returns the cookies provided by the client. The cookies provided by the client.



getEntity
public Representation getEntity()(Code)
Returns the entity representation. The entity representation.



getEntityAsDom
public DomRepresentation getEntityAsDom()(Code)



getEntityAsForm
public Form getEntityAsForm()(Code)
Returns the entity as a DOM representation.
Note that this triggers the parsing of the entity into a reusable DOM document stored in memory.
This method and the related getEntity*() methods can only be invoked once. The entity as a DOM representation.



getEntityAsObject
public Object getEntityAsObject()(Code)
Returns the entity as a higher-level object. This object is created by the Application's converter service. If you want to use this method to facilitate the processing of request entities, you need to provide a custom implementation of the ConverterService class, overriding the toObject(Representation) method.
Note that this triggers the parsing of the entity.
This method and the related getEntity*() methods can only be invoked once. The entity as a higher-level object.



getEntityAsSax
public SaxRepresentation getEntityAsSax()(Code)
Returns the entity as a SAX representation.
Note that this kind of representation can only be parsed once. If you evaluate an XPath expression, it can also only be done once. If you need to reuse the entity multiple times, consider using the getEntityAsDom() method instead. The entity as a SAX representation.



getHostRef
public Reference getHostRef()(Code)
Returns the host reference. This may be different from the resourceRef's host, for example for URNs and other URIs that don't contain host information. The host reference.



getMethod
public Method getMethod()(Code)
Returns the method. The method.



getProtocol
public Protocol getProtocol()(Code)
Returns the protocol by first returning the baseRef.schemeProtocol property if it is set, or the resourceRef.schemeProtocol property otherwise. The protocol or null if not available.



getReferrerRef
public Reference getReferrerRef()(Code)
Returns the referrer reference if available. The referrer reference.



getResourceRef
public Reference getResourceRef()(Code)
Returns the reference of the target resource. The reference of the target resource.



getRootRef
public Reference getRootRef()(Code)
Returns the application root reference. The application root reference.



getWrappedRequest
protected Request getWrappedRequest()(Code)
Returns the wrapped request. The wrapped request.



isConfidential
public boolean isConfidential()(Code)
Indicates if the call came over a confidential channel such as an SSL-secured connection. True if the call came over a confidential channel.



isEntityAvailable
public boolean isEntityAvailable()(Code)
Indicates if a content is available and can be sent. Several conditions must be met: the method must allow the sending of content, the content must exists and have some available data. True if a content is available and can be sent.



setChallengeResponse
public void setChallengeResponse(ChallengeResponse response)(Code)
Sets the authentication response sent by a client to an origin server.
Parameters:
  response - The authentication response sent by a client to an originserver.



setConfidential
public void setConfidential(boolean confidential)(Code)
Indicates if the call came over a confidential channel such as an SSL-secured connection.
Parameters:
  confidential - True if the call came over a confidential channel.



setEntity
public void setEntity(Object object)(Code)
Sets the entity from a higher-level object. This object is converted to a representation using the Application's converter service. If you want to use this method to facilitate the setting of entities, you need to provide a custom implementation of the ConverterService class, overriding the toRepresentation(Object) method.
Parameters:
  object - The higher-level object.



setEntity
public void setEntity(Representation entity)(Code)
Sets the entity representation.
Parameters:
  entity - The entity representation.



setEntity
public void setEntity(String value, MediaType mediaType)(Code)
Sets a textual entity.
Parameters:
  value - The represented string.
Parameters:
  mediaType - The representation's media type.



setHostRef
public void setHostRef(Reference hostRef)(Code)
Sets the host reference.
Parameters:
  hostRef - The host reference.



setHostRef
public void setHostRef(String hostUri)(Code)
Sets the host reference using an URI string.
Parameters:
  hostUri - The host URI.



setMethod
public void setMethod(Method method)(Code)
Sets the method called.
Parameters:
  method - The method called.



setReferrerRef
public void setReferrerRef(Reference referrerRef)(Code)
Sets the referrer reference if available.
Parameters:
  referrerRef - The referrer reference.



setReferrerRef
public void setReferrerRef(String referrerUri)(Code)
Sets the referrer reference if available using an URI string.
Parameters:
  referrerUri - The referrer URI.



setResourceRef
public void setResourceRef(Reference resourceRef)(Code)
Sets the target resource reference. If the reference is relative, it will be resolved as an absolute reference. Also, the context's base reference will be reset. Finally, the reference will be normalized to ensure a consistent handling of the call.
Parameters:
  resourceRef - The resource reference.



setResourceRef
public void setResourceRef(String resourceUri)(Code)
Sets the target resource reference using an URI string. Note that the URI can be either absolute or relative to the context's base reference.
Parameters:
  resourceUri - The resource URI.



setRootRef
public void setRootRef(Reference rootRef)(Code)
Sets the application root reference.
Parameters:
  rootRef - The application root reference.



Methods inherited from org.restlet.data.Request
public ChallengeResponse getChallengeResponse()(Code)(Java Doc)
public ClientInfo getClientInfo()(Code)(Java Doc)
public Conditions getConditions()(Code)(Java Doc)
public Series<Cookie> getCookies()(Code)(Java Doc)
public Reference getHostRef()(Code)(Java Doc)
public Method getMethod()(Code)(Java Doc)
public Protocol getProtocol()(Code)(Java Doc)
public Reference getReferrerRef()(Code)(Java Doc)
public Reference getResourceRef()(Code)(Java Doc)
public Reference getRootRef()(Code)(Java Doc)
public boolean isConfidential()(Code)(Java Doc)
public boolean isEntityAvailable()(Code)(Java Doc)
public void setChallengeResponse(ChallengeResponse response)(Code)(Java Doc)
public void setConfidential(boolean confidential)(Code)(Java Doc)
public void setHostRef(Reference hostRef)(Code)(Java Doc)
public void setHostRef(String hostUri)(Code)(Java Doc)
public void setMethod(Method method)(Code)(Java Doc)
public void setReferrerRef(Reference referrerRef)(Code)(Java Doc)
public void setReferrerRef(String referrerUri)(Code)(Java Doc)
public void setResourceRef(Reference resourceRef)(Code)(Java Doc)
public void setResourceRef(String resourceUri)(Code)(Java Doc)
public void setRootRef(Reference rootRef)(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.