epgstation

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2021 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Connected <-chan struct{} = connected

	StatusUpdated <-chan struct{} = statusUpdated

	EncodeUpdated <-chan struct{} = encodeUpdated
)

Functions

func FinishRunning

func FinishRunning(without []int) ([]db.Recording, error)

func NewRecording

func NewRecording(record Record, channel *db.Channel) (*db.Recording, error)

func RecordingExists

func RecordingExists(epgstationRecordingID int) (bool, error)

func Streaming

func Streaming(ctx context.Context, host string, port int, secure bool)

func UpdateChannel added in v0.2.0

func UpdateChannel(channel *Channel) (*db.Channel, error)

Types

type Channel added in v0.2.0

type Channel struct {
	ID                 int    `json:"id"`
	Name               string `json:"halfWidthName"`
	HasLogoData        bool   `json:"hasLogoData"`
	RemoteControlKeyID int    `json:"remoteControlKeyId"`
}

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(url string) *Client

func (*Client) GetChannel added in v0.2.0

func (client *Client) GetChannel(ctx context.Context, ID int) (*Channel, error)

func (*Client) GetRecording

func (client *Client) GetRecording(ctx context.Context) (*Records, error)

type EPGStationChannel added in v0.2.0

type EPGStationChannel struct {
	EPGStationID int `gorm:"column:epgstation_id;primaryKey"`
	ChannelID    int
	HasLogoData  bool
}

func (EPGStationChannel) TableName added in v0.2.0

func (EPGStationChannel) TableName() string

type EPGStationRecording

type EPGStationRecording struct {
	EPGStationID int `gorm:"column:epgstation_id;primaryKey"`
	RecordingID  int
	Recording    db.Recording
}

func (EPGStationRecording) TableName

func (EPGStationRecording) TableName() string

type Record

type Record struct {
	ID        int    `json:"id"`
	ChannelID int    `json:"channelId"`
	Name      string `json:"name"`
	StartedAt Time   `json:"startAt"`
	EndsAt    Time   `json:"endAt"`
}

type Records

type Records struct {
	Total   int      `json:"total"`
	Records []Record `json:"records"`
}

type Time

type Time time.Time

func (*Time) UnmarshalJSON

func (t *Time) UnmarshalJSON(b []byte) error

Jump to

Keyboard shortcuts

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