Documentation ¶
Index ¶
- Constants
- func CreateAddress(addr, id string) string
- type Data
- type IdRec
- type P2pHost
- func (h *P2pHost) AddPeers(peerHosts map[string]*IdRec)
- func (h *P2pHost) Close()
- func (h *P2pHost) GetAddress() string
- func (h *P2pHost) GetHostAddress() string
- func (h *P2pHost) GetID() string
- func (h *P2pHost) PurgePeer(hostAddr string)
- func (h *P2pHost) SetDataVersion(dataType string, version *time.Time)
Constants ¶
View Source
const ( API = "/exchange" MAX_MESSAGE = 1000000 //1M MESSAGE_PEERS = "Peers" MESSAGE_END = "End" )
Variables ¶
This section is empty.
Functions ¶
func CreateAddress ¶
Types ¶
type Data ¶
type Data struct {
// contains filtered or unexported fields
}
func (*Data) RegisterDataUpdate ¶
RegisterDataUpdate for a given dataType Protected by data Mutex
type P2pHost ¶
type P2pHost struct { Data Data // contains filtered or unexported fields }
func (*P2pHost) GetAddress ¶
func (*P2pHost) GetHostAddress ¶
Click to show internal directories.
Click to hide internal directories.