sharpster.common
Class ResponseCollection

java.lang.Object
  |
  +--sharpster.common.ResponseCollection
All Implemented Interfaces:
java.io.Serializable

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

A general collection of responses which is used by modules in the local client and in the daemon. A ResponseCollection can contain serveral Response objects of different types.

See Also:
Serialized Form

Constructor Summary
ResponseCollection()
          Constructor
 
Method Summary
 void addResponse(sharpster.common.Response response)
          Adds a new Response object to the collection.
 void appendCollection(sharpster.common.ResponseCollection collection)
          Appends a ResponseCollection to this collection.
 sharpster.common.Response getResponse(int index)
          Returns a specified response.
 int getResponseCount()
          Returns the number of Response objects in the collection.
 boolean hasError()
          Returns true if this response colletion contains responses that has error.
 java.lang.String toString()
          Prints the file collection to a readable string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ResponseCollection

public ResponseCollection()
Constructor

Method Detail

hasError

public boolean hasError()
Returns true if this response colletion contains responses that has error.


getResponseCount

public int getResponseCount()
Returns the number of Response objects in the collection.


addResponse

public void addResponse(sharpster.common.Response response)
Adds a new Response object to the collection.


appendCollection

public void appendCollection(sharpster.common.ResponseCollection collection)
Appends a ResponseCollection to this collection.


getResponse

public sharpster.common.Response getResponse(int index)
Returns a specified response.


toString

public java.lang.String toString()
Prints the file collection to a readable string.

Overrides:
toString in class java.lang.Object