OBEROn SDK

com.oberon.client
Class ApplicationRequest

java.lang.Object
  extended by com.oberon.client.ApplicationRequest

public final class ApplicationRequest
extends java.lang.Object

Contains all parameters and attributes passed to the application's handler methods

Version:
5.0

Field Summary
static java.lang.String target
           
 
Constructor Summary
ApplicationRequest(ApplicationRequest request)
          Creates new request cloning another request
ApplicationRequest(ApplicationRequest request, javax.servlet.http.HttpSession session)
          Creates new request cloning another request for a given session
ApplicationRequest(java.lang.String url, javax.servlet.http.HttpSession session)
          Creates new request
ApplicationRequest(java.lang.String url, java.lang.String targetName, javax.servlet.http.HttpSession session)
          Creates new request
 
Method Summary
 java.lang.Object getAttribute(java.lang.String key)
          Returns the value of a request parameter as a String, or null if the parameter does not exist.
 java.util.Enumeration<java.lang.String> getAttributeNames()
          Returns an Enumeration containing the names of the attributes available to this request.
 java.lang.String getForwardTarget()
          Return the name of target window on the basic of input request parameters
 java.util.Locale getLocale()
          Returns the preferred Locale that the client will accept content in
 java.lang.String getParameter(java.lang.String key)
          Returns the value of a request parameter as a String, or null if the parameter does not exist.
 java.util.Map<java.lang.String,java.lang.String> getParameterMap()
          Returns a java.util.Map of the parameters of this request.
 java.util.Enumeration<java.lang.String> getParameterNames()
          Returns an Enumeration of String objects containing the names of the parameters contained in this request.
 java.lang.String[] getParameterValues(java.lang.String key)
          Returns an array of String objects containing all of the values the given request parameter has, or null if the parameter does not exist.
 java.lang.Object getReferer()
          Returns the element in the user interface which raises the request
 java.lang.String getRequestPage()
          Returns the request target page
 java.lang.String getRequestURL()
          Returns the url the client used to make the request.
 javax.servlet.http.HttpSession getSession()
          Gets the current valid session associated with this request
 java.lang.String getTarget()
          Returns the target panel for visualization
 void removeAttribute(java.lang.String key)
          Removes an attribute from this request.
 void removeParameter(java.lang.String key)
          Removes a parameter from this request.
 void setAttribute(java.lang.String key, java.lang.Object object)
          Stores an attribute in this request.
 void setLocale(java.util.Locale locale)
          Sets the preferred Locale that the client will accept content in
 void setParameter(java.lang.String key, java.lang.String value)
          Sets a parameter for this request.
 void setReferer(java.lang.Object referer)
          Sets the referer element
 void setRequestPage(java.lang.String url)
          Updates the request target page
 void setTarget(java.lang.String target)
          Sets the target panel for visualization
 java.lang.String toString()
          Show the Application Request
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

target

public static final java.lang.String target
See Also:
Constant Field Values
Constructor Detail

ApplicationRequest

public ApplicationRequest(ApplicationRequest request)
Creates new request cloning another request


ApplicationRequest

public ApplicationRequest(ApplicationRequest request,
                          javax.servlet.http.HttpSession session)
Creates new request cloning another request for a given session

Since:
4.1

ApplicationRequest

public ApplicationRequest(java.lang.String url,
                          javax.servlet.http.HttpSession session)
Creates new request

Parameters:
url - url address, including GET parameters ( .../page.jsp?param1=value1¶m2=value2&... )
session - the current session

ApplicationRequest

public ApplicationRequest(java.lang.String url,
                          java.lang.String targetName,
                          javax.servlet.http.HttpSession session)
Creates new request

Parameters:
url - url address, including GET parameters ( .../page.jsp?param1=value1¶m2=value2&... )
targetName - the target panel for visualization
session - the current session
Since:
4.1
Method Detail

setAttribute

public void setAttribute(java.lang.String key,
                         java.lang.Object object)
Stores an attribute in this request.

Parameters:
key - a String specifying the name of the attribute
object - the Object to be stored

setLocale

public void setLocale(java.util.Locale locale)
Sets the preferred Locale that the client will accept content in


setParameter

public void setParameter(java.lang.String key,
                         java.lang.String value)
Sets a parameter for this request.

Parameters:
key - a String specifying the name of the parameter
value - the parameter value

setRequestPage

public void setRequestPage(java.lang.String url)
Updates the request target page

Parameters:
url - url address; GET parameters are ignored

setTarget

public void setTarget(java.lang.String target)
Sets the target panel for visualization

Parameters:
target - the target panel: "" or null = same panel; "_blank" = new panel; "<name>" = popup window name

setReferer

public void setReferer(java.lang.Object referer)
Sets the referer element

Parameters:
referer - any element in the user interface which raises the request

getAttribute

public java.lang.Object getAttribute(java.lang.String key)
Returns the value of a request parameter as a String, or null if the parameter does not exist.

Parameters:
key - the parameter name

getAttributeNames

public java.util.Enumeration<java.lang.String> getAttributeNames()
Returns an Enumeration containing the names of the attributes available to this request.


getLocale

public java.util.Locale getLocale()
Returns the preferred Locale that the client will accept content in


getParameter

public java.lang.String getParameter(java.lang.String key)
Returns the value of a request parameter as a String, or null if the parameter does not exist.

Parameters:
key - the parameter's name

getParameterMap

public java.util.Map<java.lang.String,java.lang.String> getParameterMap()
Returns a java.util.Map of the parameters of this request.


getParameterNames

public java.util.Enumeration<java.lang.String> getParameterNames()
Returns an Enumeration of String objects containing the names of the parameters contained in this request.


getParameterValues

public java.lang.String[] getParameterValues(java.lang.String key)
Returns an array of String objects containing all of the values the given request parameter has, or null if the parameter does not exist.

Parameters:
key - the parameter's name

getRequestPage

public java.lang.String getRequestPage()
Returns the request target page


getRequestURL

public java.lang.String getRequestURL()
Returns the url the client used to make the request.


getTarget

public java.lang.String getTarget()
Returns the target panel for visualization


getReferer

public java.lang.Object getReferer()
Returns the element in the user interface which raises the request


getSession

public javax.servlet.http.HttpSession getSession()
Gets the current valid session associated with this request


removeAttribute

public void removeAttribute(java.lang.String key)
Removes an attribute from this request.

Parameters:
key - the attribute's name

removeParameter

public void removeParameter(java.lang.String key)
Removes a parameter from this request.

Parameters:
key - the parameter's name

getForwardTarget

public java.lang.String getForwardTarget()
Return the name of target window on the basic of input request parameters

Returns:
the name of target window
Since:
4.1

toString

public java.lang.String toString()
Show the Application Request

Overrides:
toString in class java.lang.Object

OBEROn SDK

Copyright © 2008-2014 Mirko Solazzi. All Rights Reserved.