Documentation
¶
Index ¶
- Variables
- type Addr
- type Conn
- func (c Conn) Close() error
- func (c Conn) LocalAddr() net.Addr
- func (c Conn) LocalMultiaddr() ma.Multiaddr
- func (c Conn) RemoteAddr() net.Addr
- func (c Conn) RemoteMultiaddr() ma.Multiaddr
- func (c Conn) SetDeadline(t time.Time) error
- func (c Conn) SetReadDeadline(t time.Time) error
- func (c Conn) SetWriteDeadline(t time.Time) error
- func (c Conn) Transport() transport.Transport
- type Dialer
- type Listener
- type Transport
Constants ¶
This section is empty.
Variables ¶
var ErrTCPOnly = errors.New("shs only supports tcp") // TODO get rid of this
var ErrWrongBindKey = errors.New("public key in bind address doesn't match own key")
Functions ¶
This section is empty.
Types ¶
type Addr ¶
type Addr struct {
// contains filtered or unexported fields
}
Addr implements net.Addr
type Conn ¶
Conn is an encrypted connection to a remote shs host.
func (Conn) LocalMultiaddr ¶
LocalMultiaddr returns the local Multiaddr
func (Conn) RemoteAddr ¶
RemoteAddr returns the remote net.Addr with the remote public key
func (Conn) RemoteMultiaddr ¶
LocalMultiaddr returns the remote end's Multiaddr
func (Conn) SetDeadline ¶
SetDeadline passes the call to the underlying net.Conn
func (Conn) SetReadDeadline ¶
SetReadDeadline passes the call to the underlying net.Conn
func (Conn) SetWriteDeadline ¶
SetWriteDeadline passes the call to the underlying net.Conn
type Dialer ¶
Dialer allows dialing other shs hosts
func (Dialer) DialContext ¶
DialContext tries to connect to the shs host with the Multiaddress raddr.
type Listener ¶
type Listener struct {
// contains filtered or unexported fields
}
Listener implements the go-libp2p-transport.Listener interface
func (*Listener) Accept ¶
Accept waits for an incoming connection and returns it. Else it returns an error.
func (*Listener) NetListener ¶
NetListener returns a net.Listener that is equivalent to this manet.Listener.
type Transport ¶
type Transport struct {
// contains filtered or unexported fields
}
Transport implements the go-libp2p-transport.Transport interface
func NewTransport ¶
NewTransport creates and initializes a struct of type *Transport