Documentation ¶
Overview ¶
Package assetrate is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AssetRate ¶
type AssetRate struct { ID string `json:"id"` BaseAssetCode string `json:"baseAssetCode"` CounterAssetCode string `json:"counterAssetCode"` Amount float64 `json:"amount"` Scale float64 `json:"scale"` Source string `json:"source"` OrganizationID string `json:"organizationId"` LedgerID string `json:"ledgerId"` CreatedAt time.Time `json:"createdAt"` Metadata map[string]any `json:"metadata"` }
AssetRate is a struct designed to encapsulate response payload data.
type AssetRatePostgreSQLModel ¶
type AssetRatePostgreSQLModel struct { ID string BaseAssetCode string CounterAssetCode string Amount float64 Scale float64 Source string OrganizationID string LedgerID string CreatedAt time.Time Metadata map[string]any }
AssetRatePostgreSQLModel represents the entity AssetRatePostgreSQLModel into SQL context in Database
func (*AssetRatePostgreSQLModel) FromEntity ¶
func (a *AssetRatePostgreSQLModel) FromEntity(assetRate *AssetRate)
FromEntity converts an entity AssetRate to AssetRatePostgreSQLModel
func (*AssetRatePostgreSQLModel) ToEntity ¶
func (a *AssetRatePostgreSQLModel) ToEntity() *AssetRate
ToEntity converts an TransactionPostgreSQLModel to entity Transaction
type AssetRatePostgreSQLRepository ¶
type AssetRatePostgreSQLRepository struct {
// contains filtered or unexported fields
}
AssetRatePostgreSQLRepository is a Postgresql-specific implementation of the AssetRateRepository.
func NewAssetRatePostgreSQLRepository ¶
func NewAssetRatePostgreSQLRepository(pc *mpostgres.PostgresConnection) *AssetRatePostgreSQLRepository
NewAssetRatePostgreSQLRepository returns a new instance of AssetRatePostgreSQLRepository using the given Postgres connection.
type CreateAssetRateInput ¶
type CreateAssetRateInput struct { BaseAssetCode string `json:"baseAssetCode"` CounterAssetCode string `json:"counterAssetCode"` Amount float64 `json:"amount"` Scale float64 `json:"scale"` Source string `json:"source"` Metadata map[string]any `json:"metadata,omitempty"` }
CreateAssetRateInput is a struct design to encapsulate payload data.
type MockRepository ¶
type MockRepository struct {
// contains filtered or unexported fields
}
MockRepository is a mock of Repository interface.
func NewMockRepository ¶
func NewMockRepository(ctrl *gomock.Controller) *MockRepository
NewMockRepository creates a new mock instance.
func (*MockRepository) EXPECT ¶
func (m *MockRepository) EXPECT() *MockRepositoryMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockRepositoryMockRecorder ¶
type MockRepositoryMockRecorder struct {
// contains filtered or unexported fields
}
MockRepositoryMockRecorder is the mock recorder for MockRepository.