Package org.drasyl.node
Class EventTypeDrasylNode
java.lang.Object
org.drasyl.node.DrasylNode
org.drasyl.node.EventTypeDrasylNode
An implementation of
DrasylNode
that provides distinct methods for handling various
Event
types. These include:
-
Field Summary
Fields inherited from class org.drasyl.node.DrasylNode
bootstrap, identity
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
protected
EventTypeDrasylNode
(Identity identity, io.netty.bootstrap.ServerBootstrap bootstrap, io.netty.channel.ChannelFuture channelFuture, List<SocketAddress> sntpServers) protected
EventTypeDrasylNode
(DrasylConfig config) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
onAnyOtherEvent
(Event event) void
Sendsevent
to the application and tells it information about the local node, other peers, connections or incoming messages.protected void
protected void
onMessage
(MessageEvent event) protected void
onNodeEvent
(NodeEvent event) protected void
onPeerEvent
(PeerEvent event)
-
Constructor Details
-
EventTypeDrasylNode
protected EventTypeDrasylNode(Identity identity, io.netty.bootstrap.ServerBootstrap bootstrap, io.netty.channel.ChannelFuture channelFuture, List<SocketAddress> sntpServers) -
EventTypeDrasylNode
- Throws:
DrasylException
-
EventTypeDrasylNode
- Throws:
DrasylException
-
-
Method Details
-
onEvent
Description copied from class:DrasylNode
Sendsevent
to the application and tells it information about the local node, other peers, connections or incoming messages.- Specified by:
onEvent
in classDrasylNode
- Parameters:
event
- the event
-
onInboundException
-
onNodeEvent
-
onPeerEvent
-
onMessage
-
onAnyOtherEvent
-