Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ListenerHolder ¶
ListenerHolder holds an opened port that can only be handed off to 1 go routine.
func NewFromPortNumber ¶
func NewFromPortNumber(portNumber int) (*ListenerHolder, error)
NewFromPortNumber opens a TCP listener based on the port number provided.
func (*ListenerHolder) Close ¶
func (lh *ListenerHolder) Close() error
Close shutsdown the TCP listener.
func (*ListenerHolder) Number ¶
func (lh *ListenerHolder) Number() int
Number returns the port number.
Click to show internal directories.
Click to hide internal directories.