Documentation ¶
Index ¶
- type ConnectionGater
- func (_m *ConnectionGater) BlockAddr(ip net.IP) error
- func (_m *ConnectionGater) BlockPeer(p peer.ID) error
- func (_m *ConnectionGater) BlockSubnet(ipnet *net.IPNet) error
- func (_m *ConnectionGater) InterceptAccept(_a0 network.ConnMultiaddrs) bool
- func (_m *ConnectionGater) InterceptAddrDial(_a0 peer.ID, _a1 multiaddr.Multiaddr) bool
- func (_m *ConnectionGater) InterceptPeerDial(p peer.ID) bool
- func (_m *ConnectionGater) InterceptSecured(_a0 network.Direction, _a1 peer.ID, _a2 network.ConnMultiaddrs) bool
- func (_m *ConnectionGater) InterceptUpgraded(_a0 network.Conn) (bool, control.DisconnectReason)
- func (_m *ConnectionGater) IsBlocked(p peer.ID) bool
- func (_m *ConnectionGater) ListBlockedAddrs() []net.IP
- func (_m *ConnectionGater) ListBlockedPeers() []peer.ID
- func (_m *ConnectionGater) ListBlockedSubnets() []*net.IPNet
- func (_m *ConnectionGater) UnblockAddr(ip net.IP) error
- func (_m *ConnectionGater) UnblockPeer(p peer.ID) error
- func (_m *ConnectionGater) UnblockSubnet(ipnet *net.IPNet) error
- type GossipMetricer
- type PeerGater
- type Peerstore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConnectionGater ¶
ConnectionGater is an autogenerated mock type for the ConnectionGater type
func NewConnectionGater ¶
func NewConnectionGater(t mockConstructorTestingTNewConnectionGater) *ConnectionGater
NewConnectionGater creates a new instance of ConnectionGater. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func (*ConnectionGater) BlockAddr ¶
func (_m *ConnectionGater) BlockAddr(ip net.IP) error
BlockAddr provides a mock function with given fields: ip
func (*ConnectionGater) BlockPeer ¶
func (_m *ConnectionGater) BlockPeer(p peer.ID) error
BlockPeer provides a mock function with given fields: p
func (*ConnectionGater) BlockSubnet ¶
func (_m *ConnectionGater) BlockSubnet(ipnet *net.IPNet) error
BlockSubnet provides a mock function with given fields: ipnet
func (*ConnectionGater) InterceptAccept ¶
func (_m *ConnectionGater) InterceptAccept(_a0 network.ConnMultiaddrs) bool
InterceptAccept provides a mock function with given fields: _a0
func (*ConnectionGater) InterceptAddrDial ¶
InterceptAddrDial provides a mock function with given fields: _a0, _a1
func (*ConnectionGater) InterceptPeerDial ¶
func (_m *ConnectionGater) InterceptPeerDial(p peer.ID) bool
InterceptPeerDial provides a mock function with given fields: p
func (*ConnectionGater) InterceptSecured ¶
func (_m *ConnectionGater) InterceptSecured(_a0 network.Direction, _a1 peer.ID, _a2 network.ConnMultiaddrs) bool
InterceptSecured provides a mock function with given fields: _a0, _a1, _a2
func (*ConnectionGater) InterceptUpgraded ¶
func (_m *ConnectionGater) InterceptUpgraded(_a0 network.Conn) (bool, control.DisconnectReason)
InterceptUpgraded provides a mock function with given fields: _a0
func (*ConnectionGater) IsBlocked ¶
func (_m *ConnectionGater) IsBlocked(p peer.ID) bool
IsBlocked provides a mock function with given fields: p
func (*ConnectionGater) ListBlockedAddrs ¶
func (_m *ConnectionGater) ListBlockedAddrs() []net.IP
ListBlockedAddrs provides a mock function with given fields:
func (*ConnectionGater) ListBlockedPeers ¶
func (_m *ConnectionGater) ListBlockedPeers() []peer.ID
ListBlockedPeers provides a mock function with given fields:
func (*ConnectionGater) ListBlockedSubnets ¶
func (_m *ConnectionGater) ListBlockedSubnets() []*net.IPNet
ListBlockedSubnets provides a mock function with given fields:
func (*ConnectionGater) UnblockAddr ¶
func (_m *ConnectionGater) UnblockAddr(ip net.IP) error
UnblockAddr provides a mock function with given fields: ip
func (*ConnectionGater) UnblockPeer ¶
func (_m *ConnectionGater) UnblockPeer(p peer.ID) error
UnblockPeer provides a mock function with given fields: p
func (*ConnectionGater) UnblockSubnet ¶
func (_m *ConnectionGater) UnblockSubnet(ipnet *net.IPNet) error
UnblockSubnet provides a mock function with given fields: ipnet
type GossipMetricer ¶
GossipMetricer is an autogenerated mock type for the GossipMetricer type
func NewGossipMetricer ¶
func NewGossipMetricer(t mockConstructorTestingTNewGossipMetricer) *GossipMetricer
NewGossipMetricer creates a new instance of GossipMetricer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func (*GossipMetricer) RecordGossipEvent ¶
func (_m *GossipMetricer) RecordGossipEvent(evType int32)
RecordGossipEvent provides a mock function with given fields: evType
func (*GossipMetricer) SetPeerScores ¶
func (_m *GossipMetricer) SetPeerScores(_a0 map[string]float64)
SetPeerScores provides a mock function with given fields: _a0
type PeerGater ¶
PeerGater is an autogenerated mock type for the PeerGater type
func NewPeerGater ¶
func NewPeerGater(t mockConstructorTestingTNewPeerGater) *PeerGater
NewPeerGater creates a new instance of PeerGater. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
type Peerstore ¶
Peerstore is an autogenerated mock type for the Peerstore type
func NewPeerstore ¶
func NewPeerstore(t mockConstructorTestingTNewPeerstore) *Peerstore
NewPeerstore creates a new instance of Peerstore. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.