model

package
v0.0.0-...-655ee65 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2020 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	JanusEventTypeSession int = 1 << iota
	JanusEventTypeHandle
	JanusEventTypeExternal
	JanusEventTypeJSep
	JanusEventTypeWebRTC
	JanusEventTypeMedia
	JanusEventTypePlugin
	JanusEventTypeTransport
	JanusEventTypeCore
)

Constants for the Janus events

View Source
const JanusSIPPlugin = "janus.plugin.sip"

JanusSIPPlugin is the name of the SIP plugin in Janus

Variables

This section is empty.

Functions

This section is empty.

Types

type BeginTransaction

type BeginTransaction struct {
	Request BeginTransactionRequest `json:"request"`
}

BeginTransaction is the begin transaction message

type BeginTransactionRequest

type BeginTransactionRequest struct {
	Tenant                string `json:"tenant"`
	TransactionTag        string `json:"transaction_tag"`
	AccountTag            string `json:"account_tag"`
	DestinationAccountTag string `json:"destination_account_tag"`
	Source                string `json:"source"`
	Destination           string `json:"destination"`
	TimestampBegin        string `json:"timestamp_begin"`
}

BeginTransactionRequest is the begin transaction request object

type Call

type Call struct {
	Tenant                string    `json:"tenant"`
	TransactionTag        string    `json:"transaction_tag"`
	AccountTag            string    `json:"account_tag"`
	DestinationAccountTag string    `json:"destination_account_tag"`
	Source                string    `json:"source"`
	Destination           string    `json:"destination"`
	CSeq                  string    `json:"cseq"`
	TimestampInvite       time.Time `json:"timestamp_begin"`
	TimestampAck          time.Time `json:"timestamp_ack"`
	TimestampBye          time.Time `json:"timestamp_bye"`
}

Call stores the status of a call in the state manager

type EndTransaction

type EndTransaction struct {
	Request EndTransactionRequest `json:"request"`
}

EndTransaction is the begin transaction message

type EndTransactionRequest

type EndTransactionRequest struct {
	Tenant                string `json:"tenant"`
	TransactionTag        string `json:"transaction_tag"`
	AccountTag            string `json:"account_tag"`
	DestinationAccountTag string `json:"destination_account_tag"`
	TimestampEnd          string `json:"timestamp_end"`
}

EndTransactionRequest is the begin transaction request object

type Event

type Event struct {
	Emitter   string                 `json:"emitter,omitempty"`
	Type      int                    `json:"type"`
	Timestamp int64                  `json:"timestamp"`
	SessionID int64                  `json:"session_id"`
	HandleID  int64                  `json:"handle_id"`
	OpaqueID  string                 `json:"opaque_id,omitempty"`
	Event     map[string]interface{} `json:"event"`
}

Event stores the event received from a Janus Gateway instance

type EventPlugin

type EventPlugin struct {
	Plugin string                 `json:"plugin"`
	Data   map[string]interface{} `json:"data"`
}

EventPlugin stores the details of an event from a plugin

type EventPluginSIP

type EventPluginSIP struct {
	Event string `json:"event"`
	SIP   string `json:"sip"`
}

EventPluginSIP stores the data of a SIP event from the janus.plugin.sip plugin

type SIPMessage

type SIPMessage struct {
	*sipparser.SipMsg
	AccountTag            string
	DestinationAccountTag string
	Timestamp             time.Time
}

SIPMessage represents a SIP message

func SIPMessageFromString

func SIPMessageFromString(payload string) *SIPMessage

SIPMessageFromString returns a SIPMessage from a string

Jump to

Keyboard shortcuts

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