Package org.drasyl.event
Class NodeOfflineEvent
- java.lang.Object
-
- org.drasyl.event.NodeOfflineEvent
-
public class NodeOfflineEvent extends Object
This event signals that the node is currently not connected to a super peer. This means that the node cannot be discovered and contacted by remote peers. Existing direct connections are not affected by this event. Lost direct connections may not be recoveredIf the node has been configured with no super peer, this event will be never emitted.
This is an immutable object.
- See Also:
NodeOnlineEvent
,PeerDirectEvent
,PeerRelayEvent
-
-
Constructor Summary
Constructors Constructor Description NodeOfflineEvent(Node node)
Deprecated, for removal: This API element is subject to removal in a future version.Useof(Node)
instead.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
Node
getNode()
Returns the node to which this event refers.int
hashCode()
static NodeOfflineEvent
of(Node node)
String
toString()
-
-
-
Field Detail
-
node
protected final Node node
-
-
Constructor Detail
-
NodeOfflineEvent
@Deprecated(since="0.4.0", forRemoval=true) public NodeOfflineEvent(Node node)
Deprecated, for removal: This API element is subject to removal in a future version.Useof(Node)
instead.- Throws:
NullPointerException
- ifnode
isnull
-
-
Method Detail
-
of
public static NodeOfflineEvent of(Node node)
- Throws:
NullPointerException
- ifnode
isnull
-
getNode
@NonNull public Node getNode()
Description copied from interface:NodeEvent
Returns the node to which this event refers.
-
-