storage

package
v0.3.8 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CostDataInsert

type CostDataInsert struct {
	Dimension   string
	Dimension2  string
	Tag         string
	MetricName  string
	Amount      string
	Unit        string
	Granularity string
	StartDate   string
	EndDate     string
}

type CostDataStorage

type CostDataStorage struct {
}

func (*CostDataStorage) CreateFile

func (c *CostDataStorage) CreateFile(dbName string) (int, error)

return 0 if creation was a success, return 1 if file already exists or return -1 if an error occurred

func (*CostDataStorage) Insert

func (c *CostDataStorage) Insert(data CostDataInsert) (int, error)

return error and -1 if insert was not successful, return 0 if insert was successful

func (*CostDataStorage) New

func (c *CostDataStorage) New(dbName string) error

func (*CostDataStorage) Set

func (c *CostDataStorage) Set(s string) error

create a database with named provided as arg

type DBError

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

func (DBError) Error

func (e DBError) Error() string

type Persistent

type Persistent interface {
	NewPersistentStorage()
	CreateCostDataTable()
	InsertCustomer()
}

Jump to

Keyboard shortcuts

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