executor

package
Version: v1.65.2 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2021 License: BSD-3-Clause Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetName

func GetName() string

GetName 获得执行器名字

func Init

func Init(name string, cfg *types.Chain33Config, sub []byte)

Init 重命名执行器名称

func InitExecType

func InitExecType()

InitExecType ...

func NewBoardTable

func NewBoardTable(kvdb db.KV) *table.Table

NewBoardTable 新建表

func NewChangeTable

func NewChangeTable(kvdb db.KV) *table.Table

NewChangeTable 新建表

func NewProjectTable

func NewProjectTable(kvdb db.KV) *table.Table

NewProjectTable 新建表

func NewRuleTable

func NewRuleTable(kvdb db.KV) *table.Table

NewRuleTable 新建表

Types

type Autonomy

type Autonomy struct {
	drivers.DriverBase
}

Autonomy 执行器结构体

func (*Autonomy) ExecDelLocal

func (a *Autonomy) ExecDelLocal(tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecDelLocal 回退自动删除,重写基类

func (*Autonomy) ExecLocal_CommentProp

func (a *Autonomy) ExecLocal_CommentProp(payload *auty.Comment, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_CommentProp 评论提案

func (*Autonomy) ExecLocal_PropBoard

func (a *Autonomy) ExecLocal_PropBoard(payload *auty.ProposalBoard, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_PropBoard 创建提案

func (*Autonomy) ExecLocal_PropChange

func (a *Autonomy) ExecLocal_PropChange(payload *auty.ProposalChange, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_PropChange 创建提案规则

func (*Autonomy) ExecLocal_PropProject

func (a *Autonomy) ExecLocal_PropProject(payload *auty.ProposalProject, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_PropProject 创建提案项目

func (*Autonomy) ExecLocal_PropRule

func (a *Autonomy) ExecLocal_PropRule(payload *auty.ProposalRule, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_PropRule 创建提案规则

func (*Autonomy) ExecLocal_PubVotePropProject

func (a *Autonomy) ExecLocal_PubVotePropProject(payload *auty.PubVoteProposalProject, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_PubVotePropProject 全体投票提案项目

func (*Autonomy) ExecLocal_RvkPropBoard

func (a *Autonomy) ExecLocal_RvkPropBoard(payload *auty.RevokeProposalBoard, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_RvkPropBoard 撤销提案

func (*Autonomy) ExecLocal_RvkPropChange

func (a *Autonomy) ExecLocal_RvkPropChange(payload *auty.RevokeProposalChange, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_RvkPropChange 撤销提案规则

func (*Autonomy) ExecLocal_RvkPropProject

func (a *Autonomy) ExecLocal_RvkPropProject(payload *auty.RevokeProposalProject, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_RvkPropProject 撤销提案项目

func (*Autonomy) ExecLocal_RvkPropRule

func (a *Autonomy) ExecLocal_RvkPropRule(payload *auty.RevokeProposalRule, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_RvkPropRule 撤销提案规则

func (*Autonomy) ExecLocal_TmintPropBoard

func (a *Autonomy) ExecLocal_TmintPropBoard(payload *auty.TerminateProposalBoard, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_TmintPropBoard 终止提案

func (*Autonomy) ExecLocal_TmintPropChange

func (a *Autonomy) ExecLocal_TmintPropChange(payload *auty.TerminateProposalChange, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_TmintPropChange 终止提案规则

func (*Autonomy) ExecLocal_TmintPropProject

func (a *Autonomy) ExecLocal_TmintPropProject(payload *auty.TerminateProposalProject, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_TmintPropProject 终止提案项目

func (*Autonomy) ExecLocal_TmintPropRule

func (a *Autonomy) ExecLocal_TmintPropRule(payload *auty.TerminateProposalRule, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_TmintPropRule 终止提案规则

func (*Autonomy) ExecLocal_VotePropBoard

func (a *Autonomy) ExecLocal_VotePropBoard(payload *auty.VoteProposalBoard, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_VotePropBoard 投票提案

func (*Autonomy) ExecLocal_VotePropChange

func (a *Autonomy) ExecLocal_VotePropChange(payload *auty.VoteProposalChange, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_VotePropChange 投票提案规则

func (*Autonomy) ExecLocal_VotePropProject

func (a *Autonomy) ExecLocal_VotePropProject(payload *auty.VoteProposalProject, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_VotePropProject 投票提案项目

func (*Autonomy) ExecLocal_VotePropRule

func (a *Autonomy) ExecLocal_VotePropRule(payload *auty.VoteProposalRule, tx *types.Transaction, receiptData *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_VotePropRule 投票提案规则

func (*Autonomy) Exec_CommentProp

func (a *Autonomy) Exec_CommentProp(payload *auty.Comment, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_CommentProp 评论提案

func (*Autonomy) Exec_PropBoard

func (a *Autonomy) Exec_PropBoard(payload *auty.ProposalBoard, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_PropBoard 创建提案

func (*Autonomy) Exec_PropChange

func (a *Autonomy) Exec_PropChange(payload *auty.ProposalChange, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_PropChange 创建提案规则

func (*Autonomy) Exec_PropProject

func (a *Autonomy) Exec_PropProject(payload *auty.ProposalProject, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_PropProject 创建提案项目

func (*Autonomy) Exec_PropRule

func (a *Autonomy) Exec_PropRule(payload *auty.ProposalRule, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_PropRule 创建提案规则

func (*Autonomy) Exec_PubVotePropProject

func (a *Autonomy) Exec_PubVotePropProject(payload *auty.PubVoteProposalProject, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_PubVotePropProject 投票提案项目

func (*Autonomy) Exec_RvkPropBoard

func (a *Autonomy) Exec_RvkPropBoard(payload *auty.RevokeProposalBoard, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_RvkPropBoard 撤销提案

func (*Autonomy) Exec_RvkPropChange

func (a *Autonomy) Exec_RvkPropChange(payload *auty.RevokeProposalChange, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_RvkPropChange 撤销提案规则

func (*Autonomy) Exec_RvkPropProject

func (a *Autonomy) Exec_RvkPropProject(payload *auty.RevokeProposalProject, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_RvkPropProject 撤销提案项目

func (*Autonomy) Exec_RvkPropRule

func (a *Autonomy) Exec_RvkPropRule(payload *auty.RevokeProposalRule, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_RvkPropRule 撤销提案规则

func (*Autonomy) Exec_TmintPropBoard

func (a *Autonomy) Exec_TmintPropBoard(payload *auty.TerminateProposalBoard, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_TmintPropBoard 终止提案

func (*Autonomy) Exec_TmintPropChange

func (a *Autonomy) Exec_TmintPropChange(payload *auty.TerminateProposalChange, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_TmintPropChange 终止提案规则

func (*Autonomy) Exec_TmintPropProject

func (a *Autonomy) Exec_TmintPropProject(payload *auty.TerminateProposalProject, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_TmintPropProject 终止提案项目

func (*Autonomy) Exec_TmintPropRule

func (a *Autonomy) Exec_TmintPropRule(payload *auty.TerminateProposalRule, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_TmintPropRule 终止提案规则

func (*Autonomy) Exec_Transfer

func (a *Autonomy) Exec_Transfer(payload *auty.TransferFund, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_Transfer 资金转入自治系统合约中

func (*Autonomy) Exec_VotePropBoard

func (a *Autonomy) Exec_VotePropBoard(payload *auty.VoteProposalBoard, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_VotePropBoard 投票提案

func (*Autonomy) Exec_VotePropChange

func (a *Autonomy) Exec_VotePropChange(payload *auty.VoteProposalChange, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_VotePropChange 投票提案规则

func (*Autonomy) Exec_VotePropProject

func (a *Autonomy) Exec_VotePropProject(payload *auty.VoteProposalProject, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_VotePropProject 投票提案项目

func (*Autonomy) Exec_VotePropRule

func (a *Autonomy) Exec_VotePropRule(payload *auty.VoteProposalRule, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_VotePropRule 投票提案规则

func (*Autonomy) GetDriverName

func (u *Autonomy) GetDriverName() string

GetDriverName 获得驱动名字

func (*Autonomy) Query_GetActiveBoard

func (a *Autonomy) Query_GetActiveBoard(in *types.ReqString) (types.Message, error)

Query_GetActiveBoard 查询当前board

func (*Autonomy) Query_GetActiveRule

func (a *Autonomy) Query_GetActiveRule(in *types.ReqString) (types.Message, error)

Query_GetActiveRule 查询当前rule

func (*Autonomy) Query_GetProposalBoard

func (a *Autonomy) Query_GetProposalBoard(in *types.ReqString) (types.Message, error)

Query_GetProposalBoard 查询提案董事会

func (*Autonomy) Query_GetProposalChange

func (a *Autonomy) Query_GetProposalChange(in *types.ReqString) (types.Message, error)

Query_GetProposalChange 查询提案修改董事会成员

func (*Autonomy) Query_GetProposalProject

func (a *Autonomy) Query_GetProposalProject(in *types.ReqString) (types.Message, error)

Query_GetProposalProject 查询提案项目

func (*Autonomy) Query_GetProposalRule

func (a *Autonomy) Query_GetProposalRule(in *types.ReqString) (types.Message, error)

Query_GetProposalRule 查询提案规则

func (*Autonomy) Query_ListProposalBoard

func (a *Autonomy) Query_ListProposalBoard(in *auty.ReqQueryProposalBoard) (types.Message, error)

Query_ListProposalBoard 批量查询

func (*Autonomy) Query_ListProposalChange

func (a *Autonomy) Query_ListProposalChange(in *auty.ReqQueryProposalChange) (types.Message, error)

Query_ListProposalChange 批量查询

func (*Autonomy) Query_ListProposalComment

func (a *Autonomy) Query_ListProposalComment(in *auty.ReqQueryProposalComment) (types.Message, error)

Query_ListProposalComment 批量查询提案评论

func (*Autonomy) Query_ListProposalProject

func (a *Autonomy) Query_ListProposalProject(in *auty.ReqQueryProposalProject) (types.Message, error)

Query_ListProposalProject 批量查询

func (*Autonomy) Query_ListProposalRule

func (a *Autonomy) Query_ListProposalRule(in *auty.ReqQueryProposalRule) (types.Message, error)

Query_ListProposalRule 批量查询

type BoardRow

type BoardRow struct {
	*auty.AutonomyProposalBoard
}

BoardRow table meta 结构

func NewBoardRow

func NewBoardRow() *BoardRow

NewBoardRow 新建一个meta 结构

func (*BoardRow) CreateRow

func (r *BoardRow) CreateRow() *table.Row

CreateRow 新建数据行(注意index 数据一定也要保存到数据中,不能就保存heightindex)

func (*BoardRow) Get

func (r *BoardRow) Get(key string) ([]byte, error)

Get 按照indexName 查询 indexValue

func (*BoardRow) SetPayload

func (r *BoardRow) SetPayload(data types.Message) error

SetPayload 设置数据

type ChangeRow

type ChangeRow struct {
	*auty.AutonomyProposalChange
}

ChangeRow table meta 结构

func NewChangeRow

func NewChangeRow() *ChangeRow

NewChangeRow 新建一个meta 结构

func (*ChangeRow) CreateRow

func (r *ChangeRow) CreateRow() *table.Row

CreateRow 新建数据行(注意index 数据一定也要保存到数据中,不能就保存heightindex)

func (*ChangeRow) Get

func (r *ChangeRow) Get(key string) ([]byte, error)

Get 按照indexName 查询 indexValue

func (*ChangeRow) SetPayload

func (r *ChangeRow) SetPayload(data types.Message) error

SetPayload 设置数据

type ProjectRow

type ProjectRow struct {
	*auty.AutonomyProposalProject
}

ProjectRow table meta 结构

func NewProjectRow

func NewProjectRow() *ProjectRow

NewProjectRow 新建一个meta 结构

func (*ProjectRow) CreateRow

func (r *ProjectRow) CreateRow() *table.Row

CreateRow 新建数据行(注意index 数据一定也要保存到数据中,不能就保存heightindex)

func (*ProjectRow) Get

func (r *ProjectRow) Get(key string) ([]byte, error)

Get 按照indexName 查询 indexValue

func (*ProjectRow) SetPayload

func (r *ProjectRow) SetPayload(data types.Message) error

SetPayload 设置数据

type RuleRow

type RuleRow struct {
	*auty.AutonomyProposalRule
}

RuleRow table meta 结构

func NewRuleRow

func NewRuleRow() *RuleRow

NewRuleRow 新建一个meta 结构

func (*RuleRow) CreateRow

func (r *RuleRow) CreateRow() *table.Row

CreateRow 新建数据行(注意index 数据一定也要保存到数据中,不能就保存heightindex)

func (*RuleRow) Get

func (r *RuleRow) Get(key string) ([]byte, error)

Get 按照indexName 查询 indexValue

func (*RuleRow) SetPayload

func (r *RuleRow) SetPayload(data types.Message) error

SetPayload 设置数据

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL