fabric: github.com/hyperledger/fabric/common/mocks/configtx Index | Files

package configtx

import "github.com/hyperledger/fabric/common/mocks/configtx"


Package Files


type Validator Uses

type Validator struct {
    // ChainIDVal is returned as the result of ChainID()
    ChainIDVal string

    // SequenceVal is returned as the result of Sequence()
    SequenceVal uint64

    // ApplyVal is returned by Apply
    ApplyVal error

    // AppliedConfigUpdateEnvelope is set by Apply
    AppliedConfigUpdateEnvelope *cb.ConfigEnvelope

    // ValidateVal is returned by Validate
    ValidateVal error

    // ProposeConfigUpdateError is returned as the error value for ProposeConfigUpdate
    ProposeConfigUpdateError error

    // ProposeConfigUpdateVal is returns as the value for ProposeConfigUpdate
    ProposeConfigUpdateVal *cb.ConfigEnvelope

    // ConfigProtoVal is returned as the value for ConfigProtoVal()
    ConfigProtoVal *cb.Config

Validator is a mock implementation of configtx.Validator

func (*Validator) Apply Uses

func (cm *Validator) Apply(configEnv *cb.ConfigEnvelope) error

Apply returns ApplyVal

func (*Validator) ChainID Uses

func (cm *Validator) ChainID() string

ConsensusType returns the ConsensusTypeVal

func (*Validator) ConfigProto Uses

func (cm *Validator) ConfigProto() *cb.Config

ConfigProto returns the ConfigProtoVal

func (*Validator) ProposeConfigUpdate Uses

func (cm *Validator) ProposeConfigUpdate(update *cb.Envelope) (*cb.ConfigEnvelope, error)


func (*Validator) Sequence Uses

func (cm *Validator) Sequence() uint64

BatchSize returns the BatchSizeVal

func (*Validator) Validate Uses

func (cm *Validator) Validate(configEnv *cb.ConfigEnvelope) error

Validate returns ValidateVal

Package configtx imports 1 packages (graph) and is imported by 6 packages. Updated 2018-03-26. Refresh now. Tools for package owners.