server

package
v0.0.0-...-364094e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 27, 2014 License: BSD-2-Clause Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WaitTimeoutError = errors.New("timeout")

Functions

This section is empty.

Types

type ConnectionManager

type ConnectionManager struct {
	*sync.WaitGroup
	Counter int
}

func NewConnectionManager

func NewConnectionManager() *ConnectionManager

func (*ConnectionManager) Add

func (cm *ConnectionManager) Add(delta int)

func (*ConnectionManager) Done

func (cm *ConnectionManager) Done()

type Server

type Server struct {
	// contains filtered or unexported fields
}

func New

func New(logger *logger.Logger, port int) (*Server, error)

func NewFromFD

func NewFromFD(logger *logger.Logger, fd uintptr) (*Server, error)

func (*Server) Addr

func (s *Server) Addr() net.Addr

func (*Server) ConnectionsCounter

func (s *Server) ConnectionsCounter() int

func (*Server) ListenerFD

func (s *Server) ListenerFD() (uintptr, error)

func (*Server) StartAcceptLoop

func (s *Server) StartAcceptLoop()

func (*Server) Stop

func (s *Server) Stop()

func (*Server) Wait

func (s *Server) Wait()

func (*Server) WaitWithTimeout

func (s *Server) WaitWithTimeout(duration time.Duration) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL