org.jogre.common.comm
Class CommControllerObject
java.lang.Object
org.jogre.common.comm.CommBaseMessage
org.jogre.common.comm.CommGameMessage
org.jogre.common.comm.CommTableMessage
org.jogre.common.comm.CommControllerObject
- All Implemented Interfaces:
- ITransmittable
- public class CommControllerObject
- extends CommTableMessage
Communication object which will send a XMLElement as a child
from a client to server (or or vice versa). Used in the JogreController
to simplify the sending and receiving of more complex data.
- Version:
- Alpha 0.2.1
- Author:
- Bob Marks
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
data
protected XMLElement data
- XMLElement of data.
CommControllerObject
public CommControllerObject()
- Empty Constructor. This class must use the setData method (this constructor
cannot take an XMLElement as this would conflict with the parse constructor).
CommControllerObject
public CommControllerObject(XMLElement message)
- Constructor which takes an XMLElement.
- Parameters:
message
-
setData
public void setData(XMLElement data)
- Set data.
- Parameters:
data
-
getData
public XMLElement getData()
- Return the data back to the user.
- Returns:
- Data as XML object.
flatten
public XMLElement flatten()
- Description copied from interface:
ITransmittable
- This method flattens an ITransmittable object into a XMLElement which can
be transmitted. The object can then be recreated again using a single
XMLElement parameter constructor.
- Returns:
- XML version of the state of an object which can be constructed again.
- See Also:
ITransmittable.flatten()