Documentation ¶
Index ¶
- Constants
- type BufferedConnectionEvents
- type Callback
- type DataConsumer
- type ErrorConsumer
- type ManagedConnection
- func (this *ManagedConnection) Close() error
- func (this *ManagedConnection) LocalAddr() net.Addr
- func (this *ManagedConnection) Read(receiveBuffer []byte) (n int, err error)
- func (this *ManagedConnection) RemoteAddr() net.Addr
- func (this *ManagedConnection) SetDeadline(t time.Time) error
- func (this *ManagedConnection) SetReadDeadline(t time.Time) error
- func (this *ManagedConnection) SetReadTimeout(d time.Duration) error
- func (this *ManagedConnection) SetTimeout(d time.Duration) error
- func (this *ManagedConnection) SetWriteDeadline(t time.Time) error
- func (this *ManagedConnection) SetWriteTimeout(d time.Duration) error
- func (this *ManagedConnection) Write(data []byte) (n int, err error)
Constants ¶
View Source
const (
READ_BUFFER_SIZE = 81920
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataConsumer ¶
type DataConsumer func(data []byte)
type ErrorConsumer ¶
type ErrorConsumer func(err error)
type ManagedConnection ¶
type ManagedConnection struct { Conn net.Conn Events BufferedConnectionEvents BytesRead int BytesWritten int // contains filtered or unexported fields }
func NewManagedConnection ¶
func NewManagedConnection(conn net.Conn) *ManagedConnection
func (*ManagedConnection) Close ¶
func (this *ManagedConnection) Close() error
func (*ManagedConnection) LocalAddr ¶
func (this *ManagedConnection) LocalAddr() net.Addr
func (*ManagedConnection) Read ¶
func (this *ManagedConnection) Read(receiveBuffer []byte) (n int, err error)
func (*ManagedConnection) RemoteAddr ¶
func (this *ManagedConnection) RemoteAddr() net.Addr
func (*ManagedConnection) SetDeadline ¶
func (this *ManagedConnection) SetDeadline(t time.Time) error
func (*ManagedConnection) SetReadDeadline ¶
func (this *ManagedConnection) SetReadDeadline(t time.Time) error
func (*ManagedConnection) SetReadTimeout ¶
func (this *ManagedConnection) SetReadTimeout(d time.Duration) error
func (*ManagedConnection) SetTimeout ¶
func (this *ManagedConnection) SetTimeout(d time.Duration) error
func (*ManagedConnection) SetWriteDeadline ¶
func (this *ManagedConnection) SetWriteDeadline(t time.Time) error
func (*ManagedConnection) SetWriteTimeout ¶
func (this *ManagedConnection) SetWriteTimeout(d time.Duration) error
Click to show internal directories.
Click to hide internal directories.