backend

package
v0.0.0-...-6eb517c Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2019 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Overview

Package backend handles overall persistence

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CryptStore

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

CryptStore internally holds all persistence state dependencies

func OpenCryptStore

func OpenCryptStore(storeLocation string) (*CryptStore, error)

OpenCryptStore initializes and opens the persistence file

func (*CryptStore) GetStorageContainer

func (cs *CryptStore) GetStorageContainer() (*StorageContainer, error)

GetStorageContainer returns the entire storage container

func (*CryptStore) PersistStorageContainer

func (cs *CryptStore) PersistStorageContainer(s *StorageContainer) error

PersistStorageContainer persists the entire storage container

type CryptStoreInterface

type CryptStoreInterface interface {
	GetStorageContainer() (*StorageContainer, error)
	PersistStorageContainer(s *StorageContainer) error
}

CryptStoreInterface defines the persistence interface exposed to other packages

type StorageContainer

type StorageContainer struct {
	CredentialURLs []string
	LastIndex      uint64
}

StorageContainer is the top-level struct for persistence

Jump to

Keyboard shortcuts

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