MCPcopy Create free account
hub / github.com/DeAI-Artist/Linkis / String

Method String

p2p/netaddress.go:211–222  ·  view source on GitHub ↗

String representation: @ :

()

Source from the content-addressed store, hash-verified

209
210// String representation: <ID>@<IP>:<PORT>
211func (na *NetAddress) String() string {
212 if na == nil {
213 return EmptyNetAddress
214 }
215
216 addrStr := na.DialString()
217 if na.ID != "" {
218 addrStr = IDAddressString(na.ID, addrStr)
219 }
220
221 return addrStr
222}
223
224func (na *NetAddress) DialString() string {
225 if na == nil {

Callers 3

TestNetAddress_StringFunction · 0.95
TestNewNetAddressFunction · 0.95
EqualsMethod · 0.95

Calls 2

DialStringMethod · 0.95
IDAddressStringFunction · 0.85

Tested by 2

TestNetAddress_StringFunction · 0.76
TestNewNetAddressFunction · 0.76