record

package
v0.0.0-...-8a90fd1 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2023 License: MIT Imports: 31 Imported by: 0

Documentation

Overview

Package record contains the recording system.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Agent

type Agent struct {
	WriteQueueSize    int
	PathFormat        string
	Format            conf.RecordFormat
	PartDuration      time.Duration
	SegmentDuration   time.Duration
	PathName          string
	Stream            *stream.Stream
	OnSegmentCreate   OnSegmentFunc
	OnSegmentComplete OnSegmentFunc
	Parent            logger.Writer
	// contains filtered or unexported fields
}

Agent writes recordings to disk.

func (*Agent) Close

func (w *Agent) Close()

Close closes the agent.

func (*Agent) Initialize

func (w *Agent) Initialize()

Initialize initializes Agent.

func (*Agent) Log

func (w *Agent) Log(level logger.Level, format string, args ...interface{})

Log is the main logging function.

type Cleaner

type Cleaner struct {
	Entries []CleanerEntry
	Parent  logger.Writer
	// contains filtered or unexported fields
}

Cleaner removes expired recording segments from disk.

func (*Cleaner) Close

func (c *Cleaner) Close()

Close closes the Cleaner.

func (*Cleaner) Initialize

func (c *Cleaner) Initialize()

Initialize initializes a Cleaner.

func (*Cleaner) Log

func (c *Cleaner) Log(level logger.Level, format string, args ...interface{})

Log is the main logging function.

type CleanerEntry

type CleanerEntry struct {
	PathFormat  string
	Format      conf.RecordFormat
	DeleteAfter time.Duration
}

CleanerEntry is a cleaner entry.

type OnSegmentFunc

type OnSegmentFunc = func(string)

OnSegmentFunc is the prototype of the function passed as runOnSegmentStart / runOnSegmentComplete

Jump to

Keyboard shortcuts

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