ex_wire v0.1.1 ExWire.Packet.Ping
Ping is used to determine round-trip time of messages to a peer.
**Ping** `0x02` []
Requests an immediate reply of Pong from the peer.
Link to this section Summary
Functions
Given an RLP-encoded Ping packet from Eth Wire Protocol, decodes into a Ping struct
Handles a Ping message. We send a Pong back to the peer
Given a Ping packet, serializes for transport over Eth Wire Protocol
Link to this section Types
Link to this section Functions
Given an RLP-encoded Ping packet from Eth Wire Protocol, decodes into a Ping struct.
Examples
iex> ExWire.Packet.Ping.deserialize([])
%ExWire.Packet.Ping{}
Handles a Ping message. We send a Pong back to the peer.
Examples
iex> ExWire.Packet.Ping.handle(%ExWire.Packet.Ping{})
{:send, %ExWire.Packet.Pong{}}