server/client_handler.go
crusader cb96187314 ing
2017-10-27 16:48:49 +09:00

22 lines
417 B
Go

package server
import (
"io"
"time"
)
type ClientHandler interface {
Dial() (conn io.ReadWriteCloser, err error)
OnHandshake(remoteAddr string, rwc io.ReadWriteCloser) error
Handle(rwc io.ReadWriteCloser, stopChan chan struct{})
GetAddr() string
GetPendingRequests() int
GetRequestTimeout() time.Duration
GetSendBufferSize() int
GetRecvBufferSize() int
GetKeepAlivePeriod() time.Duration
Validate()
}