mongodb

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2015 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoDB

type MongoDB struct {
	Naive *naive.Naive

	Session *mgo.Session
	DB      *mgo.Database
	// contains filtered or unexported fields
}

type that implements interface HistoryStorage

func New

func New(dirPath string) *MongoDB

func (*MongoDB) Close

func (this *MongoDB) Close()

func (*MongoDB) CreateNewWorkingDir

func (this *MongoDB) CreateNewWorkingDir() string

func (*MongoDB) CreateStorage

func (this *MongoDB) CreateStorage()

func (*MongoDB) GetRequiredTime

func (this *MongoDB) GetRequiredTime(id int) (time.Duration, error)

func (*MongoDB) GetStoredHistory

func (this *MongoDB) GetStoredHistory(id int) (*SingleTrace, error)

func (*MongoDB) Init

func (this *MongoDB) Init()

func (*MongoDB) IsSuccessful added in v0.1.2

func (this *MongoDB) IsSuccessful(id int) (bool, error)

func (*MongoDB) Name

func (this *MongoDB) Name() string

func (*MongoDB) NrStoredHistories

func (this *MongoDB) NrStoredHistories() int

func (*MongoDB) RecordNewTrace

func (this *MongoDB) RecordNewTrace(newTrace *SingleTrace)

func (*MongoDB) RecordResult

func (this *MongoDB) RecordResult(successful bool, requiredTime time.Duration) error

func (*MongoDB) Search

func (this *MongoDB) Search(prefix []Event) []int

func (*MongoDB) SearchWithConverter

func (this *MongoDB) SearchWithConverter(prefix []Event, converter func(events []Event) []Event) []int

Jump to

Keyboard shortcuts

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