Documentation ¶
Overview ¶
Package segment is a generated GoMock package.
Index ¶
- Variables
- type MockMutableSegment
- func (m *MockMutableSegment) Close() error
- func (m *MockMutableSegment) ContainsID(arg0 []byte) (bool, error)
- func (m *MockMutableSegment) EXPECT() *MockMutableSegmentMockRecorder
- func (m *MockMutableSegment) Fields() ([][]byte, error)
- func (m *MockMutableSegment) Insert(arg0 doc.Document) ([]byte, error)
- func (m *MockMutableSegment) InsertBatch(arg0 index.Batch) error
- func (m *MockMutableSegment) IsSealed() bool
- func (m *MockMutableSegment) Reader() (index.Reader, error)
- func (m *MockMutableSegment) Seal() (Segment, error)
- func (m *MockMutableSegment) Size() int64
- func (m *MockMutableSegment) Terms(arg0 []byte) ([][]byte, error)
- type MockMutableSegmentMockRecorder
- func (mr *MockMutableSegmentMockRecorder) Close() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) ContainsID(arg0 interface{}) *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Fields() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Insert(arg0 interface{}) *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) InsertBatch(arg0 interface{}) *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) IsSealed() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Reader() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Seal() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Size() *gomock.Call
- func (mr *MockMutableSegmentMockRecorder) Terms(arg0 interface{}) *gomock.Call
- type MockSegment
- func (m *MockSegment) Close() error
- func (m *MockSegment) ContainsID(arg0 []byte) (bool, error)
- func (m *MockSegment) EXPECT() *MockSegmentMockRecorder
- func (m *MockSegment) Fields() ([][]byte, error)
- func (m *MockSegment) Reader() (index.Reader, error)
- func (m *MockSegment) Size() int64
- func (m *MockSegment) Terms(arg0 []byte) ([][]byte, error)
- type MockSegmentMockRecorder
- func (mr *MockSegmentMockRecorder) Close() *gomock.Call
- func (mr *MockSegmentMockRecorder) ContainsID(arg0 interface{}) *gomock.Call
- func (mr *MockSegmentMockRecorder) Fields() *gomock.Call
- func (mr *MockSegmentMockRecorder) Reader() *gomock.Call
- func (mr *MockSegmentMockRecorder) Size() *gomock.Call
- func (mr *MockSegmentMockRecorder) Terms(arg0 interface{}) *gomock.Call
- type MutableSegment
- type Segment
Constants ¶
This section is empty.
Variables ¶
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 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) Close ¶
func (m *MockMutableSegment) Close() error
Close mocks base method
func (*MockMutableSegment) ContainsID ¶
func (m *MockMutableSegment) ContainsID(arg0 []byte) (bool, error)
ContainsID mocks base method
func (*MockMutableSegment) EXPECT ¶
func (m *MockMutableSegment) EXPECT() *MockMutableSegmentMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockMutableSegment) Fields ¶
func (m *MockMutableSegment) Fields() ([][]byte, error)
Fields mocks base method
func (*MockMutableSegment) Insert ¶
func (m *MockMutableSegment) Insert(arg0 doc.Document) ([]byte, error)
Insert mocks base method
func (*MockMutableSegment) InsertBatch ¶
func (m *MockMutableSegment) InsertBatch(arg0 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() (index.Reader, error)
Reader mocks base method
func (*MockMutableSegment) Seal ¶
func (m *MockMutableSegment) Seal() (Segment, error)
Seal mocks base method
type MockMutableSegmentMockRecorder ¶
type MockMutableSegmentMockRecorder struct {
// contains filtered or unexported fields
}
MockMutableSegmentMockRecorder is the mock recorder for MockMutableSegment
func (*MockMutableSegmentMockRecorder) Close ¶
func (mr *MockMutableSegmentMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close
func (*MockMutableSegmentMockRecorder) ContainsID ¶
func (mr *MockMutableSegmentMockRecorder) ContainsID(arg0 interface{}) *gomock.Call
ContainsID indicates an expected call of ContainsID
func (*MockMutableSegmentMockRecorder) Fields ¶
func (mr *MockMutableSegmentMockRecorder) Fields() *gomock.Call
Fields indicates an expected call of Fields
func (*MockMutableSegmentMockRecorder) Insert ¶
func (mr *MockMutableSegmentMockRecorder) Insert(arg0 interface{}) *gomock.Call
Insert indicates an expected call of Insert
func (*MockMutableSegmentMockRecorder) InsertBatch ¶
func (mr *MockMutableSegmentMockRecorder) InsertBatch(arg0 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 ¶
func (mr *MockMutableSegmentMockRecorder) Reader() *gomock.Call
Reader indicates an expected call of Reader
func (*MockMutableSegmentMockRecorder) Seal ¶
func (mr *MockMutableSegmentMockRecorder) Seal() *gomock.Call
Seal indicates an expected call of Seal
func (*MockMutableSegmentMockRecorder) Size ¶
func (mr *MockMutableSegmentMockRecorder) Size() *gomock.Call
Size indicates an expected call of Size
func (*MockMutableSegmentMockRecorder) Terms ¶
func (mr *MockMutableSegmentMockRecorder) Terms(arg0 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) ContainsID ¶
func (m *MockSegment) ContainsID(arg0 []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) Fields ¶
func (m *MockSegment) Fields() ([][]byte, error)
Fields 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) ContainsID ¶
func (mr *MockSegmentMockRecorder) ContainsID(arg0 interface{}) *gomock.Call
ContainsID indicates an expected call of ContainsID
func (*MockSegmentMockRecorder) Fields ¶
func (mr *MockSegmentMockRecorder) Fields() *gomock.Call
Fields indicates an expected call of Fields
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) Terms ¶
func (mr *MockSegmentMockRecorder) Terms(arg0 interface{}) *gomock.Call
Terms indicates an expected call of Terms
type MutableSegment ¶
type MutableSegment interface { Segment index.Writer // Seal marks the Mutable Segment immutable. Seal() (Segment, error) // IsSealed returns true iff the segment is open and un-sealed. IsSealed() bool }
MutableSegment is a segment which can be updated.
type Segment ¶
type Segment interface { // 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) // Reader returns a point-in-time accessor to search the segment. Reader() (index.Reader, error) // Fields returns the list of known fields. Fields() ([][]byte, error) // Terms returns the list of known terms values for the given field. Terms(field []byte) ([][]byte, error) // Close closes the segment and releases any internal resources. Close() error }
Segment is a sub-collection of documents within an index.
Directories ¶
Path | Synopsis |
---|---|
Package fs is a generated GoMock package.
|
Package fs is a generated GoMock package. |
Package mem is a generated GoMock package.
|
Package mem is a generated GoMock package. |