store

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DiskStore

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

DiskStore is a cache on-disk

func New

func New(path string) (*DiskStore, error)

New returns a new DiskStore

func NewTemp

func NewTemp() (*DiskStore, error)

NewTemp returns a new DiskStore

func (*DiskStore) Get

func (d *DiskStore) Get(project, name string) (*crdv1.RobotAccountCredential, error)

Get returns a item

func (*DiskStore) Has

func (d *DiskStore) Has(project, name string) bool

Has returns true if the item exists, false if not

func (*DiskStore) Keys

func (d *DiskStore) Keys() [][]string

Keys returns all available keys

func (*DiskStore) Reset

func (d *DiskStore) Reset() error

Reset deletes all entries from the cache

func (*DiskStore) Set

func (d *DiskStore) Set(project string, cred crdv1.RobotAccountCredential) error

Set writes data to the disk store

Jump to

Keyboard shortcuts

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