public class CloseTransactionMessage extends DOMMessage
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
settlementId
The object identifier of the settlement at which the
transaction occurs.
|
private java.lang.String |
unitId
The object identifier of the unit performing the transaction.
|
document, logger| Constructor and Description |
|---|
CloseTransactionMessage(Game game,
org.w3c.dom.Element element)
Create a new
CloseTransactionMessage from a
supplied element. |
CloseTransactionMessage(Unit unit,
Settlement settlement)
Create a new
CloseTransactionMessage with the
supplied unit and settlement. |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
getXMLElementTagName()
The tag name of the root element representing this object.
|
org.w3c.dom.Element |
handle(FreeColServer server,
Player player,
Connection connection)
Handle a "closeTransaction"-message.
|
org.w3c.dom.Element |
toXMLElement()
Convert this CloseTransactionMessage to XML.
|
clientError, collapseElements, createError, createError, createMessage, createMessage, createNewDocument, createNewRootElement, elementToString, getAttribute, getChildElement, getDocument, getFreeColProtocolVersion, getType, hasAttribute, insertAsRoot, isType, setAttribute, setAttribute, toStringprivate final java.lang.String unitId
private final java.lang.String settlementId
public CloseTransactionMessage(Unit unit, Settlement settlement)
CloseTransactionMessage with the
supplied unit and settlement.unit - The Unit performing the transaction.settlement - The Settlement where the
transaction occurs.public CloseTransactionMessage(Game game, org.w3c.dom.Element element)
CloseTransactionMessage from a
supplied element.game - The Game this message belongs to.element - The Element to use to create the message.public org.w3c.dom.Element handle(FreeColServer server, Player player, Connection connection)
server - The FreeColServer handling the message.player - The Player the message applies to.connection - The Connection message was received on.Element on failure.public org.w3c.dom.Element toXMLElement()
toXMLElement in class DOMMessagepublic static java.lang.String getXMLElementTagName()