Package megamek.common.net.events
Class AbstractConnectionEvent
java.lang.Object
java.util.EventObject
megamek.common.net.events.AbstractConnectionEvent
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ConnectedEvent,DisconnectedEvent,PacketReceivedEvent
Instances of descendant classes are sent as a result of changes of the Connection state or packet arrival.
- See Also:
-
Field Summary
Fields inherited from class java.util.EventObject
source -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractConnectionEvent(ConnectionEventType type, Object source) Constructs a connection event -
Method Summary
Methods inherited from class java.util.EventObject
getSource
-
Constructor Details
-
AbstractConnectionEvent
Constructs a connection event- Parameters:
type- the connection event typesource- The object on which the Event initially occurred.
-
-
Method Details
-
getType
- Returns:
- the type of the event
-
getConnection
- Returns:
- the connection on which the Event occurred
-
toString
- Overrides:
toStringin classEventObject
-