Documentation
¶
Index ¶
- func GetChainConfig(txSimContext protocol.TxSimContext) (*configPb.ChainConfig, error)
- func GetChainConfigEmptyParams(txSimContext protocol.TxSimContext) (*configPb.ChainConfig, error)
- func SetChainConfig(txSimContext protocol.TxSimContext, chainConfig *configPb.ChainConfig) ([]byte, error)
- type ChainBlockRuntime
- type ChainConfigContract
- type ChainConfigRuntime
- func (r *ChainConfigRuntime) AlterAddrType(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConfigRuntime) EnableOrDisableGas(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConfigRuntime) GetChainConfig(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConfigRuntime) GetChainConfigFromBlockHeight(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- type ChainConsensusRuntime
- func (r *ChainConsensusRuntime) ConsensusExtAdd(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) ConsensusExtDelete(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) ConsensusExtUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeIdAdd(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeIdDelete(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeIdUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeOrgAdd(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeOrgDelete(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) NodeOrgUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) ResourcePolicyAdd(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) ResourcePolicyDelete(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainConsensusRuntime) ResourcePolicyUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- type ChainCoreRuntime
- type ChainTrustMembersRuntime
- type ChainTrustRootsRuntime
- func (r *ChainTrustRootsRuntime) TrustRootAdd(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainTrustRootsRuntime) TrustRootDelete(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
- func (r *ChainTrustRootsRuntime) TrustRootUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetChainConfig ¶
func GetChainConfig(txSimContext protocol.TxSimContext) (*configPb.ChainConfig, error)
func GetChainConfigEmptyParams ¶
func GetChainConfigEmptyParams(txSimContext protocol.TxSimContext) (*configPb.ChainConfig, error)
func SetChainConfig ¶
func SetChainConfig(txSimContext protocol.TxSimContext, chainConfig *configPb.ChainConfig) ([]byte, error)
Types ¶
type ChainBlockRuntime ¶
type ChainBlockRuntime struct {
// contains filtered or unexported fields
}
ChainBlockRuntime chain block config update
func (*ChainBlockRuntime) BlockUpdate ¶
func (r *ChainBlockRuntime) BlockUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
type ChainConfigContract ¶
type ChainConfigContract struct {
// contains filtered or unexported fields
}
func NewChainConfigContract ¶
func NewChainConfigContract(log protocol.Logger) *ChainConfigContract
func (*ChainConfigContract) GetMethod ¶
func (c *ChainConfigContract) GetMethod(methodName string) common.ContractFunc
type ChainConfigRuntime ¶
type ChainConfigRuntime struct {
// contains filtered or unexported fields
}
ChainConfigRuntime get chain config info
func (*ChainConfigRuntime) AlterAddrType ¶
func (r *ChainConfigRuntime) AlterAddrType(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
AlterAddrType upgrade the type of address
func (*ChainConfigRuntime) EnableOrDisableGas ¶
func (r *ChainConfigRuntime) EnableOrDisableGas(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
EnableOrDisableGas enable or able gas
func (*ChainConfigRuntime) GetChainConfig ¶
func (r *ChainConfigRuntime) GetChainConfig(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
GetChainConfig get newest chain config
func (*ChainConfigRuntime) GetChainConfigFromBlockHeight ¶
func (r *ChainConfigRuntime) GetChainConfigFromBlockHeight(txSimContext protocol.TxSimContext, params map[string][]byte) (result []byte, err error)
GetChainConfigFromBlockHeight get chain config from less than or equal to block height
type ChainConsensusRuntime ¶
type ChainConsensusRuntime struct {
// contains filtered or unexported fields
}
ChainConsensusRuntime chain consensus config update
func (*ChainConsensusRuntime) ConsensusExtAdd ¶
func (r *ChainConsensusRuntime) ConsensusExtAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ConsensusExtAdd add consensus extra
func (*ChainConsensusRuntime) ConsensusExtDelete ¶
func (r *ChainConsensusRuntime) ConsensusExtDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ConsensusExtDelete delete consensus extra
func (*ChainConsensusRuntime) ConsensusExtUpdate ¶
func (r *ChainConsensusRuntime) ConsensusExtUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ConsensusExtUpdate update consensus extra
func (*ChainConsensusRuntime) NodeIdAdd ¶
func (r *ChainConsensusRuntime) NodeIdAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeIdAdd add nodeId
func (*ChainConsensusRuntime) NodeIdDelete ¶
func (r *ChainConsensusRuntime) NodeIdDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeIdDelete delete nodeId raft consensus in public key mode, when delete nodes, the remaining consensus nodes counts need >= 2
func (*ChainConsensusRuntime) NodeIdUpdate ¶
func (r *ChainConsensusRuntime) NodeIdUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeIdUpdate update nodeId
func (*ChainConsensusRuntime) NodeOrgAdd ¶
func (r *ChainConsensusRuntime) NodeOrgAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeOrgAdd add nodeOrg
func (*ChainConsensusRuntime) NodeOrgDelete ¶
func (r *ChainConsensusRuntime) NodeOrgDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeOrgDelete delete nodeOrg raft consensus in public key mode, when delete nodes, the remaining consensus nodes counts need >= 2
func (*ChainConsensusRuntime) NodeOrgUpdate ¶
func (r *ChainConsensusRuntime) NodeOrgUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
NodeOrgUpdate update nodeOrg
func (*ChainConsensusRuntime) ResourcePolicyAdd ¶
func (r *ChainConsensusRuntime) ResourcePolicyAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ResourcePolicyAdd add permission
func (*ChainConsensusRuntime) ResourcePolicyDelete ¶
func (r *ChainConsensusRuntime) ResourcePolicyDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ResourcePolicyDelete delete permission
func (*ChainConsensusRuntime) ResourcePolicyUpdate ¶
func (r *ChainConsensusRuntime) ResourcePolicyUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
ResourcePolicyUpdate update resource policy
type ChainCoreRuntime ¶
type ChainCoreRuntime struct {
// contains filtered or unexported fields
}
ChainCoreRuntime chain core config update
func (*ChainCoreRuntime) CoreUpdate ¶
func (r *ChainCoreRuntime) CoreUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ([]byte, error)
type ChainTrustMembersRuntime ¶
type ChainTrustMembersRuntime struct {
// contains filtered or unexported fields
}
ChainTrustMembersRuntime trust member(third cert) manager
func (*ChainTrustMembersRuntime) TrustMemberAdd ¶
func (r *ChainTrustMembersRuntime) TrustMemberAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
func (*ChainTrustMembersRuntime) TrustMemberDelete ¶
func (r *ChainTrustMembersRuntime) TrustMemberDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
type ChainTrustRootsRuntime ¶
type ChainTrustRootsRuntime struct {
// contains filtered or unexported fields
}
ChainTrustRootsRuntime chain trust root manager
func (*ChainTrustRootsRuntime) TrustRootAdd ¶
func (r *ChainTrustRootsRuntime) TrustRootAdd(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
TrustRootAdd add trustRoot
func (*ChainTrustRootsRuntime) TrustRootDelete ¶
func (r *ChainTrustRootsRuntime) TrustRootDelete(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
TrustRootDelete delete the org all trust root must not contain the consensus node cert issued by the cert
func (*ChainTrustRootsRuntime) TrustRootUpdate ¶
func (r *ChainTrustRootsRuntime) TrustRootUpdate(txSimContext protocol.TxSimContext, params map[string][]byte) ( result []byte, err error)
TrustRootUpdate update the trustRoot