dstore

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package dstore contains implementations for different DStores used in Hoard

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

Types

type FlatPersistedDStore

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

func (FlatPersistedDStore) Store

func (d FlatPersistedDStore) Store(file storage.DFile, content io.Reader) error

type InMemoryDStore

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

func NewInMemoryDStore

func NewInMemoryDStore() *InMemoryDStore

func (*InMemoryDStore) Count

func (dstore *InMemoryDStore) Count() int

func (*InMemoryDStore) Delete

func (dstore *InMemoryDStore) Delete(storage.DFile) error

func (*InMemoryDStore) Get

func (dstore *InMemoryDStore) Get(dFile storage.DFile) (io.ReadCloser, error)

func (*InMemoryDStore) ListInHour

func (dstore *InMemoryDStore) ListInHour(hr hour.Hour) ([]storage.DFile, error)

func (*InMemoryDStore) ListNonEmptyHours

func (dstore *InMemoryDStore) ListNonEmptyHours() ([]hour.Hour, error)

func (*InMemoryDStore) Store

func (dstore *InMemoryDStore) Store(file storage.DFile, content io.Reader) error

type PersistedDStore

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

func (PersistedDStore) Delete

func (d PersistedDStore) Delete(file storage.DFile) error

func (PersistedDStore) Get

func (PersistedDStore) ListInHour

func (d PersistedDStore) ListInHour(hour hour.Hour) ([]storage.DFile, error)

func (PersistedDStore) ListNonEmptyHours

func (d PersistedDStore) ListNonEmptyHours() ([]hour.Hour, error)

func (PersistedDStore) Store

func (d PersistedDStore) Store(file storage.DFile, content io.Reader) error

Jump to

Keyboard shortcuts

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