biz

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: May 5, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Close

func Close()

Close func

func Entry

func Entry(method string, peer *signal.Peer, msg json.RawMessage, accept signal.RespondFunc, reject signal.RejectFunc)

Entry is the biz entry

func Init

func Init(dcID, nodeID, rpcID, eventID string, natsURL string)

Init func

func WatchServiceNodes

func WatchServiceNodes(service string, state discovery.NodeStateType, node discovery.Node)

WatchServiceNodes .

Types

type BroadcastMsg added in v0.3.0

type BroadcastMsg struct {
	RoomInfo
	Info json.RawMessage `json:"info"`
}

type CloseMsg added in v0.3.0

type CloseMsg struct {
	LeaveMsg
}

type JoinMsg added in v0.3.0

type JoinMsg struct {
	RoomInfo
	Info UserInfo `json:"info"`
}

type LeaveMsg added in v0.3.0

type LeaveMsg struct {
	RoomInfo
	Info UserInfo `json:"info"`
}

type LoginMsg added in v0.3.0

type LoginMsg struct {
}

type MediaInfo added in v0.3.0

type MediaInfo struct {
	Mid string `json:"mid"`
}

type PublishMsg added in v0.3.0

type PublishMsg struct {
	RoomInfo
	Jsep    webrtc.SessionDescription `json:"jsep"`
	Options PublishOptions            `json:"options"`
}

type PublishOptions added in v0.3.0

type PublishOptions struct {
	Codec      string `json:"codec"`
	Resolution string `json:"resolution"`
	Bandwidth  int    `json:"bandwidth"`
	Audio      bool   `json:"audio"`
	Video      bool   `json:"video"`
	Screen     bool   `json:"screen"`
}

type RoomInfo added in v0.3.0

type RoomInfo struct {
	Rid string `json:"rid"`
	Uid string `json:"uid"`
}

type SubscribeMsg added in v0.3.0

type SubscribeMsg struct {
	MediaInfo
	Jsep webrtc.SessionDescription `json:"jsep"`
}

type TrickleMsg added in v0.3.0

type TrickleMsg struct {
	RoomInfo
	MediaInfo
	Info    json.RawMessage `json:"info"`
	Trickle json.RawMessage `json:"trickle"`
}

type UnpublishMsg added in v0.3.0

type UnpublishMsg struct {
	RoomInfo
	MediaInfo
	Options PublishOptions `json:"options"`
}

type UnsubscribeMsg added in v0.3.0

type UnsubscribeMsg struct {
	MediaInfo
}

type UserInfo added in v0.3.0

type UserInfo struct {
	Name string `json:"name"`
}

Jump to

Keyboard shortcuts

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