Documentation ¶
Overview ¶
Package mem is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Merge ¶
func Merge(target sgmt.MutableSegment, srcs ...sgmt.MutableSegment) error
Merge merges the segments `srcs` into `target`.
func NewSegment ¶
NewSegment returns a new in-memory mutable segment. It will start assigning postings IDs at the provided offset.
Types ¶
type MockReadableSegment ¶
type MockReadableSegment struct {
// contains filtered or unexported fields
}
MockReadableSegment is a mock of ReadableSegment interface
func NewMockReadableSegment ¶
func NewMockReadableSegment(ctrl *gomock.Controller) *MockReadableSegment
NewMockReadableSegment creates a new mock instance
func (*MockReadableSegment) EXPECT ¶
func (m *MockReadableSegment) EXPECT() *MockReadableSegmentMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
type MockReadableSegmentMockRecorder ¶
type MockReadableSegmentMockRecorder struct {
// contains filtered or unexported fields
}
MockReadableSegmentMockRecorder is the mock recorder for MockReadableSegment
type Options ¶
type Options interface { // SetInstrumentOptions sets the instrument options. SetInstrumentOptions(value instrument.Options) Options // InstrumentOptions returns the instrument options. InstrumentOptions() instrument.Options // SetPostingsListPool sets the postings list pool. SetPostingsListPool(value postings.Pool) Options // PostingsListPool returns the postings list pool. PostingsListPool() postings.Pool // SetInitialCapacity sets the initial capacity. SetInitialCapacity(value int) Options // InitialCapacity returns the initial capacity. InitialCapacity() int // SetNewUUIDFn sets the function used to generate new UUIDs. SetNewUUIDFn(value util.NewUUIDFn) Options // NewUUIDFn returns the function used to generate new UUIDs. NewUUIDFn() util.NewUUIDFn }
Options is a collection of knobs for an in-memory segment.
type ReadableSegment ¶
type ReadableSegment interface {
// contains filtered or unexported methods
}
ReadableSegment is an internal interface for reading from a segment.
NB(jeromefroe): Currently mockgen requires that interfaces with embedded interfaces be generated with reflection mode, but private interfaces can only be generated with file mode so we can't mock this interface if its private. Once mockgen supports mocking private interfaces which contain embedded interfaces we can make this interface private.