Documentation
¶
Index ¶
- Constants
- func AEADOpen(mode int, key, nonce, ciphertext, aad []byte) ([]byte, error)
- func AEADSeal(mode int, key, nonce, plaintext, aad []byte) ([]byte, error)
- func DH(private, remotePublic []byte) (giznet.Key, error)
- func HKDFSHA256(secret, salt []byte, info string, out []byte) error
- func KeyPairFromPrivate(private []byte) (giznet.KeyPair, error)
- func Random(out []byte) error
- func TimeInstantMs() int64
- func TimeUnixMs() int64
- type Backend
- func (b *Backend) AddICEServer(url, username, credential string) error
- func (b *Backend) BufferedAmount(channelID int) (uint64, error)
- func (b *Backend) Close()
- func (b *Backend) CloseDataChannel(channelID int)
- func (b *Backend) CreateDataChannel(label string, channelID int, ordered, reliable bool) error
- func (b *Backend) CreatePeer() error
- func (b *Backend) HTTPRequest(method int, url string, headers []HTTPHeader, body []byte) (HTTPResponse, error)
- func (b *Backend) Poll(timeoutMS int)
- func (b *Backend) Send(channelID int, data []byte, isText bool) error
- func (b *Backend) SetBufferedAmountLowThreshold(channelID int, bytes uint64) error
- func (b *Backend) SetEventSink(sink EventSink)
- func (b *Backend) SetRemoteSDP(answer string) error
- func (b *Backend) StartOffer() (string, error)
- type EventSink
- type HTTPHeader
- type HTTPResponse
Constants ¶
View Source
const ( SignalingPath = "/webrtc/v1/offer" MediaStreamOpus = "audio/opus" HTTPMethodGet = 1 HTTPMethodPost = 2 HTTPMethodPut = 3 HTTPMethodPatch = 4 HTTPMethodDelete = 5 HTTPMethodHead = 6 HTTPMethodOptions = 7 CipherChaCha20Poly1305 = 1 CipherAES256GCM = 2 CipherPlaintext = 3 RTCChannelOpen = 1 RTCChannelClosed = 2 )
Variables ¶
This section is empty.
Functions ¶
func TimeInstantMs ¶
func TimeInstantMs() int64
func TimeUnixMs ¶
func TimeUnixMs() int64
Types ¶
type Backend ¶
type Backend struct {
// contains filtered or unexported fields
}
func (*Backend) AddICEServer ¶
func (*Backend) CloseDataChannel ¶
func (*Backend) CreateDataChannel ¶
func (*Backend) CreatePeer ¶
func (*Backend) HTTPRequest ¶
func (b *Backend) HTTPRequest(method int, url string, headers []HTTPHeader, body []byte) (HTTPResponse, error)
func (*Backend) SetBufferedAmountLowThreshold ¶
func (*Backend) SetEventSink ¶
func (*Backend) SetRemoteSDP ¶
func (*Backend) StartOffer ¶
type HTTPHeader ¶
type HTTPResponse ¶
Click to show internal directories.
Click to hide internal directories.