com.creamtec.ajaxswing.core

## Class HttpRequestData

- java.lang.Object
- - com.creamtec.ajaxswing.core.HttpRequestData

- All Implemented Interfaces:
    java.io.Serializable

      public class HttpRequestData
      extends java.lang.Object
      implements java.io.Serializable

  Holds various HTTP request parameters, mostly mirroring HttpRequest interface
  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static java.lang.String` | `ACCEPT_LANGUAGE_HEADER`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `HttpRequestData()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getAction()` Returns action, as specified in the HttpRequest.
    `java.lang.String` | `getAppName()` Returns application name.
    `java.lang.String` | `getErrorMessage()` Returns the error message to be displayed at the top of the response page
    `java.util.Map<java.lang.String,java.lang.String>` | `getHeaders()`
    `java.lang.Object` | `getHttpRequest()` Get current http servlet request
    `java.util.HashMap` | `getParams()` Returns a hashtable of parameters, that represent the values, entered by the user to form inputs.
    `long` | `getRequestId()` Returns the request ID.
    `boolean` | `isActionPing()`
    `boolean` | `isActionRefresh()`
    `boolean` | `isActionResize()`
    `boolean` | `isCalibrateRequest()` Returns true if the request contains calibrate param, that means we need make font calibration for this app
    `boolean` | `isFastSubmit()`
    `boolean` | `isNewSession()` Returns true if the request is recieved for a newly created session, which means that the client is making it's first request for the application (or returning to the application after exiting it)
    `boolean` | `isReloadPage()`
    `void` | `setAction(java.lang.String action)` Sets action to be emulated
    `void` | `setAppName(java.lang.String name)` Sets application name.
    `void` | `setErrorMessage(java.lang.String errorMessage)` Sets the error message that will be displayed at the top of the response page
    `void` | `setHeaders(java.util.HashMap<java.lang.String,java.lang.String> headers)`
    `void` | `setHttpRequest(java.lang.Object httpRequest)` Set current http servlet request
    `void` | `setNewSession(boolean newSession)` Sets whether or not the request is received for a new session
    `void` | `setParams(java.util.HashMap params)` Sets parameters, containing values of form inputs
    `void` | `setReloadPage(boolean reloadPage)`
    `void` | `setRequestId(long id)` Sets request ID

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### ACCEPT_LANGUAGE_HEADER

          public static final java.lang.String ACCEPT_LANGUAGE_HEADER

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### HttpRequestData

          public HttpRequestData()

  - ### Method Detail

    - #### isReloadPage

          public boolean isReloadPage()

    - #### setReloadPage

          public void setReloadPage(boolean reloadPage)

    - #### setParams

          public void setParams(java.util.HashMap params)

      Sets parameters, containing values of form inputs

    - #### getParams

          public java.util.HashMap getParams()

      Returns a hashtable of parameters, that represent the values, entered by the user to form inputs. Values are specific to the type of input (see HTML), and for some inputs there may be no valuesin the hashtable at all. Typically, component name is used as a hash code Custom parameters placed into this map should have keys beginning with "custom."

    - #### getRequestId

          public long getRequestId()

      Returns the request ID. Used for synchronization of the focused window and the HTML page, being submitted

    - #### setRequestId

          public void setRequestId(long id)

      Sets request ID

    - #### isNewSession

          public boolean isNewSession()

      Returns true if the request is recieved for a newly created session, which means that the client is making it's first request for the application (or returning to the application after exiting it)

    - #### setNewSession

          public void setNewSession(boolean newSession)

      Sets whether or not the request is received for a new session

    - #### getAppName

          public java.lang.String getAppName()

      Returns application name. Application name is everything, typed after the servlet name in the URL (servletPath).

    - #### setAppName

          public void setAppName(java.lang.String name)

      Sets application name. Application name is everything, typed after the servlet name in the URL (servletPath).

    - #### getAction

          public java.lang.String getAction()

      Returns action, as specified in the HttpRequest. Action can be the extra directory path, that was appended to the servlet virtual directory (mapping), or can be specifed by a form

    - #### setAction

          public void setAction(java.lang.String action)

      Sets action to be emulated

    - #### isFastSubmit

          public boolean isFastSubmit()

    - #### isActionPing

          public boolean isActionPing()

    - #### isActionRefresh

          public boolean isActionRefresh()

    - #### isActionResize

          public boolean isActionResize()

    - #### getErrorMessage

          public java.lang.String getErrorMessage()

      Returns the error message to be displayed at the top of the response page

    - #### setErrorMessage

          public void setErrorMessage(java.lang.String errorMessage)

      Sets the error message that will be displayed at the top of the response page
      Parameters:
        `errorMessage` - text to be displayed or null

    - #### getHttpRequest

          public java.lang.Object getHttpRequest()

      Get current http servlet request
      Returns:
        request object castable to javax.servlet.HttpServletRequest

    - #### setHttpRequest

          public void setHttpRequest(java.lang.Object httpRequest)

      Set current http servlet request
      Parameters:
        `httpRequest` - actual http servlet request

    - #### getHeaders

          public java.util.Map<java.lang.String,java.lang.String> getHeaders()

    - #### setHeaders

          public void setHeaders(java.util.HashMap<java.lang.String,java.lang.String> headers)

    - #### isCalibrateRequest

          public boolean isCalibrateRequest()

      Returns true if the request contains calibrate param, that means we need make font calibration for this app

Copyright © 2000-2012 CreamTec LLC. All Rights Reserved.