Documentation
¶
Index ¶
- type P2PServer
- func (p2p *P2PServer) Connect(peers ...string) error
- func (p2p *P2PServer) GetConnections() map[string]string
- func (p2p *P2PServer) MsgReceivedHandler(handle func([]byte))
- func (ws *P2PServer) OnParseMsgHandler(src *os.File)
- func (p2p *P2PServer) SetMsgReceivedHandler(handle func([]byte))
- func (p2p *P2PServer) SetSendMsg(clientId string, msg []byte)
- func (p2p *P2PServer) Shutdown()
- func (p2p *P2PServer) Start(ctx context.Context)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type P2PServer ¶
type P2PServer struct {
// contains filtered or unexported fields
}
func NewP2PServer ¶
func (*P2PServer) GetConnections ¶ added in v1.0.14
func (*P2PServer) MsgReceivedHandler ¶
func (*P2PServer) OnParseMsgHandler ¶
func (*P2PServer) SetMsgReceivedHandler ¶
func (*P2PServer) SetSendMsg ¶
Click to show internal directories.
Click to hide internal directories.