Socket provides network connectivity for Tashi Vertex, allowing the consensus engine to communicate with peers in the network.
Methods
bind
Binds a Tashi Vertex socket to the specified address.Parameters
Reference to a Tashi Vertex context
The address to bind to. Must be a valid IPv4 or IPv6 address including the port number (e.g., “0.0.0.0:8080” or ”[::]:8080”).
Returns
Returns a
Future that resolves to a Socket on success, or an Error::SocketBind if the bind operation fails.The address must be a valid IPv4 or IPv6 address, including the port number. DNS lookup is not performed.
Example
- IPv4
- IPv6
- Localhost