entities

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2025 License: Apache-2.0 Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	MediaMp3 = feedcast.Mp3
	MediaM4a = feedcast.M4a
)
View Source
const (
	FeedTypeNotSet   = feedcast.TypeNotSet
	FeedTypeEpisodic = feedcast.TypeEpisodic
	FeedTypeSerial   = feedcast.TypeSerial
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DownloadFormat

type DownloadFormat string

DownloadFormat is the format in which media should be downloaded.

const (
	DownloadMp3 DownloadFormat = "mp3"
	DownloadM4a DownloadFormat = "m4a"
)

type Episode

type Episode struct {
	ID            int64
	Title         string
	Description   string
	ThumbnailFile string
	MediaFile     string
	MediaType     MediaType
	MediaDuration int64
	MediaSize     int64
	Author        string
	OriginalURL   string
	CanonicalURL  string
	CreatedAt     time.Time
}

Episode represents a podcast episode.

func (*Episode) LogValue

func (p *Episode) LogValue() slog.Value

LogValue implements slog.LogValuer interface for automatic logging

type Feed added in v0.1.0

type Feed struct {
	Title         string         // Show title
	Description   string         // Show description
	Summary       string         // Show summary
	Language      string         // Lang code
	Categories    []FeedCategory // Podcast categories
	Keywords      string         // Podcast keywords comma separated
	Author        string         // Podcast author name
	Owner         *FeedOwner     // Podcast owner info
	Copyright     string         // Show copyright info if any
	Explicit      bool           // Is the show explicit
	FeedType      FeedType       // The type of the show
	FeedCompleted bool           // Is the show completed
	FeedBlocked   bool           // Is the show blocked in Apple Podcasts
	WebsiteLink   string         // Website link
	RSSLink       string         // RSS feed link
	ImageUrl      string         // Cover image link
	Generator     string         // Feed generator software
	PubDate       time.Time      // Last published date. Zero time if no episodes
	EpisodeCount  int            // Number of episodes in the feed
}

Feed contains information about podcast feed

type FeedCategory added in v0.1.0

type FeedCategory = feedcast.Category

FeedCategory contains information about podcast category

type FeedOwner added in v0.1.0

type FeedOwner struct {
	Name  string // Owner name
	Email string // Owner email
}

FeedOwner contains information about podcast owner

type FeedType added in v0.1.0

type FeedType = feedcast.ItunesType

FeedType represents the type of show. If your show is Serial you must use this tag. See feedcast.ItunesType for possible values.

type MediaType

type MediaType = feedcast.EnclosureType

MediaType is the MIME type of the media file.

type Process

type Process struct {
	ID        int64
	Request   Request
	Step      Step
	Status    Status
	Error     error
	Episode   *Episode
	CreatedAt time.Time
	UpdatedAt time.Time
}

Process represents a media processing task.

func (*Process) LogValue

func (p *Process) LogValue() slog.Value

LogValue implements slog.LogValuer interface for automatic logging

type Request

type Request struct {
	ID              string
	UserID          int64
	ChatID          int64
	MessageID       int
	Url             string
	DownloadFormat  DownloadFormat
	DownloadQuality string
	Force           bool
}

Request represents a download request.

func (*Request) LogValue

func (p *Request) LogValue() slog.Value

LogValue implements slog.LogValuer interface for automatic logging

type Status

type Status string

Status is the current status of the processing task.

const (
	StatusInProgress Status = "in_progress"
	StatusSuccess    Status = "success"
	StatusFailed     Status = "failed"
)

type Step

type Step string

Step is the current step of the processing task.

const (
	StepCreating    Step = "creating"
	StepDownloading Step = "downloading"
	StepPublishing  Step = "publishing"
)

Jump to

Keyboard shortcuts

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