loader

package
v0.2.0-beta.4 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrResolveRevisit

type ErrResolveRevisit struct {
	Profile   string
	TargetURI string
	Date      string
}

func (ErrResolveRevisit) Error

func (e ErrResolveRevisit) Error() string

func (ErrResolveRevisit) String

func (e ErrResolveRevisit) String() string

type FilePathResolver

type FilePathResolver interface {
	ResolvePath(filename string) (path string, err error)
}

type FileStorageLoader

type FileStorageLoader struct {
	FilePathResolver
}

func (FileStorageLoader) Load

func (f FileStorageLoader) Load(ctx context.Context, storageRef string) (record gowarc.WarcRecord, err error)

type Loader

type Loader struct {
	StorageRefResolver
	RecordLoader
	NoUnpack bool
}

func (*Loader) LoadById

func (l *Loader) LoadById(ctx context.Context, warcId string) (gowarc.WarcRecord, error)

func (*Loader) LoadByStorageRef

func (l *Loader) LoadByStorageRef(ctx context.Context, storageRef string) (gowarc.WarcRecord, error)

type RecordLoader

type RecordLoader interface {
	Load(ctx context.Context, storageRef string) (wr gowarc.WarcRecord, err error)
}

type StorageRefResolver

type StorageRefResolver interface {
	Resolve(ctx context.Context, warcId string) (storageRef string, err error)
}

type WarcLoader

type WarcLoader interface {
	LoadById(context.Context, string) (gowarc.WarcRecord, error)
	LoadByStorageRef(context.Context, string) (gowarc.WarcRecord, error)
}

Jump to

Keyboard shortcuts

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