Class: TcpTransport

bitmessage/net/tcp. TcpTransport

new TcpTransport(optsopt)

TCP transport class. Implements base transport interface.

Parameters:
Name Type Attributes Description
opts Object <optional>

Transport options

Properties
Name Type Description
seeds Array

Bootstrap nodes (none by default)

dnsSeeds Array

Bootstrap DNS nodes (none by default)

services Object

Service features provided by this node (NODE_NETWORK by default)

userAgent Array | string | Buffer

User agent of this node (user agent of bitmessage library by default)

streams Array.<number>

Streams accepted by this node ([1] by default)

port number

Incoming port of this node (8444 by default)

Source:

Methods

bootstrapDns() → {Promise.<Array>}

Do only DNS-specific bootstrap.

Source:
Returns:

Discovered seed nodes.

Type
Promise.<Array>

connect()

Connect to a TCP node. Connection arguments are the same as for net.connect.

Source:

listen()

Listen for incoming TCP connections. Listen arguments are the same as for server.listen.

Source: