storage

package module
v0.0.0-...-9372f3a Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2018 License: Apache-2.0 Imports: 1 Imported by: 2

README

storage

Documentation

Overview

Package storage contains common interfaces and implementation for all supported storage implementations.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Storage

type Storage interface {
	// SaveUnit saves given unit to the storage.
	SaveUnit(u unit.Unit) error

	// RemoveUnit removes given unit from the storage.
	RemoveUnit(u unit.Unit) error

	// LoadUnit loads unit with given id from the storage
	LoadUnit(id string) (unit.Unit, error)

	// IsCreated checks whether storage was already created or not
	IsCreated() bool

	// Create creates storage
	Create() error

	// Remove removes storage
	Remove() error
}

Storage represents some storage which can be used to store units

Jump to

Keyboard shortcuts

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