Class Response

java.lang.Object
ru.bgcrm.struts.form.Response

public class Response extends Object
HTTP response object, may be JSON serialized.
  • Field Details

  • Constructor Details

    • Response

      public Response()
  • Method Details

    • getStatus

      public String getStatus()
      Status of request's execution, may be: STATUS_OK, STATUS_ERROR, STATUS_MESSAGE
      Returns:
    • setStatus

      public void setStatus(String status)
      Set status of request's execution.
      Parameters:
      status -
    • getMessage

      public String getMessage()
      Returns:
    • setMessage

      public void setMessage(String message)
    • getEventList

      public List<ClientEvent> getEventList()
      Events for processing of frontend.
      Returns:
    • addEvent

      public void addEvent(ClientEvent event)
      Add an event for frontend.
      Parameters:
      event -
    • getData

      public Map<String,Object> getData()
      Response data. May be serialized to JSON, or available on JSP page.
      Returns:
    • setData

      public void setData(String key, Object data)
      Set response data object.
      Parameters:
      key -
      data -
    • addPageable

      public void addPageable(Pageable<?> result)
      Adds search result to the response data, two objects with keys: 'page' and 'list'
      Parameters:
      result -