mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
common errors as variable.
This commit is contained in:
@ -2,6 +2,7 @@ package types
|
||||
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"math"
|
||||
"strings"
|
||||
@ -12,6 +13,10 @@ import (
|
||||
"demodesk/neko/internal/types/codec"
|
||||
)
|
||||
|
||||
var (
|
||||
ErrCapturePipelineAlreadyExists = errors.New("capture pipeline already exists")
|
||||
)
|
||||
|
||||
type Sample media.Sample
|
||||
|
||||
type BroadcastManager interface {
|
||||
|
@ -1,5 +1,13 @@
|
||||
package types
|
||||
|
||||
import "errors"
|
||||
|
||||
var (
|
||||
ErrMemberAlreadyExists = errors.New("member already exists")
|
||||
ErrMemberDoesNotExist = errors.New("member does not exist")
|
||||
ErrMemberInvalidPassword = errors.New("invalid password")
|
||||
)
|
||||
|
||||
type MemberProfile struct {
|
||||
Name string `json:"name"`
|
||||
IsAdmin bool `json:"is_admin"`
|
||||
|
@ -1,6 +1,16 @@
|
||||
package types
|
||||
|
||||
import "net/http"
|
||||
import (
|
||||
"errors"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
var (
|
||||
ErrSessionNotFound = errors.New("session not found")
|
||||
ErrSessionAlreadyExists = errors.New("session already exists")
|
||||
ErrSessionAlreadyConnected = errors.New("session is already connected")
|
||||
ErrSessionLoginDisabled = errors.New("session login disabled")
|
||||
)
|
||||
|
||||
type SessionState struct {
|
||||
IsConnected bool `json:"is_connected"`
|
||||
|
@ -1,6 +1,15 @@
|
||||
package types
|
||||
|
||||
import "github.com/pion/webrtc/v3"
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"github.com/pion/webrtc/v3"
|
||||
)
|
||||
|
||||
var (
|
||||
ErrWebRTCVideoNotFound = errors.New("webrtc video not found")
|
||||
ErrWebRTCDataChannelNotFound = errors.New("webrtc data channel not found")
|
||||
)
|
||||
|
||||
type ICEServer struct {
|
||||
URLs []string `mapstructure:"urls" json:"urls"`
|
||||
|
Reference in New Issue
Block a user