Documentation ¶
Index ¶
- Variables
- type AddrBookRecord
- func (*AddrBookRecord) Descriptor() ([]byte, []int)
- func (m *AddrBookRecord) GetAddrs() []*AddrBookRecord_AddrEntry
- func (m *AddrBookRecord) GetCertifiedRecord() *AddrBookRecord_CertifiedRecord
- func (m *AddrBookRecord) Marshal() (dAtA []byte, err error)
- func (m *AddrBookRecord) MarshalTo(dAtA []byte) (int, error)
- func (m *AddrBookRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*AddrBookRecord) ProtoMessage()
- func (m *AddrBookRecord) Reset()
- func (m *AddrBookRecord) Size() (n int)
- func (m *AddrBookRecord) String() string
- func (m *AddrBookRecord) Unmarshal(dAtA []byte) error
- func (m *AddrBookRecord) XXX_DiscardUnknown()
- func (m *AddrBookRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *AddrBookRecord) XXX_Merge(src proto.Message)
- func (m *AddrBookRecord) XXX_Size() int
- func (m *AddrBookRecord) XXX_Unmarshal(b []byte) error
- type AddrBookRecord_AddrEntry
- func (*AddrBookRecord_AddrEntry) Descriptor() ([]byte, []int)
- func (m *AddrBookRecord_AddrEntry) GetExpiry() int64
- func (m *AddrBookRecord_AddrEntry) GetTtl() int64
- func (m *AddrBookRecord_AddrEntry) Marshal() (dAtA []byte, err error)
- func (m *AddrBookRecord_AddrEntry) MarshalTo(dAtA []byte) (int, error)
- func (m *AddrBookRecord_AddrEntry) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*AddrBookRecord_AddrEntry) ProtoMessage()
- func (m *AddrBookRecord_AddrEntry) Reset()
- func (m *AddrBookRecord_AddrEntry) Size() (n int)
- func (m *AddrBookRecord_AddrEntry) String() string
- func (m *AddrBookRecord_AddrEntry) Unmarshal(dAtA []byte) error
- func (m *AddrBookRecord_AddrEntry) XXX_DiscardUnknown()
- func (m *AddrBookRecord_AddrEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *AddrBookRecord_AddrEntry) XXX_Merge(src proto.Message)
- func (m *AddrBookRecord_AddrEntry) XXX_Size() int
- func (m *AddrBookRecord_AddrEntry) XXX_Unmarshal(b []byte) error
- type AddrBookRecord_CertifiedRecord
- func (*AddrBookRecord_CertifiedRecord) Descriptor() ([]byte, []int)
- func (m *AddrBookRecord_CertifiedRecord) GetRaw() []byte
- func (m *AddrBookRecord_CertifiedRecord) GetSeq() uint64
- func (m *AddrBookRecord_CertifiedRecord) Marshal() (dAtA []byte, err error)
- func (m *AddrBookRecord_CertifiedRecord) MarshalTo(dAtA []byte) (int, error)
- func (m *AddrBookRecord_CertifiedRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*AddrBookRecord_CertifiedRecord) ProtoMessage()
- func (m *AddrBookRecord_CertifiedRecord) Reset()
- func (m *AddrBookRecord_CertifiedRecord) Size() (n int)
- func (m *AddrBookRecord_CertifiedRecord) String() string
- func (m *AddrBookRecord_CertifiedRecord) Unmarshal(dAtA []byte) error
- func (m *AddrBookRecord_CertifiedRecord) XXX_DiscardUnknown()
- func (m *AddrBookRecord_CertifiedRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *AddrBookRecord_CertifiedRecord) XXX_Merge(src proto.Message)
- func (m *AddrBookRecord_CertifiedRecord) XXX_Size() int
- func (m *AddrBookRecord_CertifiedRecord) XXX_Unmarshal(b []byte) error
- type ProtoAddr
- type ProtoPeerID
- func (id ProtoPeerID) Marshal() ([]byte, error)
- func (id ProtoPeerID) MarshalJSON() ([]byte, error)
- func (id ProtoPeerID) MarshalTo(data []byte) (n int, err error)
- func (id ProtoPeerID) Size() int
- func (id *ProtoPeerID) Unmarshal(data []byte) (err error)
- func (id *ProtoPeerID) UnmarshalJSON(data []byte) error
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type AddrBookRecord ¶
type AddrBookRecord struct { // The peer ID. Id *ProtoPeerID `protobuf:"bytes,1,opt,name=id,proto3,customtype=ProtoPeerID" json:"id,omitempty"` // The multiaddresses. This is a sorted list where element 0 expires the soonest. Addrs []*AddrBookRecord_AddrEntry `protobuf:"bytes,2,rep,name=addrs,proto3" json:"addrs,omitempty"` // The most recently received signed PeerRecord. CertifiedRecord *AddrBookRecord_CertifiedRecord `protobuf:"bytes,3,opt,name=certified_record,json=certifiedRecord,proto3" json:"certified_record,omitempty"` }
AddrBookRecord represents a record for a peer in the address book.
func NewPopulatedAddrBookRecord ¶
func NewPopulatedAddrBookRecord(r randyPstore, easy bool) *AddrBookRecord
func (*AddrBookRecord) Descriptor ¶
func (*AddrBookRecord) Descriptor() ([]byte, []int)
func (*AddrBookRecord) GetAddrs ¶
func (m *AddrBookRecord) GetAddrs() []*AddrBookRecord_AddrEntry
func (*AddrBookRecord) GetCertifiedRecord ¶
func (m *AddrBookRecord) GetCertifiedRecord() *AddrBookRecord_CertifiedRecord
func (*AddrBookRecord) Marshal ¶
func (m *AddrBookRecord) Marshal() (dAtA []byte, err error)
func (*AddrBookRecord) MarshalToSizedBuffer ¶
func (m *AddrBookRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*AddrBookRecord) ProtoMessage ¶
func (*AddrBookRecord) ProtoMessage()
func (*AddrBookRecord) Reset ¶
func (m *AddrBookRecord) Reset()
func (*AddrBookRecord) Size ¶
func (m *AddrBookRecord) Size() (n int)
func (*AddrBookRecord) String ¶
func (m *AddrBookRecord) String() string
func (*AddrBookRecord) Unmarshal ¶
func (m *AddrBookRecord) Unmarshal(dAtA []byte) error
func (*AddrBookRecord) XXX_DiscardUnknown ¶
func (m *AddrBookRecord) XXX_DiscardUnknown()
func (*AddrBookRecord) XXX_Marshal ¶
func (m *AddrBookRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*AddrBookRecord) XXX_Merge ¶
func (m *AddrBookRecord) XXX_Merge(src proto.Message)
func (*AddrBookRecord) XXX_Size ¶
func (m *AddrBookRecord) XXX_Size() int
func (*AddrBookRecord) XXX_Unmarshal ¶
func (m *AddrBookRecord) XXX_Unmarshal(b []byte) error
type AddrBookRecord_AddrEntry ¶
type AddrBookRecord_AddrEntry struct { Addr *ProtoAddr `protobuf:"bytes,1,opt,name=addr,proto3,customtype=ProtoAddr" json:"addr,omitempty"` // The point in time when this address expires. Expiry int64 `protobuf:"varint,2,opt,name=expiry,proto3" json:"expiry,omitempty"` // The original TTL of this address. Ttl int64 `protobuf:"varint,3,opt,name=ttl,proto3" json:"ttl,omitempty"` }
AddrEntry represents a single multiaddress.
func NewPopulatedAddrBookRecord_AddrEntry ¶
func NewPopulatedAddrBookRecord_AddrEntry(r randyPstore, easy bool) *AddrBookRecord_AddrEntry
func (*AddrBookRecord_AddrEntry) Descriptor ¶
func (*AddrBookRecord_AddrEntry) Descriptor() ([]byte, []int)
func (*AddrBookRecord_AddrEntry) GetExpiry ¶
func (m *AddrBookRecord_AddrEntry) GetExpiry() int64
func (*AddrBookRecord_AddrEntry) GetTtl ¶
func (m *AddrBookRecord_AddrEntry) GetTtl() int64
func (*AddrBookRecord_AddrEntry) Marshal ¶
func (m *AddrBookRecord_AddrEntry) Marshal() (dAtA []byte, err error)
func (*AddrBookRecord_AddrEntry) MarshalTo ¶
func (m *AddrBookRecord_AddrEntry) MarshalTo(dAtA []byte) (int, error)
func (*AddrBookRecord_AddrEntry) MarshalToSizedBuffer ¶
func (m *AddrBookRecord_AddrEntry) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*AddrBookRecord_AddrEntry) ProtoMessage ¶
func (*AddrBookRecord_AddrEntry) ProtoMessage()
func (*AddrBookRecord_AddrEntry) Reset ¶
func (m *AddrBookRecord_AddrEntry) Reset()
func (*AddrBookRecord_AddrEntry) Size ¶
func (m *AddrBookRecord_AddrEntry) Size() (n int)
func (*AddrBookRecord_AddrEntry) String ¶
func (m *AddrBookRecord_AddrEntry) String() string
func (*AddrBookRecord_AddrEntry) Unmarshal ¶
func (m *AddrBookRecord_AddrEntry) Unmarshal(dAtA []byte) error
func (*AddrBookRecord_AddrEntry) XXX_DiscardUnknown ¶
func (m *AddrBookRecord_AddrEntry) XXX_DiscardUnknown()
func (*AddrBookRecord_AddrEntry) XXX_Marshal ¶
func (m *AddrBookRecord_AddrEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*AddrBookRecord_AddrEntry) XXX_Merge ¶
func (m *AddrBookRecord_AddrEntry) XXX_Merge(src proto.Message)
func (*AddrBookRecord_AddrEntry) XXX_Size ¶
func (m *AddrBookRecord_AddrEntry) XXX_Size() int
func (*AddrBookRecord_AddrEntry) XXX_Unmarshal ¶
func (m *AddrBookRecord_AddrEntry) XXX_Unmarshal(b []byte) error
type AddrBookRecord_CertifiedRecord ¶
type AddrBookRecord_CertifiedRecord struct { // The Seq counter from the signed PeerRecord envelope Seq uint64 `protobuf:"varint,1,opt,name=seq,proto3" json:"seq,omitempty"` // The serialized bytes of the SignedEnvelope containing the PeerRecord. Raw []byte `protobuf:"bytes,2,opt,name=raw,proto3" json:"raw,omitempty"` }
CertifiedRecord contains a serialized signed PeerRecord used to populate the signedAddrs list.
func NewPopulatedAddrBookRecord_CertifiedRecord ¶
func NewPopulatedAddrBookRecord_CertifiedRecord(r randyPstore, easy bool) *AddrBookRecord_CertifiedRecord
func (*AddrBookRecord_CertifiedRecord) Descriptor ¶
func (*AddrBookRecord_CertifiedRecord) Descriptor() ([]byte, []int)
func (*AddrBookRecord_CertifiedRecord) GetRaw ¶
func (m *AddrBookRecord_CertifiedRecord) GetRaw() []byte
func (*AddrBookRecord_CertifiedRecord) GetSeq ¶
func (m *AddrBookRecord_CertifiedRecord) GetSeq() uint64
func (*AddrBookRecord_CertifiedRecord) Marshal ¶
func (m *AddrBookRecord_CertifiedRecord) Marshal() (dAtA []byte, err error)
func (*AddrBookRecord_CertifiedRecord) MarshalTo ¶
func (m *AddrBookRecord_CertifiedRecord) MarshalTo(dAtA []byte) (int, error)
func (*AddrBookRecord_CertifiedRecord) MarshalToSizedBuffer ¶
func (m *AddrBookRecord_CertifiedRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*AddrBookRecord_CertifiedRecord) ProtoMessage ¶
func (*AddrBookRecord_CertifiedRecord) ProtoMessage()
func (*AddrBookRecord_CertifiedRecord) Reset ¶
func (m *AddrBookRecord_CertifiedRecord) Reset()
func (*AddrBookRecord_CertifiedRecord) Size ¶
func (m *AddrBookRecord_CertifiedRecord) Size() (n int)
func (*AddrBookRecord_CertifiedRecord) String ¶
func (m *AddrBookRecord_CertifiedRecord) String() string
func (*AddrBookRecord_CertifiedRecord) Unmarshal ¶
func (m *AddrBookRecord_CertifiedRecord) Unmarshal(dAtA []byte) error
func (*AddrBookRecord_CertifiedRecord) XXX_DiscardUnknown ¶
func (m *AddrBookRecord_CertifiedRecord) XXX_DiscardUnknown()
func (*AddrBookRecord_CertifiedRecord) XXX_Marshal ¶
func (m *AddrBookRecord_CertifiedRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*AddrBookRecord_CertifiedRecord) XXX_Merge ¶
func (m *AddrBookRecord_CertifiedRecord) XXX_Merge(src proto.Message)
func (*AddrBookRecord_CertifiedRecord) XXX_Size ¶
func (m *AddrBookRecord_CertifiedRecord) XXX_Size() int
func (*AddrBookRecord_CertifiedRecord) XXX_Unmarshal ¶
func (m *AddrBookRecord_CertifiedRecord) XXX_Unmarshal(b []byte) error
type ProtoAddr ¶
ProtoAddr is a custom type used by gogo to serde raw multiaddresses into the ma.Multiaddr type, and back.
func NewPopulatedProtoAddr ¶
func NewPopulatedProtoAddr(r randyPstore) *ProtoAddr
NewPopulatedProtoAddr generates a populated instance of the custom gogo type ProtoAddr. It is required by gogo-generated tests.
func (ProtoAddr) MarshalJSON ¶
func (*ProtoAddr) UnmarshalJSON ¶
type ProtoPeerID ¶
ProtoAddr is a custom type used by gogo to serde raw peer IDs into the peer.ID type, and back.
func NewPopulatedProtoPeerID ¶
func NewPopulatedProtoPeerID(r randyPstore) *ProtoPeerID
NewPopulatedProtoPeerID generates a populated instance of the custom gogo type ProtoPeerID. It is required by gogo-generated tests.
func (ProtoPeerID) Marshal ¶
func (id ProtoPeerID) Marshal() ([]byte, error)
func (ProtoPeerID) MarshalJSON ¶
func (id ProtoPeerID) MarshalJSON() ([]byte, error)
func (ProtoPeerID) Size ¶
func (id ProtoPeerID) Size() int
func (*ProtoPeerID) Unmarshal ¶
func (id *ProtoPeerID) Unmarshal(data []byte) (err error)
func (*ProtoPeerID) UnmarshalJSON ¶
func (id *ProtoPeerID) UnmarshalJSON(data []byte) error