query

package
v0.0.0-...-a42f9aa Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2017 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package query defines methods for retrieving values from a data file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Comparison

type Comparison int

Plan defines the most efficient lookups for retrieving an item from BoltDB.

type Plan

type Plan struct {
	ItemBucket []byte
	ItemKey    []byte
	Indexes    []UseIndex
}

Plan defines the most efficient lookups for retrieving an item from BoltDB.

func Bucket

func Bucket(name []byte) *Plan

func (*Plan) UseIndex

func (b *Plan) UseIndex(name, key []byte)

type Query

type Query struct {
	Item        interface{}
	Comparisons []*comparison
}

func (*Query) Field

func (q *Query) Field(name string) *comparison

func (*Query) First

func (q *Query) First() interface{}

type UseIndex

type UseIndex struct {
	IndexBucket []byte
	IndexKey    []byte
}

Plan defines the most efficient lookups for retrieving an item from BoltDB.

Jump to

Keyboard shortcuts

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