JavaGantt 2011.1 API

eu.beesoft.gaia.app
Class ApplicationResponse

java.lang.Object
  extended by eu.beesoft.gaia.app.AbstractRequestResponse
      extended by eu.beesoft.gaia.app.ApplicationResponse

public class ApplicationResponse
extends AbstractRequestResponse

Application response from an application server to a client. It supports these properties:

Please, note there are some (by methods) supported parameters to:


Constructor Summary
ApplicationResponse()
          Creates a new instance of application response.
 
Method Summary
 void addValidationError(java.lang.Object source, java.lang.String message)
          Adds an error from a form validation to the response parameters.
 void disableComponent(java.lang.String id)
          Adds a given component id to the response parameters as id of disabled component.
 java.util.List<java.lang.String> getDisabledComponents()
          Returns the parameter that keeps list of disabled components ids.
 java.lang.String getFormId()
          Returns the form id.
 java.util.List<java.lang.String> getHiddenComponents()
          Returns the parameter that keeps list of hidden components ids.
 java.lang.String getInstruction()
          Returns the instruction.
 ValidationResult getValidationErrors()
          Returns the parameter that keeps result of validations.
 void hideComponent(java.lang.String id)
          Adds a given component id to the response parameters as id of hidden component.
 void setFormId(java.lang.String formId)
          Sets the form id.
 void setInstruction(java.lang.String instruction)
          Sets the instruction
 
Methods inherited from class eu.beesoft.gaia.app.AbstractRequestResponse
addParameter, getData, getParameter, getParameters, removeParameter, setData, setParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ApplicationResponse

public ApplicationResponse()
Creates a new instance of application response.

Method Detail

getInstruction

public java.lang.String getInstruction()
Returns the instruction.

Returns:
the instruction

setInstruction

public void setInstruction(java.lang.String instruction)
Sets the instruction

Parameters:
instruction - - the instruction to set

getFormId

public java.lang.String getFormId()
Returns the form id.

Returns:
the formId

setFormId

public void setFormId(java.lang.String formId)
Sets the form id.

Parameters:
formId - - the formId to set

hideComponent

public void hideComponent(java.lang.String id)
Adds a given component id to the response parameters as id of hidden component.

Parameters:
id - - id of component to hide

getHiddenComponents

public java.util.List<java.lang.String> getHiddenComponents()
Returns the parameter that keeps list of hidden components ids. You can add component id to this list with method hideComponent(String).

Returns:
list of hidden components ids

disableComponent

public void disableComponent(java.lang.String id)
Adds a given component id to the response parameters as id of disabled component.

Parameters:
id - - id of component to disable

getDisabledComponents

public java.util.List<java.lang.String> getDisabledComponents()
Returns the parameter that keeps list of disabled components ids. You can add component id to this list with method disableComponent(String).

Returns:
list of disabled components ids

addValidationError

public void addValidationError(java.lang.Object source,
                               java.lang.String message)
Adds an error from a form validation to the response parameters.

Parameters:
source - - source component where validation fails; id of the component label or id of the component, if there is no label for validated component
message - - message to display as validation error; you should use here a key to the resource bundle

getValidationErrors

public ValidationResult getValidationErrors()
Returns the parameter that keeps result of validations. You can add a validation error to it with method addValidationError(Object, String).

Returns:
validation errors or null if no one was set

JavaGantt 2011.1 API