MCPcopy Create free account
hub / github.com/DNAProject/DNA / IsPeerEstablished

Method IsPeerEstablished

p2pserver/net/netserver/netserver.go:244–249  ·  view source on GitHub ↗

IsPeerEstablished return the establise state of given peer`s id

(p *peer.Peer)

Source from the content-addressed store, hash-verified

242
243//IsPeerEstablished return the establise state of given peer`s id
244func (this *NetServer) IsPeerEstablished(p *peer.Peer) bool {
245 if p == nil {
246 return false
247 }
248 return this.Np.NodeEstablished(p.GetID())
249}
250
251//Connect used to connect net address under sync or cons mode
252func (this *NetServer) Connect(addr string) error {

Callers

nothing calls this directly

Calls 2

NodeEstablishedMethod · 0.65
GetIDMethod · 0.65

Tested by

no test coverage detected