receipt

package
v0.9.19 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2024 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoCollection

type MongoCollection interface {
	Insert(...interface{}) error
	Create(info *mgo.CollectionInfo) error
	EnsureIndex(index mgo.Index) error
	Find(query interface{}) MongoQuery
}

MongoCollection is the subset of mgo that we use, allowing stubbing

type MongoDatabase

type MongoDatabase interface {
	Connect(url string, timeout time.Duration) error
	GetCollection(database string, collection string) MongoCollection
}

MongoDatabase is a subset of mgo that we use, allowing stubbing.

type MongoQuery

type MongoQuery interface {
	Limit(n int) *mgo.Query
	Skip(n int) *mgo.Query
	Sort(fields ...string) *mgo.Query
	All(result interface{}) error
	One(result interface{}) error
}

MongoQuery is the subset of mgo that we use, allowing stubbing

type Store added in v0.9.18

type Store interface {
	Init(ws.WebSocketChannels, ...api.ReceiptStorePersistence) error
	ValidateConf() error
	ProcessReceipt(msgBytes []byte)
	GetReceipts(res http.ResponseWriter, req *http.Request, params httprouter.Params)
	GetReceipt(res http.ResponseWriter, req *http.Request, params httprouter.Params)
	Close()
}

func NewReceiptStore

func NewReceiptStore(config *conf.RESTGatewayConf) Store

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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