recorder

package
v0.0.0-...-bace9cc Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AlreadyRunning errors.Kind = iota + 5100
	AlreadyEnded
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Chrome

type Chrome struct {
	URL     string   `json:"url"`
	Options []string `json:"options"`
}

type FFmpeg

type FFmpeg struct {
	Params  [][]string `json:"params"`
	Options [][]string `json:"options"`
}

type Middleware

type Middleware func(Service) Service

func LoggingMiddleware

func LoggingMiddleware(l log.Logger) Middleware

type Recorder

type Recorder struct {
	FFmpegCmd Runnable
	ChromeCmd Runnable
	// contains filtered or unexported fields
}

type Runnable

type Runnable interface {
	Start() error
	Stop() error
	Restart() error
}

type Service

func NewService

func NewService(l log.Logger) Service

func ValidationMiddleware

func ValidationMiddleware(svc Service) Service

type StartRecordingRequest

type StartRecordingRequest struct {
	FFmpeg      `json:"ffmpeg"`
	Chrome      `json:"chrome"`
	Destination string `json:"destination"`
	DRMKeyPath  string `json:"drmKeyPath"`
	URL         string `json:"url"`
}

StartRecordingRequest is the payload being received by recorder as part of start_recording

type StartRecordingResponse

type StartRecordingResponse struct {
	StartTime time.Time `json:"start_time"`
	// contains filtered or unexported fields
}

StartRecordingResponse defines response structure for the stop recording request

func (StartRecordingResponse) Failed

func (e StartRecordingResponse) Failed() error

type StopRecordingRequest

type StopRecordingRequest struct{}

type StopRecordingResponse

type StopRecordingResponse struct {
	StopTime time.Time `json:"stop_time"`
	// contains filtered or unexported fields
}

StopRecordingResponse is the response for the stop recording recording request

func (StopRecordingResponse) Failed

func (e StopRecordingResponse) Failed() error

Jump to

Keyboard shortcuts

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