Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EstuaryPeeringService ¶
type EstuaryPeeringService struct {
*peering.PeeringService
}
A wrapper for the `PeeringService` struct.
func NewEstuaryPeeringService ¶
func NewEstuaryPeeringService(host host.Host) *EstuaryPeeringService
NewEstuaryPeeringService Construct a new Estuary Peering Service
func (*EstuaryPeeringService) AddPeer ¶
func (ps *EstuaryPeeringService) AddPeer(info peer.AddrInfo)
AddPeer this function adds a peer on the current EstuaryPeeringService
func (*EstuaryPeeringService) ListPeers ¶
func (ps *EstuaryPeeringService) ListPeers() []peer.AddrInfo
ListPeers this function lists all peers on the current EstuaryPeeringService
func (*EstuaryPeeringService) RemovePeer ¶
func (ps *EstuaryPeeringService) RemovePeer(peerId peer.ID)
RemovePeer this function removes a peer on the current EstuaryPeeringService
func (*EstuaryPeeringService) Start ¶
func (ps *EstuaryPeeringService) Start() error
Start this function starts the EstuaryPeeringService
func (*EstuaryPeeringService) Stop ¶
func (ps *EstuaryPeeringService) Stop() error
Stop this function stop the EstuaryPeeringService
type PeeringPeer ¶
type PeeringPeer struct { ID string `json:"ID"` Addrs []string `json:"Addrs"` Connected bool `json:"Connected,omitempty"` }
A struct that is used to store the information of a peer.
Click to show internal directories.
Click to hide internal directories.