Documentation
¶
Index ¶
- type Option
- type VsockTransport
- func (t *VsockTransport) CanDial(addr ma.Multiaddr) bool
- func (t *VsockTransport) Dial(ctx context.Context, raddr ma.Multiaddr, p peer.ID) (transport.CapableConn, error)
- func (t *VsockTransport) Listen(laddr ma.Multiaddr) (transport.Listener, error)
- func (t *VsockTransport) Protocols() []int
- func (t *VsockTransport) Proxy() bool
- func (t *VsockTransport) String() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*VsockTransport) error
type VsockTransport ¶
type VsockTransport struct {
// contains filtered or unexported fields
}
VsockTransport is the VSOCK transport.
func New ¶
func New(upgrader transport.Upgrader, rcmgr network.ResourceManager, opts ...Option) (*VsockTransport, error)
New creates a VSOCK transport object that tracks dialers and listeners created.
func (*VsockTransport) CanDial ¶
func (t *VsockTransport) CanDial(addr ma.Multiaddr) bool
CanDial returns true if this transport believes it can dial the given multiaddr.
func (*VsockTransport) Dial ¶
func (t *VsockTransport) Dial(ctx context.Context, raddr ma.Multiaddr, p peer.ID) (transport.CapableConn, error)
Dial dials the peer at the remote address.
func (*VsockTransport) Protocols ¶
func (t *VsockTransport) Protocols() []int
Protocols returns the list of terminal protocols this transport can dial.
func (*VsockTransport) Proxy ¶
func (t *VsockTransport) Proxy() bool
Proxy always returns false for the VSOCK transport.
func (*VsockTransport) String ¶
func (t *VsockTransport) String() string
Click to show internal directories.
Click to hide internal directories.