types

package
v1.65.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 15, 2021 License: BSD-3-Clause Imports: 8 Imported by: 19

Documentation

Overview

Package types 管理插件相关的定义

Index

Constants

View Source
const (
	ConfigItemArrayConfig = iota
)

ConfigItemArrayConfig config Item

View Source
const (
	ManageActionModifyConfig = iota
)

ManageActionModifyConfig manager action

View Source
const (
	TyLogModifyConfig = 410
)

TyLogModifyConfig log

Variables

View Source
var (
	// ErrNoPrivilege defines a error string errnoprivilege
	ErrNoPrivilege = errors.New("ErrNoPrivilege")
	// ErrBadConfigKey defines a err string errbadconfigkey
	ErrBadConfigKey = errors.New("ErrBadConfigKey")
	// ErrBadConfigOp defines a err string errbadconfigop
	ErrBadConfigOp = errors.New("ErrBadConfigOp")
	// ErrBadConfigValue defines a err string errbadconfigvalue
	ErrBadConfigValue = errors.New("ErrBadConfigValue")
)
View Source
var File_manage_proto protoreflect.FileDescriptor
View Source
var (
	// ManageX defines a global string
	ManageX = "manage"
)

Functions

func InitExecutor

func InitExecutor(cfg *types.Chain33Config)

InitExecutor init Executor

func InitFork

func InitFork(cfg *types.Chain33Config)

InitFork init

Types

type ManageAction

type ManageAction struct {

	// Types that are assignable to Value:
	//	*ManageAction_Modify
	Value isManageAction_Value `protobuf_oneof:"value"`
	Ty    int32                `protobuf:"varint,2,opt,name=Ty,proto3" json:"Ty,omitempty"`
	// contains filtered or unexported fields
}

func (*ManageAction) Descriptor deprecated

func (*ManageAction) Descriptor() ([]byte, []int)

Deprecated: Use ManageAction.ProtoReflect.Descriptor instead.

func (*ManageAction) GetModify

func (x *ManageAction) GetModify() *types.ModifyConfig

func (*ManageAction) GetTy

func (x *ManageAction) GetTy() int32

func (*ManageAction) GetValue

func (m *ManageAction) GetValue() isManageAction_Value

func (*ManageAction) ProtoMessage

func (*ManageAction) ProtoMessage()

func (*ManageAction) ProtoReflect added in v1.65.3

func (x *ManageAction) ProtoReflect() protoreflect.Message

func (*ManageAction) Reset

func (x *ManageAction) Reset()

func (*ManageAction) String

func (x *ManageAction) String() string

type ManageAction_Modify

type ManageAction_Modify struct {
	Modify *types.ModifyConfig `protobuf:"bytes,1,opt,name=modify,proto3,oneof"`
}

type ManageType

type ManageType struct {
	types.ExecTypeBase
}

ManageType defines managetype

func NewType

func NewType(cfg *types.Chain33Config) *ManageType

NewType new a managetype object

func (ManageType) ActionName

func (m ManageType) ActionName(tx *types.Transaction) string

ActionName return action a string name

func (ManageType) Amount

func (m ManageType) Amount(tx *types.Transaction) (int64, error)

Amount amount

func (*ManageType) GetLogMap

func (m *ManageType) GetLogMap() map[int64]*types.LogInfo

GetLogMap get log for map

func (*ManageType) GetName

func (m *ManageType) GetName() string

GetName reset name

func (*ManageType) GetPayload

func (m *ManageType) GetPayload() types.Message

GetPayload return manageaction

func (ManageType) GetRealToAddr

func (m ManageType) GetRealToAddr(tx *types.Transaction) string

GetRealToAddr main reason for overloading this function is because of the manage protocol during implementation, to address specification varies fron height to height

func (ManageType) GetTypeMap

func (m ManageType) GetTypeMap() map[string]int32

GetTypeMap return typename of actionname

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL