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

Method SetHttpInfoState

p2pserver/peer/peer.go:286–292  ·  view source on GitHub ↗

SetHttpInfoState set peer`s httpinfo state

(httpInfo bool)

Source from the content-addressed store, hash-verified

284
285//SetHttpInfoState set peer`s httpinfo state
286func (this *Peer) SetHttpInfoState(httpInfo bool) {
287 if httpInfo {
288 this.cap[common.HTTP_INFO_FLAG] = 0x01
289 } else {
290 this.cap[common.HTTP_INFO_FLAG] = 0x00
291 }
292}
293
294//GetHttpInfoState return peer`s httpinfo state
295func (this *Peer) GetHttpInfoState() bool {

Callers 5

createPeersFunction · 0.95
TestAddNbrNodeFunction · 0.95
creatPeersFunction · 0.95
TestUpdatePeerFunction · 0.80
VersionHandleFunction · 0.80

Calls

no outgoing calls

Tested by 4

createPeersFunction · 0.76
TestAddNbrNodeFunction · 0.76
creatPeersFunction · 0.76
TestUpdatePeerFunction · 0.64