metadata

package
v0.2.25 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ImageFormat          = "format"
	ImageWidth           = "width"
	ImageHeight          = "height"
	ImageTitle           = "title"
	ImageSummary         = "summary"
	ImageTags            = "tags"
	ImageOrientation     = "orientation"
	ImageMake            = "make"
	ImageModel           = "model"
	ImageLensModel       = "lens"
	ImageGPSLatitude     = "gps-latitude"
	ImageGPSLongitude    = "gps-longitude"
	ImageGPSAltitude     = "gps-altitude"
	ImageAperture        = "aperture"
	ImageShutterSpeed    = "shutter-speed"
	TextTitle            = "title"
	TextAuthor           = "author"
	TextSummary          = "summary"
	TextLanguage         = "language"
	TextLines            = "lines"
	TextTags             = "tags"
	PDFTitle             = "title"
	PDFAuthor            = "author"
	PDFSubject           = "subject"
	PDFCreator           = "creator"
	PDFProducer          = "producer"
	PDFPages             = "pages"
	VideoDurationSecs    = "duration-secs"
	VideoDuration        = "duration"
	VideoDescription     = "description"
	VideoSynopsis        = "synopsis"
	VideoTitle           = "title"
	VideoDirector        = "director"
	VideoYear            = "year"
	AudioDurationSecs    = "duration-secs"
	AudioDuration        = "duration"
	AudioTitle           = "title"
	AudioArtist          = "artist"
	AudioAlbum           = "album"
	AudioGenre           = "genre"
	AudioYear            = "year"
	AudioTrack           = "track"
	DateCreated          = "created"
	DateModified         = "modified"
	CalendarTitle        = "title"
	CalendarEventCount   = "event-count"
	CalendarStart        = "start"
	CalendarEnd          = "end"
	CalendarDurationSecs = "duration-secs"
	CalendarDuration     = "duration"
	CalendarOrganizer    = "organizer"
	CalendarLocation     = "location"
	CalendarCategories   = "tags"
	CalendarDescription  = "description"
	CalendarURL          = "url"
	CalendarRecurrence   = "recurrence"
)

Variables

This section is empty.

Functions

func RegisterExtractor

func RegisterExtractor(e Extractor)

Types

type Extractor

type Extractor interface {
	// Return the media type
	MediaType() *regexp.Regexp

	// Extract metadata and artwork (thumbnails) from the file at the given path
	ExtractMetadata(ctx context.Context, r io.ReadSeeker) ([]schema.Meta, []*schema.ArtworkMeta, error)
}

func Get

func Get(mimeType string) (Extractor, error)

Return metadata for a *schema.Object in a specific backend

type FileReader added in v0.2.3

type FileReader interface {
	io.Reader
	Name() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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