fsapi

package
v0.0.0-...-6217932 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2016 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotFound = errors.New("not found")
	ErrNotDir   = errors.New("not a directory")
)

Functions

This section is empty.

Types

type Attr

type Attr struct {
	Name  string
	IsDir bool
	Song  *api.Song
	Audio *api.AudioFile
}

type ByArtistFilesystem

type ByArtistFilesystem struct {
	DbPrefix string
	// contains filtered or unexported fields
}

ByArtistFilesystem is a Filesystem implementation that exposes an artist/album/song hierarchy (and tries to pick the best-sounding file for each song).

func NewByArtistFilesystem

func NewByArtistFilesystem(db services.Database, index services.Index) *ByArtistFilesystem

func (*ByArtistFilesystem) Ls

func (afs *ByArtistFilesystem) Ls(path string) ([]Attr, error)

func (*ByArtistFilesystem) Stat

func (afs *ByArtistFilesystem) Stat(path string) (Attr, error)

type Filesystem

type Filesystem interface {
	Stat(path string) (Attr, error)
	Ls(path string) ([]Attr, error)
}

Jump to

Keyboard shortcuts

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