Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExpiringValue ¶
ExpiringValue is holds the value and expiration time.
type ExpiringValues ¶
type ExpiringValues []*ExpiringValue
ExpiringValues expiring values
func (ExpiringValues) Values ¶
func (ev ExpiringValues) Values() common.Values
Values returns the ExpiringValues as Values
type Key ¶
Key is a key for retrieving collection data
type MultiKey ¶
MultiKey is a key for retrieving collection data for multiple keys
func NewMultiKey ¶
NewMultiKey returns a new collection data multi-key
type QueryKey ¶
QueryKey holds the criteria for retrieving collection data in rich queries
func NewQueryKey ¶
NewQueryKey returns a new collection data query-key
type QueryResult ¶
type QueryResult struct { *Key *ExpiringValue }
QueryResult holds a single item from the query result set
type ResultsIterator ¶
type ResultsIterator interface { // Next returns the next item in the result set. The result is expected to be nil when // the iterator gets exhausted Next() (*QueryResult, error) // Close releases resources occupied by the iterator Close() }
ResultsIterator is an iterator returned by a query
type Retriever ¶
type Retriever interface { // GetTransientData gets the value for the given transient data item GetTransientData(ctxt context.Context, key *Key) (*ExpiringValue, error) // GetTransientDataMultipleKeys gets the values for the multiple transient data items in a single call GetTransientDataMultipleKeys(ctxt context.Context, key *MultiKey) (ExpiringValues, error) // GetData gets the value for the given data item GetData(ctxt context.Context, key *Key) (*ExpiringValue, error) // GetDataMultipleKeys gets the values for the multiple data items in a single call GetDataMultipleKeys(ctxt context.Context, key *MultiKey) (ExpiringValues, error) // Query returns the results of the given query Query(ctxt context.Context, key *QueryKey) (ResultsIterator, error) }
Retriever retrieves private data
type Store ¶
type Store interface { // Persist stores the private write set of a transaction. Persist(txid string, privateSimulationResultsWithConfig *proto.TxPvtReadWriteSetWithConfigInfo) error // GetTransientData gets the value for the given transient data item GetTransientData(key *Key) (*ExpiringValue, error) // GetTransientDataMultipleKeys gets the values for the multiple transient data items in a single call GetTransientDataMultipleKeys(key *MultiKey) (ExpiringValues, error) // GetData gets the value for the given item GetData(key *Key) (*ExpiringValue, error) // GetDataMultipleKeys gets the values for the multiple items in a single call GetDataMultipleKeys(key *MultiKey) (ExpiringValues, error) // Query executes the given query // NOTE: This function is only supported on CouchDB Query(key *QueryKey) (ResultsIterator, error) // PutData stores the key/value. PutData(config *pb.StaticCollectionConfig, key *Key, value *ExpiringValue) error // Close closes the store Close() }
Store manages the storage of private data collections.
Click to show internal directories.
Click to hide internal directories.