segment

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2021 License: Apache-2.0 Imports: 7 Imported by: 24

Documentation

Overview

Package segment is a generated GoMock package.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrClosed is the error returned when attempting to perform operations on a
	// segment that has already been closed.
	ErrClosed = errors.New("segment has been closed")
)

Functions

This section is empty.

Types

type Builder added in v0.5.0

type Builder interface {
	FieldsPostingsListIterable
	TermsIterable

	// Reset resets the builder for reuse.
	Reset()

	// Docs returns the current docs slice, this is not safe to modify
	// and is invalidated on a call to reset.
	Docs() []doc.Metadata

	// AllDocs returns an iterator over the documents known to the Reader.
	AllDocs() (index.IDDocIterator, error)
}

Builder is a builder that can be used to construct segments.

type CloseableDocumentsBuilder added in v0.15.0

type CloseableDocumentsBuilder interface {
	DocumentsBuilder

	Close() error
}

CloseableDocumentsBuilder is a builder that has documents written to it and has freeable resources.

type DocumentsBuilder added in v0.5.0

type DocumentsBuilder interface {
	Builder
	index.Writer

	// SetIndexConcurrency sets the concurrency used for building the segment.
	SetIndexConcurrency(value int)

	// IndexConcurrency returns the concurrency used for building the segment.
	IndexConcurrency() int
}

DocumentsBuilder is a builder that has documents written to it.

type DocumentsFilter added in v1.2.0

type DocumentsFilter interface {
	Contains(d doc.Metadata) bool
}

DocumentsFilter is a documents filter.

type DocumentsFilterFn added in v1.2.0

type DocumentsFilterFn func(d doc.Metadata) bool

DocumentsFilterFn implements DocumentsFilter.

func (DocumentsFilterFn) Contains added in v1.2.0

func (f DocumentsFilterFn) Contains(d doc.Metadata) bool

Contains implements the DocumentsFilter interface.

type FieldsIterable added in v0.5.0

type FieldsIterable interface {
	// Fields returns an iterator over the list of known fields, in order
	// by name, it is not valid for reading after mutating the
	// builder by inserting more documents.
	Fields() (FieldsIterator, error)
}

FieldsIterable can iterate over segment fields, it is not by default concurrency safe.

type FieldsIterator added in v0.4.1

type FieldsIterator interface {
	Iterator

	// Current returns the current field.
	// NB: the field returned is only valid until the subsequent call to Next().
	Current() []byte
}

FieldsIterator iterates over all known fields.

type FieldsPostingsListIterable added in v0.15.0

type FieldsPostingsListIterable interface {
	// Fields returns an iterator over the list of known fields, in order
	// by name, it is not valid for reading after mutating the
	// builder by inserting more documents.
	FieldsPostingsList() (FieldsPostingsListIterator, error)
}

FieldsPostingsListIterable can iterate over segment fields/postings lists, it is not by default concurrency safe.

type FieldsPostingsListIterator added in v0.15.0

type FieldsPostingsListIterator interface {
	Iterator

	// Current returns the current field and associated postings list.
	// NB: the field returned is only valid until the subsequent call to Next().
	Current() ([]byte, postings.List)
}

FieldsPostingsListIterator iterates over all known fields.

type ImmutableSegment added in v0.15.0

type ImmutableSegment interface {
	Segment

	FreeMmap() error
}

ImmutableSegment is segment that has been written to disk.

type Iterator added in v0.15.0

type Iterator interface {
	// Next returns a bool indicating if there are any more elements.
	Next() bool

	// Err returns any errors encountered during iteration.
	Err() error

	// Close releases any resources held by the iterator.
	Close() error
}

Iterator holds common iterator methods.

type MockBuilder added in v0.5.0

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

MockBuilder is a mock of Builder interface.

func NewMockBuilder added in v0.5.0

func NewMockBuilder(ctrl *gomock.Controller) *MockBuilder

NewMockBuilder creates a new mock instance.

func (*MockBuilder) AllDocs added in v0.5.0

func (m *MockBuilder) AllDocs() (index.IDDocIterator, error)

AllDocs mocks base method.

func (*MockBuilder) Docs added in v0.5.0

func (m *MockBuilder) Docs() []doc.Metadata

Docs mocks base method.

func (*MockBuilder) EXPECT added in v0.5.0

func (m *MockBuilder) EXPECT() *MockBuilderMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockBuilder) FieldsPostingsList added in v0.15.0

func (m *MockBuilder) FieldsPostingsList() (FieldsPostingsListIterator, error)

FieldsPostingsList mocks base method.

func (*MockBuilder) Reset added in v0.5.0

func (m *MockBuilder) Reset()

Reset mocks base method.

func (*MockBuilder) Terms added in v0.5.0

func (m *MockBuilder) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

type MockBuilderMockRecorder added in v0.5.0

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

MockBuilderMockRecorder is the mock recorder for MockBuilder.

func (*MockBuilderMockRecorder) AllDocs added in v0.5.0

func (mr *MockBuilderMockRecorder) AllDocs() *gomock.Call

AllDocs indicates an expected call of AllDocs.

func (*MockBuilderMockRecorder) Docs added in v0.5.0

func (mr *MockBuilderMockRecorder) Docs() *gomock.Call

Docs indicates an expected call of Docs.

func (*MockBuilderMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockBuilderMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockBuilderMockRecorder) Reset added in v0.5.0

func (mr *MockBuilderMockRecorder) Reset() *gomock.Call

Reset indicates an expected call of Reset.

func (*MockBuilderMockRecorder) Terms added in v0.5.0

func (mr *MockBuilderMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockCloseableDocumentsBuilder added in v0.15.0

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

MockCloseableDocumentsBuilder is a mock of CloseableDocumentsBuilder interface.

func NewMockCloseableDocumentsBuilder added in v0.15.0

func NewMockCloseableDocumentsBuilder(ctrl *gomock.Controller) *MockCloseableDocumentsBuilder

NewMockCloseableDocumentsBuilder creates a new mock instance.

func (*MockCloseableDocumentsBuilder) AllDocs added in v0.15.0

AllDocs mocks base method.

func (*MockCloseableDocumentsBuilder) Close added in v0.15.0

Close mocks base method.

func (*MockCloseableDocumentsBuilder) Docs added in v0.15.0

Docs mocks base method.

func (*MockCloseableDocumentsBuilder) EXPECT added in v0.15.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockCloseableDocumentsBuilder) FieldsPostingsList added in v0.15.0

FieldsPostingsList mocks base method.

func (*MockCloseableDocumentsBuilder) IndexConcurrency added in v0.15.6

func (m *MockCloseableDocumentsBuilder) IndexConcurrency() int

IndexConcurrency mocks base method.

func (*MockCloseableDocumentsBuilder) Insert added in v0.15.0

Insert mocks base method.

func (*MockCloseableDocumentsBuilder) InsertBatch added in v0.15.0

func (m *MockCloseableDocumentsBuilder) InsertBatch(b index.Batch) error

InsertBatch mocks base method.

func (*MockCloseableDocumentsBuilder) Reset added in v0.15.0

func (m *MockCloseableDocumentsBuilder) Reset()

Reset mocks base method.

func (*MockCloseableDocumentsBuilder) SetIndexConcurrency added in v0.15.6

func (m *MockCloseableDocumentsBuilder) SetIndexConcurrency(value int)

SetIndexConcurrency mocks base method.

func (*MockCloseableDocumentsBuilder) Terms added in v0.15.0

Terms mocks base method.

type MockCloseableDocumentsBuilderMockRecorder added in v0.15.0

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

MockCloseableDocumentsBuilderMockRecorder is the mock recorder for MockCloseableDocumentsBuilder.

func (*MockCloseableDocumentsBuilderMockRecorder) AllDocs added in v0.15.0

AllDocs indicates an expected call of AllDocs.

func (*MockCloseableDocumentsBuilderMockRecorder) Close added in v0.15.0

Close indicates an expected call of Close.

func (*MockCloseableDocumentsBuilderMockRecorder) Docs added in v0.15.0

Docs indicates an expected call of Docs.

func (*MockCloseableDocumentsBuilderMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockCloseableDocumentsBuilderMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockCloseableDocumentsBuilderMockRecorder) IndexConcurrency added in v0.15.6

func (mr *MockCloseableDocumentsBuilderMockRecorder) IndexConcurrency() *gomock.Call

IndexConcurrency indicates an expected call of IndexConcurrency.

func (*MockCloseableDocumentsBuilderMockRecorder) Insert added in v0.15.0

func (mr *MockCloseableDocumentsBuilderMockRecorder) Insert(d interface{}) *gomock.Call

Insert indicates an expected call of Insert.

func (*MockCloseableDocumentsBuilderMockRecorder) InsertBatch added in v0.15.0

func (mr *MockCloseableDocumentsBuilderMockRecorder) InsertBatch(b interface{}) *gomock.Call

InsertBatch indicates an expected call of InsertBatch.

func (*MockCloseableDocumentsBuilderMockRecorder) Reset added in v0.15.0

Reset indicates an expected call of Reset.

func (*MockCloseableDocumentsBuilderMockRecorder) SetIndexConcurrency added in v0.15.6

func (mr *MockCloseableDocumentsBuilderMockRecorder) SetIndexConcurrency(value interface{}) *gomock.Call

SetIndexConcurrency indicates an expected call of SetIndexConcurrency.

func (*MockCloseableDocumentsBuilderMockRecorder) Terms added in v0.15.0

func (mr *MockCloseableDocumentsBuilderMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockDocumentsBuilder added in v0.9.0

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

MockDocumentsBuilder is a mock of DocumentsBuilder interface.

func NewMockDocumentsBuilder added in v0.9.0

func NewMockDocumentsBuilder(ctrl *gomock.Controller) *MockDocumentsBuilder

NewMockDocumentsBuilder creates a new mock instance.

func (*MockDocumentsBuilder) AllDocs added in v0.9.0

AllDocs mocks base method.

func (*MockDocumentsBuilder) Docs added in v0.9.0

func (m *MockDocumentsBuilder) Docs() []doc.Metadata

Docs mocks base method.

func (*MockDocumentsBuilder) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockDocumentsBuilder) FieldsPostingsList added in v0.15.0

func (m *MockDocumentsBuilder) FieldsPostingsList() (FieldsPostingsListIterator, error)

FieldsPostingsList mocks base method.

func (*MockDocumentsBuilder) IndexConcurrency added in v0.15.6

func (m *MockDocumentsBuilder) IndexConcurrency() int

IndexConcurrency mocks base method.

func (*MockDocumentsBuilder) Insert added in v0.9.0

func (m *MockDocumentsBuilder) Insert(d doc.Metadata) ([]byte, error)

Insert mocks base method.

func (*MockDocumentsBuilder) InsertBatch added in v0.9.0

func (m *MockDocumentsBuilder) InsertBatch(b index.Batch) error

InsertBatch mocks base method.

func (*MockDocumentsBuilder) Reset added in v0.9.0

func (m *MockDocumentsBuilder) Reset()

Reset mocks base method.

func (*MockDocumentsBuilder) SetIndexConcurrency added in v0.15.6

func (m *MockDocumentsBuilder) SetIndexConcurrency(value int)

SetIndexConcurrency mocks base method.

func (*MockDocumentsBuilder) Terms added in v0.9.0

func (m *MockDocumentsBuilder) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

type MockDocumentsBuilderMockRecorder added in v0.9.0

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

MockDocumentsBuilderMockRecorder is the mock recorder for MockDocumentsBuilder.

func (*MockDocumentsBuilderMockRecorder) AllDocs added in v0.9.0

AllDocs indicates an expected call of AllDocs.

func (*MockDocumentsBuilderMockRecorder) Docs added in v0.9.0

Docs indicates an expected call of Docs.

func (*MockDocumentsBuilderMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockDocumentsBuilderMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockDocumentsBuilderMockRecorder) IndexConcurrency added in v0.15.6

func (mr *MockDocumentsBuilderMockRecorder) IndexConcurrency() *gomock.Call

IndexConcurrency indicates an expected call of IndexConcurrency.

func (*MockDocumentsBuilderMockRecorder) Insert added in v0.9.0

func (mr *MockDocumentsBuilderMockRecorder) Insert(d interface{}) *gomock.Call

Insert indicates an expected call of Insert.

func (*MockDocumentsBuilderMockRecorder) InsertBatch added in v0.9.0

func (mr *MockDocumentsBuilderMockRecorder) InsertBatch(b interface{}) *gomock.Call

InsertBatch indicates an expected call of InsertBatch.

func (*MockDocumentsBuilderMockRecorder) Reset added in v0.9.0

Reset indicates an expected call of Reset.

func (*MockDocumentsBuilderMockRecorder) SetIndexConcurrency added in v0.15.6

func (mr *MockDocumentsBuilderMockRecorder) SetIndexConcurrency(value interface{}) *gomock.Call

SetIndexConcurrency indicates an expected call of SetIndexConcurrency.

func (*MockDocumentsBuilderMockRecorder) Terms added in v0.9.0

func (mr *MockDocumentsBuilderMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockDocumentsFilter added in v1.2.0

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

MockDocumentsFilter is a mock of DocumentsFilter interface.

func NewMockDocumentsFilter added in v1.2.0

func NewMockDocumentsFilter(ctrl *gomock.Controller) *MockDocumentsFilter

NewMockDocumentsFilter creates a new mock instance.

func (*MockDocumentsFilter) Contains added in v1.2.0

func (m *MockDocumentsFilter) Contains(d doc.Metadata) bool

Contains mocks base method.

func (*MockDocumentsFilter) EXPECT added in v1.2.0

EXPECT returns an object that allows the caller to indicate expected use.

type MockDocumentsFilterMockRecorder added in v1.2.0

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

MockDocumentsFilterMockRecorder is the mock recorder for MockDocumentsFilter.

func (*MockDocumentsFilterMockRecorder) Contains added in v1.2.0

func (mr *MockDocumentsFilterMockRecorder) Contains(d interface{}) *gomock.Call

Contains indicates an expected call of Contains.

type MockFieldsIterable added in v0.9.0

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

MockFieldsIterable is a mock of FieldsIterable interface.

func NewMockFieldsIterable added in v0.9.0

func NewMockFieldsIterable(ctrl *gomock.Controller) *MockFieldsIterable

NewMockFieldsIterable creates a new mock instance.

func (*MockFieldsIterable) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockFieldsIterable) Fields added in v0.9.0

func (m *MockFieldsIterable) Fields() (FieldsIterator, error)

Fields mocks base method.

type MockFieldsIterableMockRecorder added in v0.9.0

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

MockFieldsIterableMockRecorder is the mock recorder for MockFieldsIterable.

func (*MockFieldsIterableMockRecorder) Fields added in v0.9.0

Fields indicates an expected call of Fields.

type MockFieldsIterator added in v0.9.0

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

MockFieldsIterator is a mock of FieldsIterator interface.

func NewMockFieldsIterator added in v0.9.0

func NewMockFieldsIterator(ctrl *gomock.Controller) *MockFieldsIterator

NewMockFieldsIterator creates a new mock instance.

func (*MockFieldsIterator) Close added in v0.9.0

func (m *MockFieldsIterator) Close() error

Close mocks base method.

func (*MockFieldsIterator) Current added in v0.9.0

func (m *MockFieldsIterator) Current() []byte

Current mocks base method.

func (*MockFieldsIterator) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockFieldsIterator) Err added in v0.9.0

func (m *MockFieldsIterator) Err() error

Err mocks base method.

func (*MockFieldsIterator) Next added in v0.9.0

func (m *MockFieldsIterator) Next() bool

Next mocks base method.

type MockFieldsIteratorMockRecorder added in v0.9.0

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

MockFieldsIteratorMockRecorder is the mock recorder for MockFieldsIterator.

func (*MockFieldsIteratorMockRecorder) Close added in v0.9.0

Close indicates an expected call of Close.

func (*MockFieldsIteratorMockRecorder) Current added in v0.9.0

Current indicates an expected call of Current.

func (*MockFieldsIteratorMockRecorder) Err added in v0.9.0

Err indicates an expected call of Err.

func (*MockFieldsIteratorMockRecorder) Next added in v0.9.0

Next indicates an expected call of Next.

type MockFieldsPostingsListIterable added in v0.15.0

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

MockFieldsPostingsListIterable is a mock of FieldsPostingsListIterable interface.

func NewMockFieldsPostingsListIterable added in v0.15.0

func NewMockFieldsPostingsListIterable(ctrl *gomock.Controller) *MockFieldsPostingsListIterable

NewMockFieldsPostingsListIterable creates a new mock instance.

func (*MockFieldsPostingsListIterable) EXPECT added in v0.15.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockFieldsPostingsListIterable) FieldsPostingsList added in v0.15.0

FieldsPostingsList mocks base method.

type MockFieldsPostingsListIterableMockRecorder added in v0.15.0

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

MockFieldsPostingsListIterableMockRecorder is the mock recorder for MockFieldsPostingsListIterable.

func (*MockFieldsPostingsListIterableMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockFieldsPostingsListIterableMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

type MockFieldsPostingsListIterator added in v0.15.0

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

MockFieldsPostingsListIterator is a mock of FieldsPostingsListIterator interface.

func NewMockFieldsPostingsListIterator added in v0.15.0

func NewMockFieldsPostingsListIterator(ctrl *gomock.Controller) *MockFieldsPostingsListIterator

NewMockFieldsPostingsListIterator creates a new mock instance.

func (*MockFieldsPostingsListIterator) Close added in v0.15.0

Close mocks base method.

func (*MockFieldsPostingsListIterator) Current added in v0.15.0

Current mocks base method.

func (*MockFieldsPostingsListIterator) EXPECT added in v0.15.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockFieldsPostingsListIterator) Err added in v0.15.0

Err mocks base method.

func (*MockFieldsPostingsListIterator) Next added in v0.15.0

Next mocks base method.

type MockFieldsPostingsListIteratorMockRecorder added in v0.15.0

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

MockFieldsPostingsListIteratorMockRecorder is the mock recorder for MockFieldsPostingsListIterator.

func (*MockFieldsPostingsListIteratorMockRecorder) Close added in v0.15.0

Close indicates an expected call of Close.

func (*MockFieldsPostingsListIteratorMockRecorder) Current added in v0.15.0

Current indicates an expected call of Current.

func (*MockFieldsPostingsListIteratorMockRecorder) Err added in v0.15.0

Err indicates an expected call of Err.

func (*MockFieldsPostingsListIteratorMockRecorder) Next added in v0.15.0

Next indicates an expected call of Next.

type MockImmutableSegment added in v0.15.0

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

MockImmutableSegment is a mock of ImmutableSegment interface.

func NewMockImmutableSegment added in v0.15.0

func NewMockImmutableSegment(ctrl *gomock.Controller) *MockImmutableSegment

NewMockImmutableSegment creates a new mock instance.

func (*MockImmutableSegment) Close added in v0.15.0

func (m *MockImmutableSegment) Close() error

Close mocks base method.

func (*MockImmutableSegment) ContainsField added in v0.15.0

func (m *MockImmutableSegment) ContainsField(field []byte) (bool, error)

ContainsField mocks base method.

func (*MockImmutableSegment) ContainsID added in v0.15.0

func (m *MockImmutableSegment) ContainsID(docID []byte) (bool, error)

ContainsID mocks base method.

func (*MockImmutableSegment) EXPECT added in v0.15.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockImmutableSegment) FieldsIterable added in v0.15.0

func (m *MockImmutableSegment) FieldsIterable() FieldsIterable

FieldsIterable mocks base method.

func (*MockImmutableSegment) FreeMmap added in v0.15.0

func (m *MockImmutableSegment) FreeMmap() error

FreeMmap mocks base method.

func (*MockImmutableSegment) Reader added in v0.15.0

func (m *MockImmutableSegment) Reader() (Reader, error)

Reader mocks base method.

func (*MockImmutableSegment) Size added in v0.15.0

func (m *MockImmutableSegment) Size() int64

Size mocks base method.

func (*MockImmutableSegment) TermsIterable added in v0.15.0

func (m *MockImmutableSegment) TermsIterable() TermsIterable

TermsIterable mocks base method.

type MockImmutableSegmentMockRecorder added in v0.15.0

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

MockImmutableSegmentMockRecorder is the mock recorder for MockImmutableSegment.

func (*MockImmutableSegmentMockRecorder) Close added in v0.15.0

Close indicates an expected call of Close.

func (*MockImmutableSegmentMockRecorder) ContainsField added in v0.15.0

func (mr *MockImmutableSegmentMockRecorder) ContainsField(field interface{}) *gomock.Call

ContainsField indicates an expected call of ContainsField.

func (*MockImmutableSegmentMockRecorder) ContainsID added in v0.15.0

func (mr *MockImmutableSegmentMockRecorder) ContainsID(docID interface{}) *gomock.Call

ContainsID indicates an expected call of ContainsID.

func (*MockImmutableSegmentMockRecorder) FieldsIterable added in v0.15.0

func (mr *MockImmutableSegmentMockRecorder) FieldsIterable() *gomock.Call

FieldsIterable indicates an expected call of FieldsIterable.

func (*MockImmutableSegmentMockRecorder) FreeMmap added in v0.15.0

FreeMmap indicates an expected call of FreeMmap.

func (*MockImmutableSegmentMockRecorder) Reader added in v0.15.0

Reader indicates an expected call of Reader.

func (*MockImmutableSegmentMockRecorder) Size added in v0.15.0

Size indicates an expected call of Size.

func (*MockImmutableSegmentMockRecorder) TermsIterable added in v0.15.0

func (mr *MockImmutableSegmentMockRecorder) TermsIterable() *gomock.Call

TermsIterable indicates an expected call of TermsIterable.

type MockIterator added in v0.15.0

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

MockIterator is a mock of Iterator interface.

func NewMockIterator added in v0.15.0

func NewMockIterator(ctrl *gomock.Controller) *MockIterator

NewMockIterator creates a new mock instance.

func (*MockIterator) Close added in v0.15.0

func (m *MockIterator) Close() error

Close mocks base method.

func (*MockIterator) EXPECT added in v0.15.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockIterator) Err added in v0.15.0

func (m *MockIterator) Err() error

Err mocks base method.

func (*MockIterator) Next added in v0.15.0

func (m *MockIterator) Next() bool

Next mocks base method.

type MockIteratorMockRecorder added in v0.15.0

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

MockIteratorMockRecorder is the mock recorder for MockIterator.

func (*MockIteratorMockRecorder) Close added in v0.15.0

func (mr *MockIteratorMockRecorder) Close() *gomock.Call

Close indicates an expected call of Close.

func (*MockIteratorMockRecorder) Err added in v0.15.0

Err indicates an expected call of Err.

func (*MockIteratorMockRecorder) Next added in v0.15.0

func (mr *MockIteratorMockRecorder) Next() *gomock.Call

Next indicates an expected call of Next.

type MockMutableSegment

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

MockMutableSegment is a mock of MutableSegment interface.

func NewMockMutableSegment

func NewMockMutableSegment(ctrl *gomock.Controller) *MockMutableSegment

NewMockMutableSegment creates a new mock instance.

func (*MockMutableSegment) AllDocs added in v0.5.0

func (m *MockMutableSegment) AllDocs() (index.IDDocIterator, error)

AllDocs mocks base method.

func (*MockMutableSegment) Close

func (m *MockMutableSegment) Close() error

Close mocks base method.

func (*MockMutableSegment) ContainsField added in v0.9.1

func (m *MockMutableSegment) ContainsField(field []byte) (bool, error)

ContainsField mocks base method.

func (*MockMutableSegment) ContainsID

func (m *MockMutableSegment) ContainsID(docID []byte) (bool, error)

ContainsID mocks base method.

func (*MockMutableSegment) Docs added in v0.5.0

func (m *MockMutableSegment) Docs() []doc.Metadata

Docs mocks base method.

func (*MockMutableSegment) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockMutableSegment) Fields

func (m *MockMutableSegment) Fields() (FieldsIterator, error)

Fields mocks base method.

func (*MockMutableSegment) FieldsIterable added in v0.5.0

func (m *MockMutableSegment) FieldsIterable() FieldsIterable

FieldsIterable mocks base method.

func (*MockMutableSegment) FieldsPostingsList added in v0.15.0

func (m *MockMutableSegment) FieldsPostingsList() (FieldsPostingsListIterator, error)

FieldsPostingsList mocks base method.

func (*MockMutableSegment) IndexConcurrency added in v0.15.6

func (m *MockMutableSegment) IndexConcurrency() int

IndexConcurrency mocks base method.

func (*MockMutableSegment) Insert

func (m *MockMutableSegment) Insert(d doc.Metadata) ([]byte, error)

Insert mocks base method.

func (*MockMutableSegment) InsertBatch

func (m *MockMutableSegment) InsertBatch(b index.Batch) error

InsertBatch mocks base method.

func (*MockMutableSegment) IsSealed

func (m *MockMutableSegment) IsSealed() bool

IsSealed mocks base method.

func (*MockMutableSegment) Reader

func (m *MockMutableSegment) Reader() (Reader, error)

Reader mocks base method.

func (*MockMutableSegment) Reset added in v0.5.0

func (m *MockMutableSegment) Reset()

Reset mocks base method.

func (*MockMutableSegment) Seal

func (m *MockMutableSegment) Seal() error

Seal mocks base method.

func (*MockMutableSegment) SetIndexConcurrency added in v0.15.6

func (m *MockMutableSegment) SetIndexConcurrency(value int)

SetIndexConcurrency mocks base method.

func (*MockMutableSegment) Size

func (m *MockMutableSegment) Size() int64

Size mocks base method.

func (*MockMutableSegment) Terms

func (m *MockMutableSegment) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

func (*MockMutableSegment) TermsIterable added in v0.5.0

func (m *MockMutableSegment) TermsIterable() TermsIterable

TermsIterable mocks base method.

type MockMutableSegmentMockRecorder

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

MockMutableSegmentMockRecorder is the mock recorder for MockMutableSegment.

func (*MockMutableSegmentMockRecorder) AllDocs added in v0.5.0

AllDocs indicates an expected call of AllDocs.

func (*MockMutableSegmentMockRecorder) Close

Close indicates an expected call of Close.

func (*MockMutableSegmentMockRecorder) ContainsField added in v0.9.1

func (mr *MockMutableSegmentMockRecorder) ContainsField(field interface{}) *gomock.Call

ContainsField indicates an expected call of ContainsField.

func (*MockMutableSegmentMockRecorder) ContainsID

func (mr *MockMutableSegmentMockRecorder) ContainsID(docID interface{}) *gomock.Call

ContainsID indicates an expected call of ContainsID.

func (*MockMutableSegmentMockRecorder) Docs added in v0.5.0

Docs indicates an expected call of Docs.

func (*MockMutableSegmentMockRecorder) Fields

Fields indicates an expected call of Fields.

func (*MockMutableSegmentMockRecorder) FieldsIterable added in v0.5.0

func (mr *MockMutableSegmentMockRecorder) FieldsIterable() *gomock.Call

FieldsIterable indicates an expected call of FieldsIterable.

func (*MockMutableSegmentMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockMutableSegmentMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockMutableSegmentMockRecorder) IndexConcurrency added in v0.15.6

func (mr *MockMutableSegmentMockRecorder) IndexConcurrency() *gomock.Call

IndexConcurrency indicates an expected call of IndexConcurrency.

func (*MockMutableSegmentMockRecorder) Insert

func (mr *MockMutableSegmentMockRecorder) Insert(d interface{}) *gomock.Call

Insert indicates an expected call of Insert.

func (*MockMutableSegmentMockRecorder) InsertBatch

func (mr *MockMutableSegmentMockRecorder) InsertBatch(b interface{}) *gomock.Call

InsertBatch indicates an expected call of InsertBatch.

func (*MockMutableSegmentMockRecorder) IsSealed

func (mr *MockMutableSegmentMockRecorder) IsSealed() *gomock.Call

IsSealed indicates an expected call of IsSealed.

func (*MockMutableSegmentMockRecorder) Reader

Reader indicates an expected call of Reader.

func (*MockMutableSegmentMockRecorder) Reset added in v0.5.0

Reset indicates an expected call of Reset.

func (*MockMutableSegmentMockRecorder) Seal

Seal indicates an expected call of Seal.

func (*MockMutableSegmentMockRecorder) SetIndexConcurrency added in v0.15.6

func (mr *MockMutableSegmentMockRecorder) SetIndexConcurrency(value interface{}) *gomock.Call

SetIndexConcurrency indicates an expected call of SetIndexConcurrency.

func (*MockMutableSegmentMockRecorder) Size

Size indicates an expected call of Size.

func (*MockMutableSegmentMockRecorder) Terms

func (mr *MockMutableSegmentMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

func (*MockMutableSegmentMockRecorder) TermsIterable added in v0.5.0

func (mr *MockMutableSegmentMockRecorder) TermsIterable() *gomock.Call

TermsIterable indicates an expected call of TermsIterable.

type MockOrderedBytesIterator added in v0.9.0

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

MockOrderedBytesIterator is a mock of OrderedBytesIterator interface.

func NewMockOrderedBytesIterator added in v0.9.0

func NewMockOrderedBytesIterator(ctrl *gomock.Controller) *MockOrderedBytesIterator

NewMockOrderedBytesIterator creates a new mock instance.

func (*MockOrderedBytesIterator) Close added in v0.9.0

func (m *MockOrderedBytesIterator) Close() error

Close mocks base method.

func (*MockOrderedBytesIterator) Current added in v0.9.0

func (m *MockOrderedBytesIterator) Current() []byte

Current mocks base method.

func (*MockOrderedBytesIterator) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockOrderedBytesIterator) Err added in v0.9.0

Err mocks base method.

func (*MockOrderedBytesIterator) Next added in v0.9.0

func (m *MockOrderedBytesIterator) Next() bool

Next mocks base method.

type MockOrderedBytesIteratorMockRecorder added in v0.9.0

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

MockOrderedBytesIteratorMockRecorder is the mock recorder for MockOrderedBytesIterator.

func (*MockOrderedBytesIteratorMockRecorder) Close added in v0.9.0

Close indicates an expected call of Close.

func (*MockOrderedBytesIteratorMockRecorder) Current added in v0.9.0

Current indicates an expected call of Current.

func (*MockOrderedBytesIteratorMockRecorder) Err added in v0.9.0

Err indicates an expected call of Err.

func (*MockOrderedBytesIteratorMockRecorder) Next added in v0.9.0

Next indicates an expected call of Next.

type MockReader added in v0.15.11

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

MockReader is a mock of Reader interface.

func NewMockReader added in v0.15.11

func NewMockReader(ctrl *gomock.Controller) *MockReader

NewMockReader creates a new mock instance.

func (*MockReader) AllDocs added in v0.15.11

func (m *MockReader) AllDocs() (index.IDDocIterator, error)

AllDocs mocks base method.

func (*MockReader) Close added in v0.15.11

func (m *MockReader) Close() error

Close mocks base method.

func (*MockReader) ContainsField added in v0.15.11

func (m *MockReader) ContainsField(field []byte) (bool, error)

ContainsField mocks base method.

func (*MockReader) Doc added in v0.15.11

func (m *MockReader) Doc(id postings.ID) (doc.Document, error)

Doc mocks base method.

func (*MockReader) Docs added in v0.15.11

func (m *MockReader) Docs(pl postings.List) (doc.Iterator, error)

Docs mocks base method.

func (*MockReader) EXPECT added in v0.15.11

func (m *MockReader) EXPECT() *MockReaderMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockReader) Fields added in v0.15.11

func (m *MockReader) Fields() (FieldsIterator, error)

Fields mocks base method.

func (*MockReader) FieldsPostingsList added in v1.2.0

func (m *MockReader) FieldsPostingsList() (FieldsPostingsListIterator, error)

FieldsPostingsList mocks base method.

func (*MockReader) MatchAll added in v0.15.11

func (m *MockReader) MatchAll() (postings.List, error)

MatchAll mocks base method.

func (*MockReader) MatchField added in v0.15.11

func (m *MockReader) MatchField(field []byte) (postings.List, error)

MatchField mocks base method.

func (*MockReader) MatchRegexp added in v0.15.11

func (m *MockReader) MatchRegexp(field []byte, c index.CompiledRegex) (postings.List, error)

MatchRegexp mocks base method.

func (*MockReader) MatchTerm added in v0.15.11

func (m *MockReader) MatchTerm(field, term []byte) (postings.List, error)

MatchTerm mocks base method.

func (*MockReader) Metadata added in v1.0.1

func (m *MockReader) Metadata(id postings.ID) (doc.Metadata, error)

Metadata mocks base method.

func (*MockReader) MetadataIterator added in v1.0.1

func (m *MockReader) MetadataIterator(pl postings.List) (doc.MetadataIterator, error)

MetadataIterator mocks base method.

func (*MockReader) Terms added in v0.15.11

func (m *MockReader) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

type MockReaderMockRecorder added in v0.15.11

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

MockReaderMockRecorder is the mock recorder for MockReader.

func (*MockReaderMockRecorder) AllDocs added in v0.15.11

func (mr *MockReaderMockRecorder) AllDocs() *gomock.Call

AllDocs indicates an expected call of AllDocs.

func (*MockReaderMockRecorder) Close added in v0.15.11

func (mr *MockReaderMockRecorder) Close() *gomock.Call

Close indicates an expected call of Close.

func (*MockReaderMockRecorder) ContainsField added in v0.15.11

func (mr *MockReaderMockRecorder) ContainsField(field interface{}) *gomock.Call

ContainsField indicates an expected call of ContainsField.

func (*MockReaderMockRecorder) Doc added in v0.15.11

func (mr *MockReaderMockRecorder) Doc(id interface{}) *gomock.Call

Doc indicates an expected call of Doc.

func (*MockReaderMockRecorder) Docs added in v0.15.11

func (mr *MockReaderMockRecorder) Docs(pl interface{}) *gomock.Call

Docs indicates an expected call of Docs.

func (*MockReaderMockRecorder) Fields added in v0.15.11

func (mr *MockReaderMockRecorder) Fields() *gomock.Call

Fields indicates an expected call of Fields.

func (*MockReaderMockRecorder) FieldsPostingsList added in v1.2.0

func (mr *MockReaderMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockReaderMockRecorder) MatchAll added in v0.15.11

func (mr *MockReaderMockRecorder) MatchAll() *gomock.Call

MatchAll indicates an expected call of MatchAll.

func (*MockReaderMockRecorder) MatchField added in v0.15.11

func (mr *MockReaderMockRecorder) MatchField(field interface{}) *gomock.Call

MatchField indicates an expected call of MatchField.

func (*MockReaderMockRecorder) MatchRegexp added in v0.15.11

func (mr *MockReaderMockRecorder) MatchRegexp(field, c interface{}) *gomock.Call

MatchRegexp indicates an expected call of MatchRegexp.

func (*MockReaderMockRecorder) MatchTerm added in v0.15.11

func (mr *MockReaderMockRecorder) MatchTerm(field, term interface{}) *gomock.Call

MatchTerm indicates an expected call of MatchTerm.

func (*MockReaderMockRecorder) Metadata added in v1.0.1

func (mr *MockReaderMockRecorder) Metadata(id interface{}) *gomock.Call

Metadata indicates an expected call of Metadata.

func (*MockReaderMockRecorder) MetadataIterator added in v1.0.1

func (mr *MockReaderMockRecorder) MetadataIterator(pl interface{}) *gomock.Call

MetadataIterator indicates an expected call of MetadataIterator.

func (*MockReaderMockRecorder) Terms added in v0.15.11

func (mr *MockReaderMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockSegment

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

MockSegment is a mock of Segment interface.

func NewMockSegment

func NewMockSegment(ctrl *gomock.Controller) *MockSegment

NewMockSegment creates a new mock instance.

func (*MockSegment) Close

func (m *MockSegment) Close() error

Close mocks base method.

func (*MockSegment) ContainsField added in v0.9.1

func (m *MockSegment) ContainsField(field []byte) (bool, error)

ContainsField mocks base method.

func (*MockSegment) ContainsID

func (m *MockSegment) ContainsID(docID []byte) (bool, error)

ContainsID mocks base method.

func (*MockSegment) EXPECT

func (m *MockSegment) EXPECT() *MockSegmentMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockSegment) FieldsIterable added in v0.5.0

func (m *MockSegment) FieldsIterable() FieldsIterable

FieldsIterable mocks base method.

func (*MockSegment) Reader

func (m *MockSegment) Reader() (Reader, error)

Reader mocks base method.

func (*MockSegment) Size

func (m *MockSegment) Size() int64

Size mocks base method.

func (*MockSegment) TermsIterable added in v0.5.0

func (m *MockSegment) TermsIterable() TermsIterable

TermsIterable mocks base method.

type MockSegmentMockRecorder

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

MockSegmentMockRecorder is the mock recorder for MockSegment.

func (*MockSegmentMockRecorder) Close

func (mr *MockSegmentMockRecorder) Close() *gomock.Call

Close indicates an expected call of Close.

func (*MockSegmentMockRecorder) ContainsField added in v0.9.1

func (mr *MockSegmentMockRecorder) ContainsField(field interface{}) *gomock.Call

ContainsField indicates an expected call of ContainsField.

func (*MockSegmentMockRecorder) ContainsID

func (mr *MockSegmentMockRecorder) ContainsID(docID interface{}) *gomock.Call

ContainsID indicates an expected call of ContainsID.

func (*MockSegmentMockRecorder) FieldsIterable added in v0.5.0

func (mr *MockSegmentMockRecorder) FieldsIterable() *gomock.Call

FieldsIterable indicates an expected call of FieldsIterable.

func (*MockSegmentMockRecorder) Reader

func (mr *MockSegmentMockRecorder) Reader() *gomock.Call

Reader indicates an expected call of Reader.

func (*MockSegmentMockRecorder) Size

func (mr *MockSegmentMockRecorder) Size() *gomock.Call

Size indicates an expected call of Size.

func (*MockSegmentMockRecorder) TermsIterable added in v0.5.0

func (mr *MockSegmentMockRecorder) TermsIterable() *gomock.Call

TermsIterable indicates an expected call of TermsIterable.

type MockSegmentsBuilder added in v0.9.0

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

MockSegmentsBuilder is a mock of SegmentsBuilder interface.

func NewMockSegmentsBuilder added in v0.9.0

func NewMockSegmentsBuilder(ctrl *gomock.Controller) *MockSegmentsBuilder

NewMockSegmentsBuilder creates a new mock instance.

func (*MockSegmentsBuilder) AddSegments added in v0.9.0

func (m *MockSegmentsBuilder) AddSegments(segments []Segment) error

AddSegments mocks base method.

func (*MockSegmentsBuilder) AllDocs added in v0.9.0

func (m *MockSegmentsBuilder) AllDocs() (index.IDDocIterator, error)

AllDocs mocks base method.

func (*MockSegmentsBuilder) Docs added in v0.9.0

func (m *MockSegmentsBuilder) Docs() []doc.Metadata

Docs mocks base method.

func (*MockSegmentsBuilder) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockSegmentsBuilder) FieldsPostingsList added in v0.15.0

func (m *MockSegmentsBuilder) FieldsPostingsList() (FieldsPostingsListIterator, error)

FieldsPostingsList mocks base method.

func (*MockSegmentsBuilder) Reset added in v0.9.0

func (m *MockSegmentsBuilder) Reset()

Reset mocks base method.

func (*MockSegmentsBuilder) SegmentMetadatas added in v1.2.0

func (m *MockSegmentsBuilder) SegmentMetadatas() ([]SegmentsBuilderSegmentMetadata, error)

SegmentMetadatas mocks base method.

func (*MockSegmentsBuilder) SetFilter added in v1.2.0

func (m *MockSegmentsBuilder) SetFilter(keep DocumentsFilter, filterCount tally.Counter)

SetFilter mocks base method.

func (*MockSegmentsBuilder) Terms added in v0.9.0

func (m *MockSegmentsBuilder) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

type MockSegmentsBuilderMockRecorder added in v0.9.0

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

MockSegmentsBuilderMockRecorder is the mock recorder for MockSegmentsBuilder.

func (*MockSegmentsBuilderMockRecorder) AddSegments added in v0.9.0

func (mr *MockSegmentsBuilderMockRecorder) AddSegments(segments interface{}) *gomock.Call

AddSegments indicates an expected call of AddSegments.

func (*MockSegmentsBuilderMockRecorder) AllDocs added in v0.9.0

AllDocs indicates an expected call of AllDocs.

func (*MockSegmentsBuilderMockRecorder) Docs added in v0.9.0

Docs indicates an expected call of Docs.

func (*MockSegmentsBuilderMockRecorder) FieldsPostingsList added in v0.15.0

func (mr *MockSegmentsBuilderMockRecorder) FieldsPostingsList() *gomock.Call

FieldsPostingsList indicates an expected call of FieldsPostingsList.

func (*MockSegmentsBuilderMockRecorder) Reset added in v0.9.0

Reset indicates an expected call of Reset.

func (*MockSegmentsBuilderMockRecorder) SegmentMetadatas added in v1.2.0

func (mr *MockSegmentsBuilderMockRecorder) SegmentMetadatas() *gomock.Call

SegmentMetadatas indicates an expected call of SegmentMetadatas.

func (*MockSegmentsBuilderMockRecorder) SetFilter added in v1.2.0

func (mr *MockSegmentsBuilderMockRecorder) SetFilter(keep, filterCount interface{}) *gomock.Call

SetFilter indicates an expected call of SetFilter.

func (*MockSegmentsBuilderMockRecorder) Terms added in v0.9.0

func (mr *MockSegmentsBuilderMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockTermsIterable added in v0.9.0

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

MockTermsIterable is a mock of TermsIterable interface.

func NewMockTermsIterable added in v0.9.0

func NewMockTermsIterable(ctrl *gomock.Controller) *MockTermsIterable

NewMockTermsIterable creates a new mock instance.

func (*MockTermsIterable) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockTermsIterable) Terms added in v0.9.0

func (m *MockTermsIterable) Terms(field []byte) (TermsIterator, error)

Terms mocks base method.

type MockTermsIterableMockRecorder added in v0.9.0

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

MockTermsIterableMockRecorder is the mock recorder for MockTermsIterable.

func (*MockTermsIterableMockRecorder) Terms added in v0.9.0

func (mr *MockTermsIterableMockRecorder) Terms(field interface{}) *gomock.Call

Terms indicates an expected call of Terms.

type MockTermsIterator added in v0.9.0

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

MockTermsIterator is a mock of TermsIterator interface.

func NewMockTermsIterator added in v0.9.0

func NewMockTermsIterator(ctrl *gomock.Controller) *MockTermsIterator

NewMockTermsIterator creates a new mock instance.

func (*MockTermsIterator) Close added in v0.9.0

func (m *MockTermsIterator) Close() error

Close mocks base method.

func (*MockTermsIterator) Current added in v0.9.0

func (m *MockTermsIterator) Current() ([]byte, postings.List)

Current mocks base method.

func (*MockTermsIterator) EXPECT added in v0.9.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockTermsIterator) Err added in v0.9.0

func (m *MockTermsIterator) Err() error

Err mocks base method.

func (*MockTermsIterator) Next added in v0.9.0

func (m *MockTermsIterator) Next() bool

Next mocks base method.

type MockTermsIteratorMockRecorder added in v0.9.0

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

MockTermsIteratorMockRecorder is the mock recorder for MockTermsIterator.

func (*MockTermsIteratorMockRecorder) Close added in v0.9.0

Close indicates an expected call of Close.

func (*MockTermsIteratorMockRecorder) Current added in v0.9.0

func (mr *MockTermsIteratorMockRecorder) Current() *gomock.Call

Current indicates an expected call of Current.

func (*MockTermsIteratorMockRecorder) Err added in v0.9.0

Err indicates an expected call of Err.

func (*MockTermsIteratorMockRecorder) Next added in v0.9.0

Next indicates an expected call of Next.

type MutableSegment

type MutableSegment interface {
	Segment
	DocumentsBuilder

	// Fields returns an iterator over the list of known fields, in order
	// by name, it is not valid for reading after mutating the
	// builder by inserting more documents.
	Fields() (FieldsIterator, error)

	// Seal marks the Mutable Segment immutable.
	Seal() error

	// IsSealed returns true iff the segment is open and un-sealed.
	IsSealed() bool
}

MutableSegment is a segment which can be updated.

type OrderedBytesIterator added in v0.4.1

type OrderedBytesIterator interface {
	// Next returns a bool indicating if there are any more elements.
	Next() bool

	// Current returns the current element.
	// NB: the element returned is only valid until the subsequent call to Next().
	Current() []byte

	// Err returns any errors encountered during iteration.
	Err() error

	// Close releases any resources held by the iterator.
	Close() error
}

OrderedBytesIterator iterates over a collection of []bytes in lexicographical order.

var EmptyOrderedBytesIterator OrderedBytesIterator = emptyBytesIter{}

EmptyOrderedBytesIterator is an empty OrderedBytesIterator.

type Reader added in v0.15.11

type Reader interface {
	index.Reader
	FieldsIterable
	TermsIterable
	FieldsPostingsListIterable

	// ContainsField returns a bool indicating if the Segment contains the provided field.
	ContainsField(field []byte) (bool, error)
}

Reader extends index reader interface to allow for reading of fields and terms.

type Segment

type Segment interface {
	// FieldsIterable returns an iterable fields, for which is not
	// safe for concurrent use. For concurrent use call FieldsIterable
	// multiple times.
	FieldsIterable() FieldsIterable

	// TermsIterable returns an iterable terms, for which is not
	// safe for concurrent use. For concurrent use call TermsIterable
	// multiple times.
	TermsIterable() TermsIterable

	// Size returns the number of documents within the Segment. It returns
	// 0 if the Segment has been closed.
	Size() int64

	// ContainsID returns a bool indicating if the Segment contains the provided ID.
	ContainsID(docID []byte) (bool, error)

	// ContainsField returns a bool indicating if the Segment contains the provided field.
	ContainsField(field []byte) (bool, error)

	// Reader returns a point-in-time accessor to search the segment.
	Reader() (Reader, error)

	// Close closes the segment and releases any internal resources.
	Close() error
}

Segment is a sub-collection of documents within an index.

type SegmentsBuilder added in v0.5.0

type SegmentsBuilder interface {
	Builder

	// SetFilter sets a filter on which documents to retain
	// when building the segment.
	SetFilter(keep DocumentsFilter, filterCount tally.Counter)

	// AddSegments adds segments to build from.
	AddSegments(segments []Segment) error

	// SegmentMetadatas returns the segment builder segment metadata.
	SegmentMetadatas() ([]SegmentsBuilderSegmentMetadata, error)
}

SegmentsBuilder is a builder that is built from segments.

type SegmentsBuilderSegmentMetadata added in v1.2.0

type SegmentsBuilderSegmentMetadata struct {
	Segment Segment
	Offset  postings.ID
	// NegativeOffsets is a lookup of document IDs are duplicates or should be skipped,
	// that is documents that are already contained by other segments or should
	// not be included in the output segment and hence should not be returned
	// when looking up documents. If this is the case offset is -1.
	// If a document ID is not a duplicate or skipped then the offset is
	// the shift that should be applied when translating this postings ID
	// to the result postings ID.
	NegativeOffsets []int64
	Skips           int64
}

SegmentsBuilderSegmentMetadata is a set of metadata about a segment that was used to build a compacted segment.

type TermsIterable added in v0.5.0

type TermsIterable interface {
	// Terms returns an iterator over the known terms values for the given
	// field, in order by name, it is not valid for reading after mutating the
	// builder by inserting more documents.
	Terms(field []byte) (TermsIterator, error)
}

TermsIterable can iterate over segment terms, it is not by default concurrency safe.

type TermsIterator added in v0.4.1

type TermsIterator interface {
	Iterator

	// Current returns the current element.
	// NB: the element returned is only valid until the subsequent call to Next().
	Current() (term []byte, postings postings.List)
}

TermsIterator iterates over all known terms for the provided field.

var EmptyTermsIterator TermsIterator = emptyTermsIter{}

EmptyTermsIterator is an empty EmptyTermsIterator.

Directories

Path Synopsis
fst
Package fst is a generated GoMock package.
Package fst is a generated GoMock package.
Package mem is a generated GoMock package.
Package mem is a generated GoMock package.

Jump to

Keyboard shortcuts

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