MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / String

Method String

proto/nodeinfo.go:234–246  ·  view source on GitHub ↗

String is a string variable of ServerRole.

()

Source from the content-addressed store, hash-verified

232
233// String is a string variable of ServerRole.
234func (s ServerRole) String() string {
235 switch s {
236 case Leader:
237 return "Leader"
238 case Follower:
239 return "Follower"
240 case Miner:
241 return "Miner"
242 case Client:
243 return "Client"
244 }
245 return "Unknown"
246}
247
248// MarshalYAML implements the yaml.Marshaler interface.
249func (s ServerRole) MarshalYAML() (interface{}, error) {

Callers 10

MarshalYAMLMethod · 0.95
StringMethod · 0.45
InitNodeCryptoInfoMethod · 0.45
ToNodeIDMethod · 0.45
FromAccountAndNonceFunction · 0.45
TestNodeID_ToRawNodeIDFunction · 0.45
TestCPUMiner_HashBlockFunction · 0.45

Calls

no outgoing calls

Tested by 5

TestNodeID_ToRawNodeIDFunction · 0.36
TestCPUMiner_HashBlockFunction · 0.36