com.electrotank.electroserver.plugins.utilities
Class EventResponse

java.lang.Object
  extended bycom.electrotank.electroserver.plugins.utilities.EventResponse
Direct Known Subclasses:
LoginResponse

public class EventResponse
extends Object

This is the base class from which all event responses, like LoginResponse, are derived.


Constructor Summary
EventResponse(String message)
          Creates a new EventResponse and passes in the return message.
 
Method Summary
 void addResponseVariable(String key, String value)
          Adds a single response variable to the response variable Map.
 String getMessage()
          Gets the message that will be returned to the caller.
 Map getResponseVariables()
          Gets a Map of the response variables for this event.
 void removeResponseVariable(String key)
          Removes the specified response variable from the Map.
 void setMessage(String message)
          Sets the message that will be returned to the caller.
 void setResponseVariables(Map responseVariables)
          Sets the response variables with a Map.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EventResponse

public EventResponse(String message)
Creates a new EventResponse and passes in the return message.

Parameters:
message - the message to return to the event caller.
Method Detail

getMessage

public String getMessage()
Gets the message that will be returned to the caller.

Returns:
the message that will be returned to the caller.

setMessage

public void setMessage(String message)
Sets the message that will be returned to the caller.

Parameters:
message - the message to set.

getResponseVariables

public Map getResponseVariables()
Gets a Map of the response variables for this event. Response variables contain both a key/name and a value. Both of which must be strings. These variables are all passed to the caller as soon as the event has completed.

Returns:
a map containing all the response variables.

setResponseVariables

public void setResponseVariables(Map responseVariables)
Sets the response variables with a Map.

Parameters:
responseVariables - a Map containing the response variables.

addResponseVariable

public void addResponseVariable(String key,
                                String value)
Adds a single response variable to the response variable Map.

Parameters:
key - the key/name of the response variable.
value - the value of the response variable.

removeResponseVariable

public void removeResponseVariable(String key)
Removes the specified response variable from the Map.

Parameters:
key - the key/name of the response variable to be removed.


Copyright © 2006 Electrotank, Inc. All Rights Reserved.