github.com/m3db/m3@v1.5.0/src/cmd/services/m3coordinator/ingest/write_mock.go (about) 1 // Code generated by MockGen. DO NOT EDIT. 2 // Source: github.com/m3db/m3/src/cmd/services/m3coordinator/ingest (interfaces: DownsamplerAndWriter) 3 4 // Copyright (c) 2021 Uber Technologies, Inc. 5 // 6 // Permission is hereby granted, free of charge, to any person obtaining a copy 7 // of this software and associated documentation files (the "Software"), to deal 8 // in the Software without restriction, including without limitation the rights 9 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 // copies of the Software, and to permit persons to whom the Software is 11 // furnished to do so, subject to the following conditions: 12 // 13 // The above copyright notice and this permission notice shall be included in 14 // all copies or substantial portions of the Software. 15 // 16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 // THE SOFTWARE. 23 24 // Package ingest is a generated GoMock package. 25 package ingest 26 27 import ( 28 "context" 29 "reflect" 30 31 "github.com/m3db/m3/src/cmd/services/m3coordinator/downsample" 32 "github.com/m3db/m3/src/query/models" 33 "github.com/m3db/m3/src/query/storage" 34 "github.com/m3db/m3/src/query/ts" 35 "github.com/m3db/m3/src/x/time" 36 37 "github.com/golang/mock/gomock" 38 ) 39 40 // MockDownsamplerAndWriter is a mock of DownsamplerAndWriter interface. 41 type MockDownsamplerAndWriter struct { 42 ctrl *gomock.Controller 43 recorder *MockDownsamplerAndWriterMockRecorder 44 } 45 46 // MockDownsamplerAndWriterMockRecorder is the mock recorder for MockDownsamplerAndWriter. 47 type MockDownsamplerAndWriterMockRecorder struct { 48 mock *MockDownsamplerAndWriter 49 } 50 51 // NewMockDownsamplerAndWriter creates a new mock instance. 52 func NewMockDownsamplerAndWriter(ctrl *gomock.Controller) *MockDownsamplerAndWriter { 53 mock := &MockDownsamplerAndWriter{ctrl: ctrl} 54 mock.recorder = &MockDownsamplerAndWriterMockRecorder{mock} 55 return mock 56 } 57 58 // EXPECT returns an object that allows the caller to indicate expected use. 59 func (m *MockDownsamplerAndWriter) EXPECT() *MockDownsamplerAndWriterMockRecorder { 60 return m.recorder 61 } 62 63 // Downsampler mocks base method. 64 func (m *MockDownsamplerAndWriter) Downsampler() downsample.Downsampler { 65 m.ctrl.T.Helper() 66 ret := m.ctrl.Call(m, "Downsampler") 67 ret0, _ := ret[0].(downsample.Downsampler) 68 return ret0 69 } 70 71 // Downsampler indicates an expected call of Downsampler. 72 func (mr *MockDownsamplerAndWriterMockRecorder) Downsampler() *gomock.Call { 73 mr.mock.ctrl.T.Helper() 74 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Downsampler", reflect.TypeOf((*MockDownsamplerAndWriter)(nil).Downsampler)) 75 } 76 77 // Storage mocks base method. 78 func (m *MockDownsamplerAndWriter) Storage() storage.Storage { 79 m.ctrl.T.Helper() 80 ret := m.ctrl.Call(m, "Storage") 81 ret0, _ := ret[0].(storage.Storage) 82 return ret0 83 } 84 85 // Storage indicates an expected call of Storage. 86 func (mr *MockDownsamplerAndWriterMockRecorder) Storage() *gomock.Call { 87 mr.mock.ctrl.T.Helper() 88 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Storage", reflect.TypeOf((*MockDownsamplerAndWriter)(nil).Storage)) 89 } 90 91 // Write mocks base method. 92 func (m *MockDownsamplerAndWriter) Write(arg0 context.Context, arg1 models.Tags, arg2 ts.Datapoints, arg3 time.Unit, arg4 []byte, arg5 WriteOptions, arg6 ts.SourceType) error { 93 m.ctrl.T.Helper() 94 ret := m.ctrl.Call(m, "Write", arg0, arg1, arg2, arg3, arg4, arg5, arg6) 95 ret0, _ := ret[0].(error) 96 return ret0 97 } 98 99 // Write indicates an expected call of Write. 100 func (mr *MockDownsamplerAndWriterMockRecorder) Write(arg0, arg1, arg2, arg3, arg4, arg5, arg6 interface{}) *gomock.Call { 101 mr.mock.ctrl.T.Helper() 102 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Write", reflect.TypeOf((*MockDownsamplerAndWriter)(nil).Write), arg0, arg1, arg2, arg3, arg4, arg5, arg6) 103 } 104 105 // WriteBatch mocks base method. 106 func (m *MockDownsamplerAndWriter) WriteBatch(arg0 context.Context, arg1 DownsampleAndWriteIter, arg2 WriteOptions) BatchError { 107 m.ctrl.T.Helper() 108 ret := m.ctrl.Call(m, "WriteBatch", arg0, arg1, arg2) 109 ret0, _ := ret[0].(BatchError) 110 return ret0 111 } 112 113 // WriteBatch indicates an expected call of WriteBatch. 114 func (mr *MockDownsamplerAndWriterMockRecorder) WriteBatch(arg0, arg1, arg2 interface{}) *gomock.Call { 115 mr.mock.ctrl.T.Helper() 116 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WriteBatch", reflect.TypeOf((*MockDownsamplerAndWriter)(nil).WriteBatch), arg0, arg1, arg2) 117 }