Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OurIPAddress ¶
func OurRandom16 ¶
func OurRandom16() uint32
func OurRandom32 ¶
func OurRandom32() uint32
func ReadSocket ¶
ReadSocket reads data from the connection.
Types ¶
type GroupSock ¶
type GroupSock struct {
// contains filtered or unexported fields
}
GroupSock is used to both send and receive packets. As the name suggests, it was originally designed to send/receive multicast, but it can send/receive unicast as well.
func NewGroupSock ¶
NewGroupSock returns a source-independent multicast group
func (*GroupSock) AddDestination ¶
AddDestination can add multiple destinations (addresses & ports) This can be used to implement multi-unicast.
func (*GroupSock) Close ¶
func (g *GroupSock) Close()
Close is responsible for disconnection from client.
func (*GroupSock) DelDestination ¶
func (g *GroupSock) DelDestination()
DelDestination can remove the destinations.
func (*GroupSock) GetSourcePort ¶
GetSourcePort returns the source port of system allocation.
func (*GroupSock) HandleRead ¶
HandleRead reads data from client connection.
Click to show internal directories.
Click to hide internal directories.