Documentation ¶
Overview ¶
package dealssvc is a generated GoMock package.
Index ¶
- type DealsService
- type MockDealsService
- func (m *MockDealsService) Delete(accountID, dealID int64) error
- func (m *MockDealsService) EXPECT() *MockDealsServiceMockRecorder
- func (m *MockDealsService) GetByID(accountID, dealID int64) (*deals.Deal, error)
- func (m *MockDealsService) GetTickerBeats(accountID int64, from time.Time) ([]*deals.Deal, error)
- func (m *MockDealsService) Insert(ac *deals.Deal) error
- func (m *MockDealsService) Update(ac *deals.Deal) error
- func (m *MockDealsService) UpdateOrderIdByPosition(accountID, positionID, orderID int64) error
- type MockDealsServiceMockRecorder
- func (mr *MockDealsServiceMockRecorder) Delete(accountID, dealID interface{}) *gomock.Call
- func (mr *MockDealsServiceMockRecorder) GetByID(accountID, dealID interface{}) *gomock.Call
- func (mr *MockDealsServiceMockRecorder) GetTickerBeats(accountID, from interface{}) *gomock.Call
- func (mr *MockDealsServiceMockRecorder) Insert(ac interface{}) *gomock.Call
- func (mr *MockDealsServiceMockRecorder) Update(ac interface{}) *gomock.Call
- func (mr *MockDealsServiceMockRecorder) UpdateOrderIdByPosition(accountID, positionID, orderID interface{}) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DealsService ¶
type DealsService interface { Insert(ac *deals.Deal) error GetByID(accountID, dealID int64) (*deals.Deal, error) Update(ac *deals.Deal) error Delete(accountID, dealID int64) error GetTickerBeats(accountID int64, from time.Time) ([]*deals.Deal, error) UpdateOrderIdByPosition(accountID, positionID, orderID int64) error }
DealsService is a CRUD to the database
func NewDealsService ¶
func NewDealsService(ctx context.Context, repo repo.DealsRepository, pos ps.PositionsService, beats bb.TickerBeatsService) DealsService
NewDealsService creates a service to interact with PostgreSQL
type MockDealsService ¶ added in v0.17.0
type MockDealsService struct {
// contains filtered or unexported fields
}
MockDealsService is a mock of DealsService interface.
func NewMockDealsService ¶ added in v0.17.0
func NewMockDealsService(ctrl *gomock.Controller) *MockDealsService
NewMockDealsService creates a new mock instance.
func (*MockDealsService) Delete ¶ added in v0.17.0
func (m *MockDealsService) Delete(accountID, dealID int64) error
Delete mocks base method.
func (*MockDealsService) EXPECT ¶ added in v0.17.0
func (m *MockDealsService) EXPECT() *MockDealsServiceMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockDealsService) GetByID ¶ added in v0.17.0
func (m *MockDealsService) GetByID(accountID, dealID int64) (*deals.Deal, error)
GetByID mocks base method.
func (*MockDealsService) GetTickerBeats ¶ added in v0.17.0
GetTickerBeats mocks base method.
func (*MockDealsService) Insert ¶ added in v0.17.0
func (m *MockDealsService) Insert(ac *deals.Deal) error
Insert mocks base method.
func (*MockDealsService) Update ¶ added in v0.17.0
func (m *MockDealsService) Update(ac *deals.Deal) error
Update mocks base method.
func (*MockDealsService) UpdateOrderIdByPosition ¶ added in v0.17.0
func (m *MockDealsService) UpdateOrderIdByPosition(accountID, positionID, orderID int64) error
UpdateOrderIdByPosition mocks base method.
type MockDealsServiceMockRecorder ¶ added in v0.17.0
type MockDealsServiceMockRecorder struct {
// contains filtered or unexported fields
}
MockDealsServiceMockRecorder is the mock recorder for MockDealsService.
func (*MockDealsServiceMockRecorder) Delete ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) Delete(accountID, dealID interface{}) *gomock.Call
Delete indicates an expected call of Delete.
func (*MockDealsServiceMockRecorder) GetByID ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) GetByID(accountID, dealID interface{}) *gomock.Call
GetByID indicates an expected call of GetByID.
func (*MockDealsServiceMockRecorder) GetTickerBeats ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) GetTickerBeats(accountID, from interface{}) *gomock.Call
GetTickerBeats indicates an expected call of GetTickerBeats.
func (*MockDealsServiceMockRecorder) Insert ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) Insert(ac interface{}) *gomock.Call
Insert indicates an expected call of Insert.
func (*MockDealsServiceMockRecorder) Update ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) Update(ac interface{}) *gomock.Call
Update indicates an expected call of Update.
func (*MockDealsServiceMockRecorder) UpdateOrderIdByPosition ¶ added in v0.17.0
func (mr *MockDealsServiceMockRecorder) UpdateOrderIdByPosition(accountID, positionID, orderID interface{}) *gomock.Call
UpdateOrderIdByPosition indicates an expected call of UpdateOrderIdByPosition.