package stream import ( "fmt" inet "github.com/libp2p/go-libp2p-net" transport "github.com/libp2p/go-libp2p-transport" smux "github.com/libp2p/go-stream-muxer" ) type transportConn struct { smux.Conn inet.ConnMultiaddrs inet.ConnSecurity transport transport.Transport } func (t *transportConn) Transport() transport.Transport { return t.transport } func (t *transportConn) String() string { ts := "" if s, ok := t.transport.(fmt.Stringer); ok { ts = "[" + s.String() + "]" } return fmt.Sprintf( " %s (%s)>", ts, t.LocalMultiaddr(), t.LocalPeer(), t.RemoteMultiaddr(), t.RemotePeer(), ) }