Package org.drasyl.node.event
Class Peer
java.lang.Object
org.drasyl.node.event.Peer
Used by
Event to describe an event related to a Peer (e.g. PeerRelayEvent, PeerDirectEvent).
This is an immutable object.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract DrasylAddressReturns the peer's address.Deprecated, for removal: This API element is subject to removal in a future version.static Peerof(DrasylAddress address)
-
Constructor Details
-
Peer
public Peer()
-
-
Method Details
-
getAddress
Returns the peer's address.- Returns:
- the peer's address.
-
getIdentityPublicKey
Deprecated, for removal: This API element is subject to removal in a future version.UsegetAddress()instead.Returns the peer's public key.- Returns:
- the peer's public key.
-
of
- Throws:
NullPointerException- ifaddressisnull
-
getAddress()instead.