Documentation ¶
Index ¶
- type MockValidatorsView
- func (validatorsView *MockValidatorsView) Count() (int64, error)
- func (validatorsView *MockValidatorsView) FindLastBy(identity ValidatorIdentity) (*ValidatorRow, error)
- func (validatorsView *MockValidatorsView) Insert(row *ValidatorRow) error
- func (validatorsView *MockValidatorsView) ListAll() ([]ValidatorRow, error)
- func (validatorsView *MockValidatorsView) Update(row *ValidatorRow) error
- func (validatorsView *MockValidatorsView) Upsert(row *ValidatorRow) error
- type ValidatorIdentity
- type ValidatorRow
- type Validators
- type ValidatorsView
- func (validatorsView *ValidatorsView) Count() (int64, error)
- func (validatorsView *ValidatorsView) FindLastBy(identity ValidatorIdentity) (*ValidatorRow, error)
- func (validatorsView *ValidatorsView) Insert(validator *ValidatorRow) error
- func (validatorsView *ValidatorsView) ListAll() ([]ValidatorRow, error)
- func (validatorsView *ValidatorsView) Update(validator *ValidatorRow) error
- func (validatorsView *ValidatorsView) Upsert(validator *ValidatorRow) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockValidatorsView ¶
type MockValidatorsView struct {
testify_mock.Mock
}
func (*MockValidatorsView) Count ¶
func (validatorsView *MockValidatorsView) Count() ( int64, error, )
func (*MockValidatorsView) FindLastBy ¶
func (validatorsView *MockValidatorsView) FindLastBy( identity ValidatorIdentity, ) ( *ValidatorRow, error, )
func (*MockValidatorsView) Insert ¶
func (validatorsView *MockValidatorsView) Insert(row *ValidatorRow) error
func (*MockValidatorsView) ListAll ¶
func (validatorsView *MockValidatorsView) ListAll() ( []ValidatorRow, error, )
func (*MockValidatorsView) Update ¶
func (validatorsView *MockValidatorsView) Update(row *ValidatorRow) error
func (*MockValidatorsView) Upsert ¶
func (validatorsView *MockValidatorsView) Upsert(row *ValidatorRow) error
type ValidatorIdentity ¶
type ValidatorRow ¶
type ValidatorRow struct { MaybeId *int64 `json:"-"` ConsensusNodeAddress string `json:"consensusNodeAddress"` OperatorAddress string `json:"operatorAddress"` InitialDelegatorAddress string `json:"initialDelegatorAddress"` TendermintPubkey string `json:"tendermintPubkey"` TendermintAddress string `json:"tendermintAddress"` Moniker string `json:"moniker"` }
type Validators ¶
type Validators interface { Upsert(validator *ValidatorRow) error Insert(validator *ValidatorRow) error Update(validator *ValidatorRow) error ListAll() ([]ValidatorRow, error) FindLastBy(identity ValidatorIdentity) (*ValidatorRow, error) Count() (int64, error) }
func NewMockValidatorsView ¶
func NewMockValidatorsView() Validators
func NewValidatorsView ¶
func NewValidatorsView(handle *rdb.Handle, tableName string) Validators
type ValidatorsView ¶
type ValidatorsView struct {
// contains filtered or unexported fields
}
A generic validator view
func (*ValidatorsView) Count ¶
func (validatorsView *ValidatorsView) Count() (int64, error)
func (*ValidatorsView) FindLastBy ¶
func (validatorsView *ValidatorsView) FindLastBy(identity ValidatorIdentity) (*ValidatorRow, error)
func (*ValidatorsView) Insert ¶
func (validatorsView *ValidatorsView) Insert(validator *ValidatorRow) error
func (*ValidatorsView) ListAll ¶
func (validatorsView *ValidatorsView) ListAll() ([]ValidatorRow, error)
func (*ValidatorsView) Update ¶
func (validatorsView *ValidatorsView) Update(validator *ValidatorRow) error
func (*ValidatorsView) Upsert ¶
func (validatorsView *ValidatorsView) Upsert(validator *ValidatorRow) error
Click to show internal directories.
Click to hide internal directories.