Documentation
¶
Index ¶
Constants ¶
View Source
const ( StreamStateScheduled string = "scheduled" StreamStateRunning string = "running" StreamStateEnded string = "ended" StreamStatePending string = "pending" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Channel ¶
type Channel struct {
core.BaseModel `bson:",inline"`
UserId int `json:"-" gorm:"column:user_id"`
UserUID *core.UID `json:"userId" gorm:"-"`
Image *core.Image `json:"image" gorm:"column:image"`
UserName string `json:"userName" gorm:"column:user_name"`
DisplayName string `json:"displayName" gorm:"column:display_name"`
}
type Stream ¶
type Stream struct {
core.BaseModel `json:",inline"`
ChannelId int `json:"-" gorm:"column:channel_id"`
ChannelFakeId *core.UID `json:"ChannelId" gorm:"-"`
Channel *Channel `json:"channel" gorm:"foreignkey:ChannelId"`
Title string `json:"title" gorm:"column:title"`
Notification string `json:"notification" gorm:"column:notification"`
Description string `json:"description" gorm:"column:description"`
CategoryId int `json:"-" gorm:"column:category_id"`
Category *Category `json:"category" gorm:"foreignkey:CategoryId;preload=false"`
CategoryFakeId *core.UID `json:"-" gorm:"-"`
IsRerun bool `json:"isRerun" gorm:"column:is_rerun"`
StreamKey *uuid.UUID `json:"streamKey" gorm:"column:stream_key"`
State string `json:"state" gorm:"column:state"`
ActualStartTime *time.Time `json:"actualStartTime" gorm:"column:actual_start_time"`
ActualEndTime *time.Time `json:"actualEndTime" gorm:"column:actual_end_time"`
PeakConcurrentView int `json:"peakConcurrentView" gorm:"column:peak_concurrent_view"`
TotalUniqueViewers int `json:"totalUniqueViewers" gorm:"column:total_unique_viewers"`
ScheduledStartTime *time.Time `json:"scheduledStartTime" gorm:"column:scheduled_start_time"`
Status int `json:"status" gorm:"column:status"`
}
type StreamCreate ¶
type StreamCreate struct {
core.BaseModel `json:",inline"`
Title string `json:"title" gorm:"column:title" validate:"required"`
Description string `json:"description" gorm:"column:description" validate:"required"`
ChannelId int `json:"-" gorm:"column:channel_id"`
ChannelFakeId *core.UID `json:"channelId" gorm:"-"`
CategoryId int `json:"-" gorm:"column:category_id"`
CategoryFakeId *core.UID `json:"categoryId" gorm:"-"`
IsRerun bool `json:"isRerun" gorm:"column:is_rerun"`
Notification string `json:"notification" gorm:"column:notification"`
ScheduledStartTime *time.Time `json:"scheduledStartTime" gorm:"column:scheduled_start_time"`
StreamKey *uuid.UUID `json:"streamKey" gorm:"column:stream_key"`
}
func (*StreamCreate) UnMask ¶
func (s *StreamCreate) UnMask()
type StreamCreateResponse ¶
type StreamFilter ¶
type StreamFilter struct {
State string `json:"state" form:"state"`
CategoryFakeId string `json:"categoryId" form:"categoryId"`
CategoryId int `json:"-" form:"-"`
ChannelFakeId string `json:"channelId" form:"channelId"`
ChannelId int `json:"-" form:"-"`
UserName string `json:"userName" form:"userName"`
Title string `json:"title" form:"title"`
}
func (*StreamFilter) Process ¶
func (s *StreamFilter) Process() error
type StreamList ¶
type StreamList struct {
core.BaseModel `json:",inline"`
ChannelId int `json:"-" gorm:"column:channel_id"`
ChannelFakeId *core.UID `json:"ChannelId" gorm:"-"`
Channel *Channel `json:"channel" gorm:"foreignkey:ChannelId"`
Title string `json:"title" gorm:"column:title"`
Description string `json:"description" gorm:"column:description"`
CategoryId int `json:"-" gorm:"column:category_id"`
Category *Category `json:"category" gorm:"foreignkey:CategoryId;preload=false"`
CategoryFakeId *core.UID `json:"-" gorm:"-"`
CurrentView int `json:"currentView" gorm:"-"`
IsRerun bool `json:"isRerun" gorm:"column:is_rerun"`
State string `json:"state" gorm:"column:state"`
}
func (*StreamList) Mask ¶
func (s *StreamList) Mask()
type StreamUpdate ¶
type StreamUpdate struct {
Title *string `json:"title" gorm:"column:title"`
Description *string `json:"description" gorm:"column:description"`
IsRerun *bool `json:"isRerun" gorm:"column:is_rerun"`
Notification *string `json:"notification" gorm:"column:notification"`
ScheduledStartTime *time.Time `json:"scheduledStartTime" gorm:"column:scheduled_start_time"`
State *string `json:"state" gorm:"column:state"`
}
Click to show internal directories.
Click to hide internal directories.