editor

package
v0.0.0-...-1794af1 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2016 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cover

type Cover struct {
	Mime        string
	Type        string
	Description string
	Data        []byte
}

func (Cover) Empty

func (cover Cover) Empty() bool

func (Cover) Size

func (cover Cover) Size() int

func (Cover) String

func (cover Cover) String() string

type Editor

type Editor interface {
	ReadTag(path string) (Tag, error)
	WriteTag(src, dst string, tag Tag) error
}

func NewEditor

func NewEditor(editorType EditorType) Editor

type EditorType

type EditorType int
const (
	Mp3 EditorType = iota
	Ogg
	Flac
)

type FlacTagEditor

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

func (*FlacTagEditor) ReadTag

func (editor *FlacTagEditor) ReadTag(path string) (Tag, error)

func (*FlacTagEditor) WriteTag

func (editor *FlacTagEditor) WriteTag(src, dst string, tag Tag) error

type Mp3TagEditor

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

func (*Mp3TagEditor) ReadTag

func (editor *Mp3TagEditor) ReadTag(path string) (Tag, error)

func (*Mp3TagEditor) WriteTag

func (editor *Mp3TagEditor) WriteTag(src, dst string, tag Tag) error

type OggTagEditor

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

func (*OggTagEditor) ReadTag

func (editor *OggTagEditor) ReadTag(path string) (Tag, error)

func (*OggTagEditor) WriteTag

func (editor *OggTagEditor) WriteTag(src, dst string, tag Tag) error

type Tag

type Tag struct {
	Title   string
	Artist  string
	Album   string
	Track   int
	Year    int
	Comment string
	Genre   string
	Cover   Cover
}

func (Tag) Empty

func (tag Tag) Empty() bool

func (*Tag) MergeWith

func (tag *Tag) MergeWith(src Tag)

func (Tag) Size

func (tag Tag) Size() int

func (Tag) String

func (tag Tag) String() string

Jump to

Keyboard shortcuts

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