Documentation
¶
Index ¶
- type Connection
- type Server
- func (s *Server) Accept() (string, error)
- func (s *Server) Addr() net.Addr
- func (s *Server) Close() error
- func (s *Server) GetConnection(id string) (net.Conn, error)
- func (s *Server) RemoveConnection(id string) error
- func (s *Server) Send(id string, payload []byte) error
- func (s *Server) SetConnection(conn net.Conn) (string, error)
- func (s *Server) SetOnConnect(f func(id string))
- func (s *Server) SetOnData(f func(id string, payload []byte))
- func (s *Server) SetOnDisconnect(f func(id string))
- func (s *Server) SetOnError(f func(id string, err error))
- type Settings
- type UDPServer
- func (s *UDPServer) Accept() (string, error)
- func (s *UDPServer) Addr() net.Addr
- func (s *UDPServer) Close() error
- func (s *UDPServer) GetConnection(id string) (net.Conn, error)
- func (s *UDPServer) Send(id string, payload []byte) error
- func (s *UDPServer) SetOnConnect(f func(id string))
- func (s *UDPServer) SetOnData(f func(id string, payload []byte))
- func (s *UDPServer) SetOnDisconnect(f func(id string))
- func (s *UDPServer) SetOnError(f func(id string, err error))
- type UDPSettings
- type WebRTCPeer
- type WebRTCServer
- func (s *WebRTCServer) Accept() (string, error)
- func (s *WebRTCServer) AddICECandidate(candidate webrtc.ICECandidateInit) error
- func (s *WebRTCServer) AddICECandidateForPeer(id string, candidate webrtc.ICECandidateInit) error
- func (s *WebRTCServer) Addr() net.Addr
- func (s *WebRTCServer) ApplyRemoteDescription(desc webrtc.SessionDescription) error
- func (s *WebRTCServer) ApplyRemoteDescriptionForPeer(id string, desc webrtc.SessionDescription) error
- func (s *WebRTCServer) Close() error
- func (s *WebRTCServer) CreatePeer(id string) (*WebRTCPeer, error)
- func (s *WebRTCServer) GetConnection(id string) (net.Conn, error)
- func (s *WebRTCServer) RemovePeer(id string) error
- func (s *WebRTCServer) Send(id string, payload []byte) error
- func (s *WebRTCServer) SetOnConnect(f func(id string))
- func (s *WebRTCServer) SetOnData(f func(id string, payload []byte))
- func (s *WebRTCServer) SetOnDisconnect(f func(id string))
- func (s *WebRTCServer) SetOnError(f func(id string, err error))
- func (s *WebRTCServer) SetOnLocalCandidate(f func(candidate webrtc.ICECandidateInit))
- func (s *WebRTCServer) SetOnLocalCandidateForPeer(f func(id string, candidate webrtc.ICECandidateInit))
- func (s *WebRTCServer) SetOnLocalDescription(f func(desc webrtc.SessionDescription))
- func (s *WebRTCServer) SetOnLocalDescriptionForPeer(f func(id string, desc webrtc.SessionDescription))
- type WebRTCSettings
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
type Connection struct {
// contains filtered or unexported fields
}
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) RemoveConnection ¶
func (*Server) SetOnConnect ¶
func (*Server) SetOnDisconnect ¶
func (*Server) SetOnError ¶
type UDPServer ¶
type UDPServer struct {
// contains filtered or unexported fields
}
func NewUDPServer ¶
func NewUDPServer(settings UDPSettings) (*UDPServer, error)
func (*UDPServer) SetOnConnect ¶
func (*UDPServer) SetOnDisconnect ¶
func (*UDPServer) SetOnError ¶
type UDPSettings ¶
type WebRTCPeer ¶
type WebRTCPeer struct {
// contains filtered or unexported fields
}
type WebRTCServer ¶
type WebRTCServer struct {
// contains filtered or unexported fields
}
func NewWebRTCServer ¶
func NewWebRTCServer(settings WebRTCSettings) (*WebRTCServer, error)
func (*WebRTCServer) Accept ¶
func (s *WebRTCServer) Accept() (string, error)
func (*WebRTCServer) AddICECandidate ¶
func (s *WebRTCServer) AddICECandidate(candidate webrtc.ICECandidateInit) error
func (*WebRTCServer) AddICECandidateForPeer ¶
func (s *WebRTCServer) AddICECandidateForPeer(id string, candidate webrtc.ICECandidateInit) error
func (*WebRTCServer) Addr ¶
func (s *WebRTCServer) Addr() net.Addr
func (*WebRTCServer) ApplyRemoteDescription ¶
func (s *WebRTCServer) ApplyRemoteDescription(desc webrtc.SessionDescription) error
func (*WebRTCServer) ApplyRemoteDescriptionForPeer ¶
func (s *WebRTCServer) ApplyRemoteDescriptionForPeer(id string, desc webrtc.SessionDescription) error
func (*WebRTCServer) Close ¶
func (s *WebRTCServer) Close() error
func (*WebRTCServer) CreatePeer ¶
func (s *WebRTCServer) CreatePeer(id string) (*WebRTCPeer, error)
func (*WebRTCServer) GetConnection ¶
func (s *WebRTCServer) GetConnection(id string) (net.Conn, error)
func (*WebRTCServer) RemovePeer ¶
func (s *WebRTCServer) RemovePeer(id string) error
func (*WebRTCServer) SetOnConnect ¶
func (s *WebRTCServer) SetOnConnect(f func(id string))
func (*WebRTCServer) SetOnData ¶
func (s *WebRTCServer) SetOnData(f func(id string, payload []byte))
func (*WebRTCServer) SetOnDisconnect ¶
func (s *WebRTCServer) SetOnDisconnect(f func(id string))
func (*WebRTCServer) SetOnError ¶
func (s *WebRTCServer) SetOnError(f func(id string, err error))
func (*WebRTCServer) SetOnLocalCandidate ¶
func (s *WebRTCServer) SetOnLocalCandidate(f func(candidate webrtc.ICECandidateInit))
func (*WebRTCServer) SetOnLocalCandidateForPeer ¶
func (s *WebRTCServer) SetOnLocalCandidateForPeer(f func(id string, candidate webrtc.ICECandidateInit))
func (*WebRTCServer) SetOnLocalDescription ¶
func (s *WebRTCServer) SetOnLocalDescription(f func(desc webrtc.SessionDescription))
func (*WebRTCServer) SetOnLocalDescriptionForPeer ¶
func (s *WebRTCServer) SetOnLocalDescriptionForPeer(f func(id string, desc webrtc.SessionDescription))
type WebRTCSettings ¶
type WebRTCSettings struct {
Configuration webrtc.Configuration
MaxFrameBytes uint32
MaxDecompressedBytes uint32
ZipThreshold uint32
}
Click to show internal directories.
Click to hide internal directories.