Documentation ¶
Index ¶
- type AddressesMap
- func (m *AddressesMap) Delete(k string)
- func (m *AddressesMap) Get(k string) (*addressState, bool)
- func (m *AddressesMap) GetOrPut(k string, v *addressState) (*addressState, bool)
- func (m *AddressesMap) ListKeys() []string
- func (m *AddressesMap) ListValues() []*addressState
- func (m *AddressesMap) Put(k string, v *addressState)
- func (m *AddressesMap) Range(i func(k string, v *addressState) bool)
- type ConnectionCleanup
- type ConnectionHandler
- type ConnectionsMap
- func (m *ConnectionsMap) Delete(k string)
- func (m *ConnectionsMap) Get(k string) (*peerbox, bool)
- func (m *ConnectionsMap) GetOrPut(k string, v *peerbox) (*peerbox, bool)
- func (m *ConnectionsMap) ListKeys() []string
- func (m *ConnectionsMap) ListValues() []*peerbox
- func (m *ConnectionsMap) Put(k string, v *peerbox)
- func (m *ConnectionsMap) Range(i func(k string, v *peerbox) bool)
- type Manager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddressesMap ¶
type AddressesMap struct {
// contains filtered or unexported fields
}
AddressesMap -
func NewAddressesMap ¶
func NewAddressesMap() *AddressesMap
NewAddressesMap constructs a new SyncMap
func (*AddressesMap) GetOrPut ¶
func (m *AddressesMap) GetOrPut(k string, v *addressState) (*addressState, bool)
GetOrPut -
func (*AddressesMap) Range ¶
func (m *AddressesMap) Range(i func(k string, v *addressState) bool)
Range -
type ConnectionCleanup ¶ added in v0.17.2
type ConnectionCleanup func()
type ConnectionHandler ¶
type ConnectionHandler func(*net.Connection, ConnectionCleanup) error
type ConnectionsMap ¶
type ConnectionsMap struct {
// contains filtered or unexported fields
}
ConnectionsMap -
func NewConnectionsMap ¶
func NewConnectionsMap() *ConnectionsMap
NewConnectionsMap constructs a new SyncMap
func (*ConnectionsMap) GetOrPut ¶
func (m *ConnectionsMap) GetOrPut(k string, v *peerbox) (*peerbox, bool)
GetOrPut -
func (*ConnectionsMap) Range ¶
func (m *ConnectionsMap) Range(i func(k string, v *peerbox) bool)
Range -
type Manager ¶
type Manager interface { GetConnection( context.Context, *peer.ConnectionInfo, ) (*net.Connection, error) CloseConnection( *net.Connection, ) }
Click to show internal directories.
Click to hide internal directories.