dal

package
v0.0.0-...-ac06f80 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder interface {
	Build() (Operator, error)
}

Builder defines the Build function which is used to initialize an operator

type Metadata

type Metadata struct {
	Size int
}

type Operator

type Operator interface {
	// Read data into a byte array from a path
	Read(path string, p []byte) (n int, err error)
	// Write data from a byte array to a path
	Write(path string, p []byte) (n int, err error)
	// Stat return information about a file at the given path
	Stat(path string) (meta *Metadata, err error)
}

Operator provides a unified interface for reading and writing data from various backends

func NewOperator

func NewOperator(builder Builder) (Operator, error)

NewOperator given a builder, returns an intialized Operator

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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