common

package
v0.0.0-...-4619e39 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2022 License: Apache-2.0 Imports: 10 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthBlock        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowBlock          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupBlock = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthContract        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowContract          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupContract = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthMilkyway        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowMilkyway          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupMilkyway = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthRequest        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowRequest          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupRequest = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthResult        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowResult          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupResult = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthRwset        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowRwset          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupRwset = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthTransaction        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTransaction          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTransaction = fmt.Errorf("proto: unexpected end of group")
)
View Source
var BlockType_name = map[int32]string{
	0: "NORMAL_BLOCK",
	1: "CONFIG_BLOCK",
	2: "CONTRACT_MGR_BLOCK",
	4: "HAS_COINBASE",
}
View Source
var BlockType_value = map[string]int32{
	"NORMAL_BLOCK":       0,
	"CONFIG_BLOCK":       1,
	"CONTRACT_MGR_BLOCK": 2,
	"HAS_COINBASE":       4,
}
View Source
var ContractStatus_name = map[int32]string{
	0: "NORMAL",
	1: "FROZEN",
	2: "REVOKED",
}
View Source
var ContractStatus_value = map[string]int32{
	"NORMAL":  0,
	"FROZEN":  1,
	"REVOKED": 2,
}
View Source
var FilterExtensionType_name = map[int32]string{
	0: "FETDefault",
	1: "FETTimestamp",
}
View Source
var FilterExtensionType_value = map[string]int32{
	"FETDefault":   0,
	"FETTimestamp": 1,
}
View Source
var KeyType_name = map[int32]string{
	0: "KTDefault",
	1: "KTTimestampKey",
}
View Source
var KeyType_value = map[string]int32{
	"KTDefault":      0,
	"KTTimestampKey": 1,
}
View Source
var RuleType_name = map[int32]string{
	0: "AbsoluteExpireTime",
}
View Source
var RuleType_value = map[string]int32{
	"AbsoluteExpireTime": 0,
}
View Source
var RuntimeType_name = map[int32]string{
	0: "INVALID",
	1: "NATIVE",
	2: "WASMER",
	3: "WXVM",
	4: "GASM",
	5: "EVM",
	6: "DOCKER_GO",
	7: "DOCKER_JAVA",
}
View Source
var RuntimeType_value = map[string]int32{
	"INVALID":     0,
	"NATIVE":      1,
	"WASMER":      2,
	"WXVM":        3,
	"GASM":        4,
	"EVM":         5,
	"DOCKER_GO":   6,
	"DOCKER_JAVA": 7,
}
View Source
var SerializeIntervalType_name = map[int32]string{
	0: "Height",
	1: "Timed",
	2: "Exit",
}
View Source
var SerializeIntervalType_value = map[string]int32{
	"Height": 0,
	"Timed":  1,
	"Exit":   2,
}
View Source
var TxStatusCode_name = map[int32]string{
	0:  "SUCCESS",
	1:  "TIMEOUT",
	2:  "INVALID_PARAMETER",
	3:  "NO_PERMISSION",
	4:  "CONTRACT_FAIL",
	5:  "INTERNAL_ERROR",
	10: "INVALID_CONTRACT_TRANSACTION_TYPE",
	11: "INVALID_CONTRACT_PARAMETER_CONTRACT_NAME",
	12: "INVALID_CONTRACT_PARAMETER_METHOD",
	13: "INVALID_CONTRACT_PARAMETER_INIT_METHOD",
	14: "INVALID_CONTRACT_PARAMETER_UPGRADE_METHOD",
	15: "INVALID_CONTRACT_PARAMETER_BYTE_CODE",
	16: "INVALID_CONTRACT_PARAMETER_RUNTIME_TYPE",
	17: "INVALID_CONTRACT_PARAMETER_VERSION",
	20: "GET_FROM_TX_CONTEXT_FAILED",
	21: "PUT_INTO_TX_CONTEXT_FAILED",
	22: "CONTRACT_VERSION_EXIST_FAILED",
	23: "CONTRACT_VERSION_NOT_EXIST_FAILED",
	24: "CONTRACT_BYTE_CODE_NOT_EXIST_FAILED",
	25: "MARSHAL_SENDER_FAILED",
	26: "INVOKE_INIT_METHOD_FAILED",
	27: "INVOKE_UPGRADE_METHOD_FAILED",
	28: "CREATE_RUNTIME_INSTANCE_FAILED",
	29: "UNMARSHAL_CREATOR_FAILED",
	30: "UNMARSHAL_SENDER_FAILED",
	31: "GET_SENDER_PK_FAILED",
	32: "GET_CREATOR_PK_FAILED",
	33: "GET_CREATOR_FAILED",
	34: "GET_CREATOR_CERT_FAILED",
	35: "GET_SENDER_CERT_FAILED",
	36: "CONTRACT_FREEZE_FAILED",
	37: "CONTRACT_TOO_DEEP_FAILED",
	38: "CONTRACT_REVOKE_FAILED",
	39: "CONTRACT_INVOKE_METHOD_FAILED",
	40: "ARCHIVED_TX",
	41: "ARCHIVED_BLOCK",
	42: "GAS_BALANCE_NOT_ENOUGH_FAILED",
}
View Source
var TxStatusCode_value = map[string]int32{
	"SUCCESS":                           0,
	"TIMEOUT":                           1,
	"INVALID_PARAMETER":                 2,
	"NO_PERMISSION":                     3,
	"CONTRACT_FAIL":                     4,
	"INTERNAL_ERROR":                    5,
	"INVALID_CONTRACT_TRANSACTION_TYPE": 10,
	"INVALID_CONTRACT_PARAMETER_CONTRACT_NAME":  11,
	"INVALID_CONTRACT_PARAMETER_METHOD":         12,
	"INVALID_CONTRACT_PARAMETER_INIT_METHOD":    13,
	"INVALID_CONTRACT_PARAMETER_UPGRADE_METHOD": 14,
	"INVALID_CONTRACT_PARAMETER_BYTE_CODE":      15,
	"INVALID_CONTRACT_PARAMETER_RUNTIME_TYPE":   16,
	"INVALID_CONTRACT_PARAMETER_VERSION":        17,
	"GET_FROM_TX_CONTEXT_FAILED":                20,
	"PUT_INTO_TX_CONTEXT_FAILED":                21,
	"CONTRACT_VERSION_EXIST_FAILED":             22,
	"CONTRACT_VERSION_NOT_EXIST_FAILED":         23,
	"CONTRACT_BYTE_CODE_NOT_EXIST_FAILED":       24,
	"MARSHAL_SENDER_FAILED":                     25,
	"INVOKE_INIT_METHOD_FAILED":                 26,
	"INVOKE_UPGRADE_METHOD_FAILED":              27,
	"CREATE_RUNTIME_INSTANCE_FAILED":            28,
	"UNMARSHAL_CREATOR_FAILED":                  29,
	"UNMARSHAL_SENDER_FAILED":                   30,
	"GET_SENDER_PK_FAILED":                      31,
	"GET_CREATOR_PK_FAILED":                     32,
	"GET_CREATOR_FAILED":                        33,
	"GET_CREATOR_CERT_FAILED":                   34,
	"GET_SENDER_CERT_FAILED":                    35,
	"CONTRACT_FREEZE_FAILED":                    36,
	"CONTRACT_TOO_DEEP_FAILED":                  37,
	"CONTRACT_REVOKE_FAILED":                    38,
	"CONTRACT_INVOKE_METHOD_FAILED":             39,
	"ARCHIVED_TX":                               40,
	"ARCHIVED_BLOCK":                            41,
	"GAS_BALANCE_NOT_ENOUGH_FAILED":             42,
}
View Source
var TxType_name = map[int32]string{
	0: "INVOKE_CONTRACT",
	1: "QUERY_CONTRACT",
	2: "SUBSCRIBE",
	3: "ARCHIVE",
}
View Source
var TxType_value = map[string]int32{
	"INVOKE_CONTRACT": 0,
	"QUERY_CONTRACT":  1,
	"SUBSCRIBE":       2,
	"ARCHIVE":         3,
}

Functions

func GetTxKeyWith

func GetTxKeyWith(propose []byte, blockHeight uint64) string

Types

type AdditionalData

type AdditionalData struct {
	// 带有键值映射类型的额外数据,在哈希计算中排除
	ExtraData map[string][]byte `` /* 176-byte string literal not displayed */
}

区块附加数据

func (*AdditionalData) Descriptor

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

func (*AdditionalData) GetExtraData

func (m *AdditionalData) GetExtraData() map[string][]byte

func (*AdditionalData) Marshal

func (m *AdditionalData) Marshal() (dAtA []byte, err error)

func (*AdditionalData) MarshalTo

func (m *AdditionalData) MarshalTo(dAtA []byte) (int, error)

func (*AdditionalData) MarshalToSizedBuffer

func (m *AdditionalData) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AdditionalData) ProtoMessage

func (*AdditionalData) ProtoMessage()

func (*AdditionalData) Reset

func (m *AdditionalData) Reset()

func (*AdditionalData) Size

func (m *AdditionalData) Size() (n int)

func (*AdditionalData) String

func (m *AdditionalData) String() string

func (*AdditionalData) Unmarshal

func (m *AdditionalData) Unmarshal(dAtA []byte) error

func (*AdditionalData) XXX_DiscardUnknown

func (m *AdditionalData) XXX_DiscardUnknown()

func (*AdditionalData) XXX_Marshal

func (m *AdditionalData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AdditionalData) XXX_Merge

func (m *AdditionalData) XXX_Merge(src proto.Message)

func (*AdditionalData) XXX_Size

func (m *AdditionalData) XXX_Size() int

func (*AdditionalData) XXX_Unmarshal

func (m *AdditionalData) XXX_Unmarshal(b []byte) error

type AliasCertInfo

type AliasCertInfo struct {
	Hash        string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
	Cert        []byte `protobuf:"bytes,2,opt,name=cert,proto3" json:"cert,omitempty"`
	BlockHeight uint64 `protobuf:"varint,3,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
}

证书别名信息

func (*AliasCertInfo) Descriptor

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

func (*AliasCertInfo) GetBlockHeight

func (m *AliasCertInfo) GetBlockHeight() uint64

func (*AliasCertInfo) GetCert

func (m *AliasCertInfo) GetCert() []byte

func (*AliasCertInfo) GetHash

func (m *AliasCertInfo) GetHash() string

func (*AliasCertInfo) Marshal

func (m *AliasCertInfo) Marshal() (dAtA []byte, err error)

func (*AliasCertInfo) MarshalTo

func (m *AliasCertInfo) MarshalTo(dAtA []byte) (int, error)

func (*AliasCertInfo) MarshalToSizedBuffer

func (m *AliasCertInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AliasCertInfo) ProtoMessage

func (*AliasCertInfo) ProtoMessage()

func (*AliasCertInfo) Reset

func (m *AliasCertInfo) Reset()

func (*AliasCertInfo) Size

func (m *AliasCertInfo) Size() (n int)

func (*AliasCertInfo) String

func (m *AliasCertInfo) String() string

func (*AliasCertInfo) Unmarshal

func (m *AliasCertInfo) Unmarshal(dAtA []byte) error

func (*AliasCertInfo) XXX_DiscardUnknown

func (m *AliasCertInfo) XXX_DiscardUnknown()

func (*AliasCertInfo) XXX_Marshal

func (m *AliasCertInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AliasCertInfo) XXX_Merge

func (m *AliasCertInfo) XXX_Merge(src proto.Message)

func (*AliasCertInfo) XXX_Size

func (m *AliasCertInfo) XXX_Size() int

func (*AliasCertInfo) XXX_Unmarshal

func (m *AliasCertInfo) XXX_Unmarshal(b []byte) error

type AliasInfo

type AliasInfo struct {
	Alias    string           `protobuf:"bytes,1,opt,name=alias,proto3" json:"alias,omitempty"`
	NowCert  *AliasCertInfo   `protobuf:"bytes,2,opt,name=now_cert,json=nowCert,proto3" json:"now_cert,omitempty"`
	HisCerts []*AliasCertInfo `protobuf:"bytes,3,rep,name=his_certs,json=hisCerts,proto3" json:"his_certs,omitempty"`
}

别名信息

func (*AliasInfo) Descriptor

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

func (*AliasInfo) GetAlias

func (m *AliasInfo) GetAlias() string

func (*AliasInfo) GetHisCerts

func (m *AliasInfo) GetHisCerts() []*AliasCertInfo

func (*AliasInfo) GetNowCert

func (m *AliasInfo) GetNowCert() *AliasCertInfo

func (*AliasInfo) Marshal

func (m *AliasInfo) Marshal() (dAtA []byte, err error)

func (*AliasInfo) MarshalTo

func (m *AliasInfo) MarshalTo(dAtA []byte) (int, error)

func (*AliasInfo) MarshalToSizedBuffer

func (m *AliasInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AliasInfo) ProtoMessage

func (*AliasInfo) ProtoMessage()

func (*AliasInfo) Reset

func (m *AliasInfo) Reset()

func (*AliasInfo) Size

func (m *AliasInfo) Size() (n int)

func (*AliasInfo) String

func (m *AliasInfo) String() string

func (*AliasInfo) Unmarshal

func (m *AliasInfo) Unmarshal(dAtA []byte) error

func (*AliasInfo) XXX_DiscardUnknown

func (m *AliasInfo) XXX_DiscardUnknown()

func (*AliasInfo) XXX_Marshal

func (m *AliasInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AliasInfo) XXX_Merge

func (m *AliasInfo) XXX_Merge(src proto.Message)

func (*AliasInfo) XXX_Size

func (m *AliasInfo) XXX_Size() int

func (*AliasInfo) XXX_Unmarshal

func (m *AliasInfo) XXX_Unmarshal(b []byte) error

type AliasInfos

type AliasInfos struct {
	AliasInfos []*AliasInfo `protobuf:"bytes,1,rep,name=alias_infos,json=aliasInfos,proto3" json:"alias_infos,omitempty"`
}

别名信息集合

func (*AliasInfos) Descriptor

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

func (*AliasInfos) GetAliasInfos

func (m *AliasInfos) GetAliasInfos() []*AliasInfo

func (*AliasInfos) Marshal

func (m *AliasInfos) Marshal() (dAtA []byte, err error)

func (*AliasInfos) MarshalTo

func (m *AliasInfos) MarshalTo(dAtA []byte) (int, error)

func (*AliasInfos) MarshalToSizedBuffer

func (m *AliasInfos) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AliasInfos) ProtoMessage

func (*AliasInfos) ProtoMessage()

func (*AliasInfos) Reset

func (m *AliasInfos) Reset()

func (*AliasInfos) Size

func (m *AliasInfos) Size() (n int)

func (*AliasInfos) String

func (m *AliasInfos) String() string

func (*AliasInfos) Unmarshal

func (m *AliasInfos) Unmarshal(dAtA []byte) error

func (*AliasInfos) XXX_DiscardUnknown

func (m *AliasInfos) XXX_DiscardUnknown()

func (*AliasInfos) XXX_Marshal

func (m *AliasInfos) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AliasInfos) XXX_Merge

func (m *AliasInfos) XXX_Merge(src proto.Message)

func (*AliasInfos) XXX_Size

func (m *AliasInfos) XXX_Size() int

func (*AliasInfos) XXX_Unmarshal

func (m *AliasInfos) XXX_Unmarshal(b []byte) error

type Block

type Block struct {
	// 块头
	Header *BlockHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
	// 区块内交易的执行顺序,由提议者生成
	Dag *DAG `protobuf:"bytes,2,opt,name=dag,proto3" json:"dag,omitempty"`
	// 该区块中的交易列表
	Txs []*Transaction `protobuf:"bytes,3,rep,name=txs,proto3" json:"txs,omitempty"`
	// 存储当前区块的投票信息,不包含在区块哈希值计算中
	AdditionalData *AdditionalData `protobuf:"bytes,4,opt,name=additional_data,json=additionalData,proto3" json:"additional_data,omitempty"`
}

块定义

func (*Block) Descriptor

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

func (*Block) GetAdditionalData

func (m *Block) GetAdditionalData() *AdditionalData

func (*Block) GetBlockHashStr

func (b *Block) GetBlockHashStr() string

func (*Block) GetDag

func (m *Block) GetDag() *DAG

func (*Block) GetHeader

func (m *Block) GetHeader() *BlockHeader

func (*Block) GetTimestamp

func (b *Block) GetTimestamp() time.Time

func (*Block) GetTxKey

func (b *Block) GetTxKey() string

GetTxKey get transaction key

func (*Block) GetTxs

func (m *Block) GetTxs() []*Transaction

func (*Block) Hash

func (b *Block) Hash() []byte

func (*Block) Marshal

func (m *Block) Marshal() (dAtA []byte, err error)

func (*Block) MarshalTo

func (m *Block) MarshalTo(dAtA []byte) (int, error)

func (*Block) MarshalToSizedBuffer

func (m *Block) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Block) ProtoMessage

func (*Block) ProtoMessage()

func (*Block) Reset

func (m *Block) Reset()

func (*Block) Size

func (m *Block) Size() (n int)

func (*Block) String

func (m *Block) String() string

func (*Block) Unmarshal

func (m *Block) Unmarshal(dAtA []byte) error

func (*Block) XXX_DiscardUnknown

func (m *Block) XXX_DiscardUnknown()

func (*Block) XXX_Marshal

func (m *Block) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Block) XXX_Merge

func (m *Block) XXX_Merge(src proto.Message)

func (*Block) XXX_Size

func (m *Block) XXX_Size() int

func (*Block) XXX_Unmarshal

func (m *Block) XXX_Unmarshal(b []byte) error

type BlockHeader

type BlockHeader struct {
	// 块版本
	BlockVersion uint32 `protobuf:"varint,1,opt,name=block_version,json=blockVersion,proto3" json:"block_version,omitempty"`
	// 配置块或普通块或其他
	BlockType BlockType `protobuf:"varint,2,opt,name=block_type,json=blockType,proto3,enum=common.BlockType" json:"block_type,omitempty"`
	// 区块链标识符
	ChainId string `protobuf:"bytes,3,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	// 块高
	BlockHeight uint64 `protobuf:"varint,4,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	// 块哈希
	BlockHash []byte `protobuf:"bytes,5,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"`
	// 前一个区块哈希
	PreBlockHash []byte `protobuf:"bytes,6,opt,name=pre_block_hash,json=preBlockHash,proto3" json:"pre_block_hash,omitempty"`
	// 前一个配置块高度,用于跟踪和检查链配置是否有效
	PreConfHeight uint64 `protobuf:"varint,7,opt,name=pre_conf_height,json=preConfHeight,proto3" json:"pre_conf_height,omitempty"`
	// 交易次数
	TxCount uint32 `protobuf:"varint,8,opt,name=tx_count,json=txCount,proto3" json:"tx_count,omitempty"`
	// 用于验证此交易存在的交易的默克尔根
	TxRoot []byte `protobuf:"bytes,9,opt,name=tx_root,json=txRoot,proto3" json:"tx_root,omitempty"`
	// 保存DAG特征摘要,对序列化DAG的Pb序列化hash后的DAG进行hash
	DagHash []byte `protobuf:"bytes,10,opt,name=dag_hash,json=dagHash,proto3" json:"dag_hash,omitempty"`
	// 区块中每笔交易的结果中read_write_set_digest
	// 生成的Merkle树的根哈希,用于验证区块的读写集
	RwSetRoot []byte `protobuf:"bytes,11,opt,name=rw_set_root,json=rwSetRoot,proto3" json:"rw_set_root,omitempty"`
	// 区块的时间戳
	BlockTimestamp int64 `protobuf:"varint,12,opt,name=block_timestamp,json=blockTimestamp,proto3" json:"block_timestamp,omitempty"`
	// 共识参数
	// 用于存储信息,包含在区块哈希计算中
	ConsensusArgs []byte `protobuf:"bytes,13,opt,name=consensus_args,json=consensusArgs,proto3" json:"consensus_args,omitempty"`
	// 提议节点标识符
	Proposer *accesscontrol.Member `protobuf:"bytes,14,opt,name=proposer,proto3" json:"proposer,omitempty"`
	// 提议人签名
	Signature []byte `protobuf:"bytes,15,opt,name=signature,proto3" json:"signature,omitempty"`
}

块头

func (*BlockHeader) Descriptor

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

func (*BlockHeader) GetBlockHash

func (m *BlockHeader) GetBlockHash() []byte

func (*BlockHeader) GetBlockHeight

func (m *BlockHeader) GetBlockHeight() uint64

func (*BlockHeader) GetBlockTimestamp

func (m *BlockHeader) GetBlockTimestamp() int64

func (*BlockHeader) GetBlockType

func (m *BlockHeader) GetBlockType() BlockType

func (*BlockHeader) GetBlockVersion

func (m *BlockHeader) GetBlockVersion() uint32

func (*BlockHeader) GetChainId

func (m *BlockHeader) GetChainId() string

func (*BlockHeader) GetConsensusArgs

func (m *BlockHeader) GetConsensusArgs() []byte

func (*BlockHeader) GetDagHash

func (m *BlockHeader) GetDagHash() []byte

func (*BlockHeader) GetPreBlockHash

func (m *BlockHeader) GetPreBlockHash() []byte

func (*BlockHeader) GetPreConfHeight

func (m *BlockHeader) GetPreConfHeight() uint64

func (*BlockHeader) GetProposer

func (m *BlockHeader) GetProposer() *accesscontrol.Member

func (*BlockHeader) GetRwSetRoot

func (m *BlockHeader) GetRwSetRoot() []byte

func (*BlockHeader) GetSignature

func (m *BlockHeader) GetSignature() []byte

func (*BlockHeader) GetTxCount

func (m *BlockHeader) GetTxCount() uint32

func (*BlockHeader) GetTxRoot

func (m *BlockHeader) GetTxRoot() []byte

func (*BlockHeader) Marshal

func (m *BlockHeader) Marshal() (dAtA []byte, err error)

func (*BlockHeader) MarshalTo

func (m *BlockHeader) MarshalTo(dAtA []byte) (int, error)

func (*BlockHeader) MarshalToSizedBuffer

func (m *BlockHeader) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BlockHeader) ProtoMessage

func (*BlockHeader) ProtoMessage()

func (*BlockHeader) Reset

func (m *BlockHeader) Reset()

func (*BlockHeader) Size

func (m *BlockHeader) Size() (n int)

func (*BlockHeader) String

func (m *BlockHeader) String() string

func (*BlockHeader) Unmarshal

func (m *BlockHeader) Unmarshal(dAtA []byte) error

func (*BlockHeader) XXX_DiscardUnknown

func (m *BlockHeader) XXX_DiscardUnknown()

func (*BlockHeader) XXX_Marshal

func (m *BlockHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BlockHeader) XXX_Merge

func (m *BlockHeader) XXX_Merge(src proto.Message)

func (*BlockHeader) XXX_Size

func (m *BlockHeader) XXX_Size() int

func (*BlockHeader) XXX_Unmarshal

func (m *BlockHeader) XXX_Unmarshal(b []byte) error

type BlockHeightSerializeIntervalConfig

type BlockHeightSerializeIntervalConfig struct {
	Interval uint64 `protobuf:"varint,1,opt,name=interval,proto3" json:"interval,omitempty"`
}

区块高度序列化间隔

func (*BlockHeightSerializeIntervalConfig) Descriptor

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

func (*BlockHeightSerializeIntervalConfig) GetInterval

func (m *BlockHeightSerializeIntervalConfig) GetInterval() uint64

func (*BlockHeightSerializeIntervalConfig) Marshal

func (m *BlockHeightSerializeIntervalConfig) Marshal() (dAtA []byte, err error)

func (*BlockHeightSerializeIntervalConfig) MarshalTo

func (m *BlockHeightSerializeIntervalConfig) MarshalTo(dAtA []byte) (int, error)

func (*BlockHeightSerializeIntervalConfig) MarshalToSizedBuffer

func (m *BlockHeightSerializeIntervalConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BlockHeightSerializeIntervalConfig) ProtoMessage

func (*BlockHeightSerializeIntervalConfig) ProtoMessage()

func (*BlockHeightSerializeIntervalConfig) Reset

func (*BlockHeightSerializeIntervalConfig) Size

func (*BlockHeightSerializeIntervalConfig) String

func (*BlockHeightSerializeIntervalConfig) Unmarshal

func (m *BlockHeightSerializeIntervalConfig) Unmarshal(dAtA []byte) error

func (*BlockHeightSerializeIntervalConfig) XXX_DiscardUnknown

func (m *BlockHeightSerializeIntervalConfig) XXX_DiscardUnknown()

func (*BlockHeightSerializeIntervalConfig) XXX_Marshal

func (m *BlockHeightSerializeIntervalConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BlockHeightSerializeIntervalConfig) XXX_Merge

func (*BlockHeightSerializeIntervalConfig) XXX_Size

func (*BlockHeightSerializeIntervalConfig) XXX_Unmarshal

func (m *BlockHeightSerializeIntervalConfig) XXX_Unmarshal(b []byte) error

type BlockInfo

type BlockInfo struct {
	// 区块
	Block *Block `protobuf:"bytes,1,opt,name=block,proto3" json:"block,omitempty"`
	// 区块中包含的事务对应的读/写集合列表
	RwsetList []*TxRWSet `protobuf:"bytes,2,rep,name=rwset_list,json=rwsetList,proto3" json:"rwset_list,omitempty"`
}

块信息

func (*BlockInfo) Descriptor

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

func (*BlockInfo) GetBlock

func (m *BlockInfo) GetBlock() *Block

func (*BlockInfo) GetRwsetList

func (m *BlockInfo) GetRwsetList() []*TxRWSet

func (*BlockInfo) Marshal

func (m *BlockInfo) Marshal() (dAtA []byte, err error)

func (*BlockInfo) MarshalTo

func (m *BlockInfo) MarshalTo(dAtA []byte) (int, error)

func (*BlockInfo) MarshalToSizedBuffer

func (m *BlockInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BlockInfo) ProtoMessage

func (*BlockInfo) ProtoMessage()

func (*BlockInfo) Reset

func (m *BlockInfo) Reset()

func (*BlockInfo) Size

func (m *BlockInfo) Size() (n int)

func (*BlockInfo) String

func (m *BlockInfo) String() string

func (*BlockInfo) Unmarshal

func (m *BlockInfo) Unmarshal(dAtA []byte) error

func (*BlockInfo) XXX_DiscardUnknown

func (m *BlockInfo) XXX_DiscardUnknown()

func (*BlockInfo) XXX_Marshal

func (m *BlockInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BlockInfo) XXX_Merge

func (m *BlockInfo) XXX_Merge(src proto.Message)

func (*BlockInfo) XXX_Size

func (m *BlockInfo) XXX_Size() int

func (*BlockInfo) XXX_Unmarshal

func (m *BlockInfo) XXX_Unmarshal(b []byte) error

type BlockType

type BlockType int32

BlockType 指定块包 txs 类型

const (
	// 普通区块,将多笔交易打包成一个区块
	BlockType_NORMAL_BLOCK BlockType = 0
	// 配置区块,此区块中仅包含 1 条链配置更新 tx
	BlockType_CONFIG_BLOCK BlockType = 1
	// Sql Contract init or upgrade 区块,该区块中仅包含 1 个 sql contract init 或 upgrade tx
	BlockType_CONTRACT_MGR_BLOCK BlockType = 2
	// block.Txs[0] 是 coinbase tx
	BlockType_HAS_COINBASE BlockType = 4
)

func (BlockType) EnumDescriptor

func (BlockType) EnumDescriptor() ([]byte, []int)

func (BlockType) String

func (x BlockType) String() string

type CertInfo

type CertInfo struct {
	// 证书哈希
	Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
	// 证书内容
	Cert []byte `protobuf:"bytes,2,opt,name=cert,proto3" json:"cert,omitempty"`
}

证书信息

func (*CertInfo) Descriptor

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

func (*CertInfo) GetCert

func (m *CertInfo) GetCert() []byte

func (*CertInfo) GetHash

func (m *CertInfo) GetHash() string

func (*CertInfo) Marshal

func (m *CertInfo) Marshal() (dAtA []byte, err error)

func (*CertInfo) MarshalTo

func (m *CertInfo) MarshalTo(dAtA []byte) (int, error)

func (*CertInfo) MarshalToSizedBuffer

func (m *CertInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*CertInfo) ProtoMessage

func (*CertInfo) ProtoMessage()

func (*CertInfo) Reset

func (m *CertInfo) Reset()

func (*CertInfo) Size

func (m *CertInfo) Size() (n int)

func (*CertInfo) String

func (m *CertInfo) String() string

func (*CertInfo) Unmarshal

func (m *CertInfo) Unmarshal(dAtA []byte) error

func (*CertInfo) XXX_DiscardUnknown

func (m *CertInfo) XXX_DiscardUnknown()

func (*CertInfo) XXX_Marshal

func (m *CertInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CertInfo) XXX_Merge

func (m *CertInfo) XXX_Merge(src proto.Message)

func (*CertInfo) XXX_Size

func (m *CertInfo) XXX_Size() int

func (*CertInfo) XXX_Unmarshal

func (m *CertInfo) XXX_Unmarshal(b []byte) error

type CertInfos

type CertInfos struct {
	CertInfos []*CertInfo `protobuf:"bytes,1,rep,name=cert_infos,json=certInfos,proto3" json:"cert_infos,omitempty"`
}

证书集合

func (*CertInfos) Descriptor

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

func (*CertInfos) GetCertInfos

func (m *CertInfos) GetCertInfos() []*CertInfo

func (*CertInfos) Marshal

func (m *CertInfos) Marshal() (dAtA []byte, err error)

func (*CertInfos) MarshalTo

func (m *CertInfos) MarshalTo(dAtA []byte) (int, error)

func (*CertInfos) MarshalToSizedBuffer

func (m *CertInfos) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*CertInfos) ProtoMessage

func (*CertInfos) ProtoMessage()

func (*CertInfos) Reset

func (m *CertInfos) Reset()

func (*CertInfos) Size

func (m *CertInfos) Size() (n int)

func (*CertInfos) String

func (m *CertInfos) String() string

func (*CertInfos) Unmarshal

func (m *CertInfos) Unmarshal(dAtA []byte) error

func (*CertInfos) XXX_DiscardUnknown

func (m *CertInfos) XXX_DiscardUnknown()

func (*CertInfos) XXX_Marshal

func (m *CertInfos) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CertInfos) XXX_Merge

func (m *CertInfos) XXX_Merge(src proto.Message)

func (*CertInfos) XXX_Size

func (m *CertInfos) XXX_Size() int

func (*CertInfos) XXX_Unmarshal

func (m *CertInfos) XXX_Unmarshal(b []byte) error

type Contract

type Contract struct {
	// 智能合约名称,由合约创建者设置,可以有多个版本
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// 智能合约版本,由合约创建者设置,名称+版本唯一
	Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
	// 智能合约运行时类型,由合约创建者设置
	RuntimeType RuntimeType `protobuf:"varint,3,opt,name=runtime_type,json=runtimeType,proto3,enum=common.RuntimeType" json:"runtime_type,omitempty"`
	// 合同状态
	Status ContractStatus `protobuf:"varint,4,opt,name=status,proto3,enum=common.ContractStatus" json:"status,omitempty"`
	// 合约创建者身份标识
	Creator *accesscontrol.MemberFull `protobuf:"bytes,5,opt,name=creator,proto3" json:"creator,omitempty"`
}

func (*Contract) Descriptor

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

func (*Contract) GetCreator

func (m *Contract) GetCreator() *accesscontrol.MemberFull

func (*Contract) GetName

func (m *Contract) GetName() string

func (*Contract) GetRuntimeType

func (m *Contract) GetRuntimeType() RuntimeType

func (*Contract) GetStatus

func (m *Contract) GetStatus() ContractStatus

func (*Contract) GetVersion

func (m *Contract) GetVersion() string

func (*Contract) Marshal

func (m *Contract) Marshal() (dAtA []byte, err error)

func (*Contract) MarshalTo

func (m *Contract) MarshalTo(dAtA []byte) (int, error)

func (*Contract) MarshalToSizedBuffer

func (m *Contract) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Contract) ProtoMessage

func (*Contract) ProtoMessage()

func (*Contract) Reset

func (m *Contract) Reset()

func (*Contract) Size

func (m *Contract) Size() (n int)

func (*Contract) String

func (m *Contract) String() string

func (*Contract) Unmarshal

func (m *Contract) Unmarshal(dAtA []byte) error

func (*Contract) XXX_DiscardUnknown

func (m *Contract) XXX_DiscardUnknown()

func (*Contract) XXX_Marshal

func (m *Contract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Contract) XXX_Merge

func (m *Contract) XXX_Merge(src proto.Message)

func (*Contract) XXX_Size

func (m *Contract) XXX_Size() int

func (*Contract) XXX_Unmarshal

func (m *Contract) XXX_Unmarshal(b []byte) error

type ContractEvent

type ContractEvent struct {
	Topic           string   `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
	TxId            string   `protobuf:"bytes,2,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"`
	ContractName    string   `protobuf:"bytes,3,opt,name=contract_name,json=contractName,proto3" json:"contract_name,omitempty"`
	ContractVersion string   `protobuf:"bytes,4,opt,name=contract_version,json=contractVersion,proto3" json:"contract_version,omitempty"`
	EventData       []string `protobuf:"bytes,5,rep,name=event_data,json=eventData,proto3" json:"event_data,omitempty"`
}

区块链中保存的合约事件

func (*ContractEvent) Descriptor

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

func (*ContractEvent) GetContractName

func (m *ContractEvent) GetContractName() string

func (*ContractEvent) GetContractVersion

func (m *ContractEvent) GetContractVersion() string

func (*ContractEvent) GetEventData

func (m *ContractEvent) GetEventData() []string

func (*ContractEvent) GetTopic

func (m *ContractEvent) GetTopic() string

func (*ContractEvent) GetTxId

func (m *ContractEvent) GetTxId() string

func (*ContractEvent) Marshal

func (m *ContractEvent) Marshal() (dAtA []byte, err error)

func (*ContractEvent) MarshalTo

func (m *ContractEvent) MarshalTo(dAtA []byte) (int, error)

func (*ContractEvent) MarshalToSizedBuffer

func (m *ContractEvent) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractEvent) ProtoMessage

func (*ContractEvent) ProtoMessage()

func (*ContractEvent) Reset

func (m *ContractEvent) Reset()

func (*ContractEvent) Size

func (m *ContractEvent) Size() (n int)

func (*ContractEvent) String

func (m *ContractEvent) String() string

func (*ContractEvent) Unmarshal

func (m *ContractEvent) Unmarshal(dAtA []byte) error

func (*ContractEvent) XXX_DiscardUnknown

func (m *ContractEvent) XXX_DiscardUnknown()

func (*ContractEvent) XXX_Marshal

func (m *ContractEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractEvent) XXX_Merge

func (m *ContractEvent) XXX_Merge(src proto.Message)

func (*ContractEvent) XXX_Size

func (m *ContractEvent) XXX_Size() int

func (*ContractEvent) XXX_Unmarshal

func (m *ContractEvent) XXX_Unmarshal(b []byte) error

type ContractEventInfo

type ContractEventInfo struct {
	BlockHeight     uint64   `protobuf:"varint,1,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	ChainId         string   `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	Topic           string   `protobuf:"bytes,3,opt,name=topic,proto3" json:"topic,omitempty"`
	TxId            string   `protobuf:"bytes,4,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"`
	EventIndex      uint32   `protobuf:"varint,5,opt,name=event_index,json=eventIndex,proto3" json:"event_index,omitempty"`
	ContractName    string   `protobuf:"bytes,6,opt,name=contract_name,json=contractName,proto3" json:"contract_name,omitempty"`
	ContractVersion string   `protobuf:"bytes,7,opt,name=contract_version,json=contractVersion,proto3" json:"contract_version,omitempty"`
	EventData       []string `protobuf:"bytes,8,rep,name=event_data,json=eventData,proto3" json:"event_data,omitempty"`
}

发布给用户的合约事件

func (*ContractEventInfo) Descriptor

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

func (*ContractEventInfo) GetBlockHeight

func (m *ContractEventInfo) GetBlockHeight() uint64

func (*ContractEventInfo) GetChainId

func (m *ContractEventInfo) GetChainId() string

func (*ContractEventInfo) GetContractName

func (m *ContractEventInfo) GetContractName() string

func (*ContractEventInfo) GetContractVersion

func (m *ContractEventInfo) GetContractVersion() string

func (*ContractEventInfo) GetEventData

func (m *ContractEventInfo) GetEventData() []string

func (*ContractEventInfo) GetEventIndex

func (m *ContractEventInfo) GetEventIndex() uint32

func (*ContractEventInfo) GetTopic

func (m *ContractEventInfo) GetTopic() string

func (*ContractEventInfo) GetTxId

func (m *ContractEventInfo) GetTxId() string

func (*ContractEventInfo) Marshal

func (m *ContractEventInfo) Marshal() (dAtA []byte, err error)

func (*ContractEventInfo) MarshalTo

func (m *ContractEventInfo) MarshalTo(dAtA []byte) (int, error)

func (*ContractEventInfo) MarshalToSizedBuffer

func (m *ContractEventInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractEventInfo) ProtoMessage

func (*ContractEventInfo) ProtoMessage()

func (*ContractEventInfo) Reset

func (m *ContractEventInfo) Reset()

func (*ContractEventInfo) Size

func (m *ContractEventInfo) Size() (n int)

func (*ContractEventInfo) String

func (m *ContractEventInfo) String() string

func (*ContractEventInfo) Unmarshal

func (m *ContractEventInfo) Unmarshal(dAtA []byte) error

func (*ContractEventInfo) XXX_DiscardUnknown

func (m *ContractEventInfo) XXX_DiscardUnknown()

func (*ContractEventInfo) XXX_Marshal

func (m *ContractEventInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractEventInfo) XXX_Merge

func (m *ContractEventInfo) XXX_Merge(src proto.Message)

func (*ContractEventInfo) XXX_Size

func (m *ContractEventInfo) XXX_Size() int

func (*ContractEventInfo) XXX_Unmarshal

func (m *ContractEventInfo) XXX_Unmarshal(b []byte) error

type ContractEventInfoList

type ContractEventInfoList struct {
	ContractEvents []*ContractEventInfo `protobuf:"bytes,1,rep,name=contract_events,json=contractEvents,proto3" json:"contract_events,omitempty"`
}

发布给用户的合约事件列表

func (*ContractEventInfoList) Descriptor

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

func (*ContractEventInfoList) GetContractEvents

func (m *ContractEventInfoList) GetContractEvents() []*ContractEventInfo

func (*ContractEventInfoList) Marshal

func (m *ContractEventInfoList) Marshal() (dAtA []byte, err error)

func (*ContractEventInfoList) MarshalTo

func (m *ContractEventInfoList) MarshalTo(dAtA []byte) (int, error)

func (*ContractEventInfoList) MarshalToSizedBuffer

func (m *ContractEventInfoList) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractEventInfoList) ProtoMessage

func (*ContractEventInfoList) ProtoMessage()

func (*ContractEventInfoList) Reset

func (m *ContractEventInfoList) Reset()

func (*ContractEventInfoList) Size

func (m *ContractEventInfoList) Size() (n int)

func (*ContractEventInfoList) String

func (m *ContractEventInfoList) String() string

func (*ContractEventInfoList) Unmarshal

func (m *ContractEventInfoList) Unmarshal(dAtA []byte) error

func (*ContractEventInfoList) XXX_DiscardUnknown

func (m *ContractEventInfoList) XXX_DiscardUnknown()

func (*ContractEventInfoList) XXX_Marshal

func (m *ContractEventInfoList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractEventInfoList) XXX_Merge

func (m *ContractEventInfoList) XXX_Merge(src proto.Message)

func (*ContractEventInfoList) XXX_Size

func (m *ContractEventInfoList) XXX_Size() int

func (*ContractEventInfoList) XXX_Unmarshal

func (m *ContractEventInfoList) XXX_Unmarshal(b []byte) error

type ContractResult

type ContractResult struct {
	// 用户合约定义返回码,0-ok,>0 用户定义错误码。 例如代币转账余额不足
	Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	// 用户合约定义结果
	Result []byte `protobuf:"bytes,2,opt,name=result,proto3" json:"result,omitempty"`
	// 用户合约定义结果消息
	Message string `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"`
	// 当前合约使用的gas(包括合约调用)
	GasUsed uint64 `protobuf:"varint,4,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty"`
	// 合约事件
	ContractEvent []*ContractEvent `protobuf:"bytes,5,rep,name=contract_event,json=contractEvent,proto3" json:"contract_event,omitempty"`
}

调用用户合约方法从 TransactResult.TxResponse.payload 返回 UserContractReturnPayload 反序列化数据

func (*ContractResult) Descriptor

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

func (*ContractResult) GetCode

func (m *ContractResult) GetCode() uint32

func (*ContractResult) GetContractEvent

func (m *ContractResult) GetContractEvent() []*ContractEvent

func (*ContractResult) GetGasUsed

func (m *ContractResult) GetGasUsed() uint64

func (*ContractResult) GetMessage

func (m *ContractResult) GetMessage() string

func (*ContractResult) GetResult

func (m *ContractResult) GetResult() []byte

func (*ContractResult) Marshal

func (m *ContractResult) Marshal() (dAtA []byte, err error)

func (*ContractResult) MarshalTo

func (m *ContractResult) MarshalTo(dAtA []byte) (int, error)

func (*ContractResult) MarshalToSizedBuffer

func (m *ContractResult) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractResult) ProtoMessage

func (*ContractResult) ProtoMessage()

func (*ContractResult) Reset

func (m *ContractResult) Reset()

func (*ContractResult) Size

func (m *ContractResult) Size() (n int)

func (*ContractResult) String

func (m *ContractResult) String() string

func (*ContractResult) Unmarshal

func (m *ContractResult) Unmarshal(dAtA []byte) error

func (*ContractResult) XXX_DiscardUnknown

func (m *ContractResult) XXX_DiscardUnknown()

func (*ContractResult) XXX_Marshal

func (m *ContractResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractResult) XXX_Merge

func (m *ContractResult) XXX_Merge(src proto.Message)

func (*ContractResult) XXX_Size

func (m *ContractResult) XXX_Size() int

func (*ContractResult) XXX_Unmarshal

func (m *ContractResult) XXX_Unmarshal(b []byte) error

type ContractStatus

type ContractStatus int32
const (
	// 正常,可以调用
	ContractStatus_NORMAL ContractStatus = 0
	// 冻结,暂时无法调用
	ContractStatus_FROZEN ContractStatus = 1
	// 已撤销,不能永久调用
	ContractStatus_REVOKED ContractStatus = 2
)

func (ContractStatus) EnumDescriptor

func (ContractStatus) EnumDescriptor() ([]byte, []int)

func (ContractStatus) String

func (x ContractStatus) String() string

type DAG

type DAG struct {
	// 事务拓扑排序的序号 与事务关联的事务拓扑排序的序号
	Vertexes []*DAG_Neighbor `protobuf:"bytes,2,rep,name=vertexes,proto3" json:"vertexes,omitempty"`
}

事务执行序列 使用邻接表存储

func (*DAG) Descriptor

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

func (*DAG) GetVertexes

func (m *DAG) GetVertexes() []*DAG_Neighbor

func (*DAG) Marshal

func (m *DAG) Marshal() (dAtA []byte, err error)

func (*DAG) MarshalTo

func (m *DAG) MarshalTo(dAtA []byte) (int, error)

func (*DAG) MarshalToSizedBuffer

func (m *DAG) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DAG) ProtoMessage

func (*DAG) ProtoMessage()

func (*DAG) Reset

func (m *DAG) Reset()

func (*DAG) Size

func (m *DAG) Size() (n int)

func (*DAG) String

func (m *DAG) String() string

func (*DAG) Unmarshal

func (m *DAG) Unmarshal(dAtA []byte) error

func (*DAG) XXX_DiscardUnknown

func (m *DAG) XXX_DiscardUnknown()

func (*DAG) XXX_Marshal

func (m *DAG) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DAG) XXX_Merge

func (m *DAG) XXX_Merge(src proto.Message)

func (*DAG) XXX_Size

func (m *DAG) XXX_Size() int

func (*DAG) XXX_Unmarshal

func (m *DAG) XXX_Unmarshal(b []byte) error

type DAG_Neighbor

type DAG_Neighbor struct {
	Neighbors []uint32 `protobuf:"varint,1,rep,packed,name=neighbors,proto3" json:"neighbors,omitempty"`
}

邻居节点:有读写冲突的相关事务

func (*DAG_Neighbor) Descriptor

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

func (*DAG_Neighbor) GetNeighbors

func (m *DAG_Neighbor) GetNeighbors() []uint32

func (*DAG_Neighbor) Marshal

func (m *DAG_Neighbor) Marshal() (dAtA []byte, err error)

func (*DAG_Neighbor) MarshalTo

func (m *DAG_Neighbor) MarshalTo(dAtA []byte) (int, error)

func (*DAG_Neighbor) MarshalToSizedBuffer

func (m *DAG_Neighbor) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DAG_Neighbor) ProtoMessage

func (*DAG_Neighbor) ProtoMessage()

func (*DAG_Neighbor) Reset

func (m *DAG_Neighbor) Reset()

func (*DAG_Neighbor) Size

func (m *DAG_Neighbor) Size() (n int)

func (*DAG_Neighbor) String

func (m *DAG_Neighbor) String() string

func (*DAG_Neighbor) Unmarshal

func (m *DAG_Neighbor) Unmarshal(dAtA []byte) error

func (*DAG_Neighbor) XXX_DiscardUnknown

func (m *DAG_Neighbor) XXX_DiscardUnknown()

func (*DAG_Neighbor) XXX_Marshal

func (m *DAG_Neighbor) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DAG_Neighbor) XXX_Merge

func (m *DAG_Neighbor) XXX_Merge(src proto.Message)

func (*DAG_Neighbor) XXX_Size

func (m *DAG_Neighbor) XXX_Size() int

func (*DAG_Neighbor) XXX_Unmarshal

func (m *DAG_Neighbor) XXX_Unmarshal(b []byte) error

type EndorsementEntry

type EndorsementEntry struct {
	// 签名者
	Signer *accesscontrol.Member `protobuf:"bytes,1,opt,name=signer,proto3" json:"signer,omitempty"`
	// 签名
	Signature []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
}

背书信息,包括签名者及其签名

func (*EndorsementEntry) Descriptor

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

func (*EndorsementEntry) GetSignature

func (m *EndorsementEntry) GetSignature() []byte

func (*EndorsementEntry) GetSigner

func (m *EndorsementEntry) GetSigner() *accesscontrol.Member

func (*EndorsementEntry) Marshal

func (m *EndorsementEntry) Marshal() (dAtA []byte, err error)

func (*EndorsementEntry) MarshalTo

func (m *EndorsementEntry) MarshalTo(dAtA []byte) (int, error)

func (*EndorsementEntry) MarshalToSizedBuffer

func (m *EndorsementEntry) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EndorsementEntry) ProtoMessage

func (*EndorsementEntry) ProtoMessage()

func (*EndorsementEntry) Reset

func (m *EndorsementEntry) Reset()

func (*EndorsementEntry) Size

func (m *EndorsementEntry) Size() (n int)

func (*EndorsementEntry) String

func (m *EndorsementEntry) String() string

func (*EndorsementEntry) Unmarshal

func (m *EndorsementEntry) Unmarshal(dAtA []byte) error

func (*EndorsementEntry) XXX_DiscardUnknown

func (m *EndorsementEntry) XXX_DiscardUnknown()

func (*EndorsementEntry) XXX_Marshal

func (m *EndorsementEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EndorsementEntry) XXX_Merge

func (m *EndorsementEntry) XXX_Merge(src proto.Message)

func (*EndorsementEntry) XXX_Size

func (m *EndorsementEntry) XXX_Size() int

func (*EndorsementEntry) XXX_Unmarshal

func (m *EndorsementEntry) XXX_Unmarshal(b []byte) error

type FilterExtensionType

type FilterExtensionType int32
const (
	FilterExtensionType_FETDefault   FilterExtensionType = 0
	FilterExtensionType_FETTimestamp FilterExtensionType = 1
)

func (FilterExtensionType) EnumDescriptor

func (FilterExtensionType) EnumDescriptor() ([]byte, []int)

func (FilterExtensionType) String

func (x FilterExtensionType) String() string

type KeyType

type KeyType int32
const (
	KeyType_KTDefault      KeyType = 0
	KeyType_KTTimestampKey KeyType = 1
)

func (KeyType) EnumDescriptor

func (KeyType) EnumDescriptor() ([]byte, []int)

func (KeyType) String

func (x KeyType) String() string

type KeyValuePair

type KeyValuePair struct {
	// 键
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// 值
	Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
}

一个键值对

func (*KeyValuePair) Descriptor

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

func (*KeyValuePair) GetKey

func (m *KeyValuePair) GetKey() string

func (*KeyValuePair) GetValue

func (m *KeyValuePair) GetValue() []byte

func (*KeyValuePair) Marshal

func (m *KeyValuePair) Marshal() (dAtA []byte, err error)

func (*KeyValuePair) MarshalTo

func (m *KeyValuePair) MarshalTo(dAtA []byte) (int, error)

func (*KeyValuePair) MarshalToSizedBuffer

func (m *KeyValuePair) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*KeyValuePair) ProtoMessage

func (*KeyValuePair) ProtoMessage()

func (*KeyValuePair) Reset

func (m *KeyValuePair) Reset()

func (*KeyValuePair) Size

func (m *KeyValuePair) Size() (n int)

func (*KeyValuePair) String

func (m *KeyValuePair) String() string

func (*KeyValuePair) Unmarshal

func (m *KeyValuePair) Unmarshal(dAtA []byte) error

func (*KeyValuePair) XXX_DiscardUnknown

func (m *KeyValuePair) XXX_DiscardUnknown()

func (*KeyValuePair) XXX_Marshal

func (m *KeyValuePair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*KeyValuePair) XXX_Merge

func (m *KeyValuePair) XXX_Merge(src proto.Message)

func (*KeyValuePair) XXX_Size

func (m *KeyValuePair) XXX_Size() int

func (*KeyValuePair) XXX_Unmarshal

func (m *KeyValuePair) XXX_Unmarshal(b []byte) error

type KeyVersion

type KeyVersion struct {
	// 最后修改密钥的事务标识符
	RefTxId string `protobuf:"bytes,1,opt,name=ref_tx_id,json=refTxId,proto3" json:"ref_tx_id,omitempty"`
	// 事务写入集中key的偏移量,从0开始
	RefOffset int32 `protobuf:"varint,2,opt,name=ref_offset,json=refOffset,proto3" json:"ref_offset,omitempty"`
}

键读版本

func (*KeyVersion) Descriptor

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

func (*KeyVersion) GetRefOffset

func (m *KeyVersion) GetRefOffset() int32

func (*KeyVersion) GetRefTxId

func (m *KeyVersion) GetRefTxId() string

func (*KeyVersion) Marshal

func (m *KeyVersion) Marshal() (dAtA []byte, err error)

func (*KeyVersion) MarshalTo

func (m *KeyVersion) MarshalTo(dAtA []byte) (int, error)

func (*KeyVersion) MarshalToSizedBuffer

func (m *KeyVersion) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*KeyVersion) ProtoMessage

func (*KeyVersion) ProtoMessage()

func (*KeyVersion) Reset

func (m *KeyVersion) Reset()

func (*KeyVersion) Size

func (m *KeyVersion) Size() (n int)

func (*KeyVersion) String

func (m *KeyVersion) String() string

func (*KeyVersion) Unmarshal

func (m *KeyVersion) Unmarshal(dAtA []byte) error

func (*KeyVersion) XXX_DiscardUnknown

func (m *KeyVersion) XXX_DiscardUnknown()

func (*KeyVersion) XXX_Marshal

func (m *KeyVersion) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*KeyVersion) XXX_Merge

func (m *KeyVersion) XXX_Merge(src proto.Message)

func (*KeyVersion) XXX_Size

func (m *KeyVersion) XXX_Size() int

func (*KeyVersion) XXX_Unmarshal

func (m *KeyVersion) XXX_Unmarshal(b []byte) error

type Limit

type Limit struct {
	// gas 限制
	GasLimit uint64 `protobuf:"varint,1,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit,omitempty"`
}

Limit 定义交易限制,Limit 作为消息方便扩展

func (*Limit) Descriptor

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

func (*Limit) GetGasLimit

func (m *Limit) GetGasLimit() uint64

func (*Limit) Marshal

func (m *Limit) Marshal() (dAtA []byte, err error)

func (*Limit) MarshalTo

func (m *Limit) MarshalTo(dAtA []byte) (int, error)

func (*Limit) MarshalToSizedBuffer

func (m *Limit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Limit) ProtoMessage

func (*Limit) ProtoMessage()

func (*Limit) Reset

func (m *Limit) Reset()

func (*Limit) Size

func (m *Limit) Size() (n int)

func (*Limit) String

func (m *Limit) String() string

func (*Limit) Unmarshal

func (m *Limit) Unmarshal(dAtA []byte) error

func (*Limit) XXX_DiscardUnknown

func (m *Limit) XXX_DiscardUnknown()

func (*Limit) XXX_Marshal

func (m *Limit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Limit) XXX_Merge

func (m *Limit) XXX_Merge(src proto.Message)

func (*Limit) XXX_Size

func (m *Limit) XXX_Size() int

func (*Limit) XXX_Unmarshal

func (m *Limit) XXX_Unmarshal(b []byte) error

type MilkyWay

type MilkyWay struct {
	// 天河配置
	Config *MilkyWayConfig `protobuf:"bytes,1,opt,name=config,proto3" json:"config,omitempty"`
	// 最终高度
	Height uint64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"`
	// 当前索引
	CurrentIndex uint32 `protobuf:"varint,3,opt,name=currentIndex,proto3" json:"currentIndex,omitempty"`
	// 一组天马过滤器
	Filters []*PegasusFilter `protobuf:"bytes,4,rep,name=filters,proto3" json:"filters,omitempty"`
}

天河交易过滤器

func (*MilkyWay) Descriptor

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

func (*MilkyWay) GetConfig

func (m *MilkyWay) GetConfig() *MilkyWayConfig

func (*MilkyWay) GetCurrentIndex

func (m *MilkyWay) GetCurrentIndex() uint32

func (*MilkyWay) GetFilters

func (m *MilkyWay) GetFilters() []*PegasusFilter

func (*MilkyWay) GetHeight

func (m *MilkyWay) GetHeight() uint64

func (*MilkyWay) Marshal

func (m *MilkyWay) Marshal() (dAtA []byte, err error)

func (*MilkyWay) MarshalTo

func (m *MilkyWay) MarshalTo(dAtA []byte) (int, error)

func (*MilkyWay) MarshalToSizedBuffer

func (m *MilkyWay) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MilkyWay) ProtoMessage

func (*MilkyWay) ProtoMessage()

func (*MilkyWay) Reset

func (m *MilkyWay) Reset()

func (*MilkyWay) Size

func (m *MilkyWay) Size() (n int)

func (*MilkyWay) String

func (m *MilkyWay) String() string

func (*MilkyWay) Unmarshal

func (m *MilkyWay) Unmarshal(dAtA []byte) error

func (*MilkyWay) XXX_DiscardUnknown

func (m *MilkyWay) XXX_DiscardUnknown()

func (*MilkyWay) XXX_Marshal

func (m *MilkyWay) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MilkyWay) XXX_Merge

func (m *MilkyWay) XXX_Merge(src proto.Message)

func (*MilkyWay) XXX_Size

func (m *MilkyWay) XXX_Size() int

func (*MilkyWay) XXX_Unmarshal

func (m *MilkyWay) XXX_Unmarshal(b []byte) error

type MilkyWayConfig

type MilkyWayConfig struct {
	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	Length  uint32 `protobuf:"varint,2,opt,name=length,proto3" json:"length,omitempty"`
	// 规则配置
	Rules *RulesConfig `protobuf:"bytes,3,opt,name=rules,proto3" json:"rules,omitempty"`
	// 天马交易过滤器配置
	Pegasus *PegasusConfig `protobuf:"bytes,4,opt,name=pegasus,proto3" json:"pegasus,omitempty"`
	// 快照配置
	Snapshot *SnapshotSerializerConfig `protobuf:"bytes,5,opt,name=snapshot,proto3" json:"snapshot,omitempty"`
}

func (*MilkyWayConfig) Descriptor

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

func (*MilkyWayConfig) GetChainId

func (m *MilkyWayConfig) GetChainId() string

func (*MilkyWayConfig) GetLength

func (m *MilkyWayConfig) GetLength() uint32

func (*MilkyWayConfig) GetPegasus

func (m *MilkyWayConfig) GetPegasus() *PegasusConfig

func (*MilkyWayConfig) GetRules

func (m *MilkyWayConfig) GetRules() *RulesConfig

func (*MilkyWayConfig) GetSnapshot

func (m *MilkyWayConfig) GetSnapshot() *SnapshotSerializerConfig

func (*MilkyWayConfig) Marshal

func (m *MilkyWayConfig) Marshal() (dAtA []byte, err error)

func (*MilkyWayConfig) MarshalTo

func (m *MilkyWayConfig) MarshalTo(dAtA []byte) (int, error)

func (*MilkyWayConfig) MarshalToSizedBuffer

func (m *MilkyWayConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MilkyWayConfig) ProtoMessage

func (*MilkyWayConfig) ProtoMessage()

func (*MilkyWayConfig) Reset

func (m *MilkyWayConfig) Reset()

func (*MilkyWayConfig) Size

func (m *MilkyWayConfig) Size() (n int)

func (*MilkyWayConfig) String

func (m *MilkyWayConfig) String() string

func (*MilkyWayConfig) Unmarshal

func (m *MilkyWayConfig) Unmarshal(dAtA []byte) error

func (*MilkyWayConfig) XXX_DiscardUnknown

func (m *MilkyWayConfig) XXX_DiscardUnknown()

func (*MilkyWayConfig) XXX_Marshal

func (m *MilkyWayConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MilkyWayConfig) XXX_Merge

func (m *MilkyWayConfig) XXX_Merge(src proto.Message)

func (*MilkyWayConfig) XXX_Size

func (m *MilkyWayConfig) XXX_Size() int

func (*MilkyWayConfig) XXX_Unmarshal

func (m *MilkyWayConfig) XXX_Unmarshal(b []byte) error

type Payload

type Payload struct {
	// 区块链标识
	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	// 交易类型
	TxType TxType `protobuf:"varint,2,opt,name=tx_type,json=txType,proto3,enum=common.TxType" json:"tx_type,omitempty"`
	// 发件人设置的交易ID,应该是唯一的
	TxId string `protobuf:"bytes,3,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"`
	// 事务时间戳,unix 时间戳格式,秒
	Timestamp int64 `protobuf:"varint,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// Unix时间戳格式的过期时间戳,如果交易尚未包含在块中,则该交易无效
	ExpirationTime int64 `protobuf:"varint,5,opt,name=expiration_time,json=expirationTime,proto3" json:"expiration_time,omitempty"`
	// 智能合约名称
	ContractName string `protobuf:"bytes,6,opt,name=contract_name,json=contractName,proto3" json:"contract_name,omitempty"`
	// 调用方法
	Method string `protobuf:"bytes,7,opt,name=method,proto3" json:"method,omitempty"`
	// 以 k-v 格式调用参数
	Parameters []*KeyValuePair `protobuf:"bytes,8,rep,name=parameters,proto3" json:"parameters,omitempty"`
	// 序号,默认为0
	Sequence uint64 `protobuf:"varint,9,opt,name=sequence,proto3" json:"sequence,omitempty"`
	// 交易限制
	Limit *Limit `protobuf:"bytes,10,opt,name=limit,proto3" json:"limit,omitempty"`
}

交易有效数据

func (*Payload) Descriptor

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

func (*Payload) GetChainId

func (m *Payload) GetChainId() string

func (*Payload) GetContractName

func (m *Payload) GetContractName() string

func (*Payload) GetExpirationTime

func (m *Payload) GetExpirationTime() int64

func (*Payload) GetLimit

func (m *Payload) GetLimit() *Limit

func (*Payload) GetMethod

func (m *Payload) GetMethod() string

func (*Payload) GetParameter

func (t *Payload) GetParameter(key string) []byte

GetParameter 获得某个参数的值

func (*Payload) GetParameters

func (m *Payload) GetParameters() []*KeyValuePair

func (*Payload) GetSequence

func (m *Payload) GetSequence() uint64

func (*Payload) GetTimestamp

func (m *Payload) GetTimestamp() int64

func (*Payload) GetTxId

func (m *Payload) GetTxId() string

func (*Payload) GetTxType

func (m *Payload) GetTxType() TxType

func (*Payload) Marshal

func (m *Payload) Marshal() (dAtA []byte, err error)

func (*Payload) MarshalTo

func (m *Payload) MarshalTo(dAtA []byte) (int, error)

func (*Payload) MarshalToSizedBuffer

func (m *Payload) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Payload) ProtoMessage

func (*Payload) ProtoMessage()

func (*Payload) Reset

func (m *Payload) Reset()

func (*Payload) Size

func (m *Payload) Size() (n int)

func (*Payload) String

func (m *Payload) String() string

func (*Payload) Unmarshal

func (m *Payload) Unmarshal(dAtA []byte) error

func (*Payload) XXX_DiscardUnknown

func (m *Payload) XXX_DiscardUnknown()

func (*Payload) XXX_Marshal

func (m *Payload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Payload) XXX_Merge

func (m *Payload) XXX_Merge(src proto.Message)

func (*Payload) XXX_Size

func (m *Payload) XXX_Size() int

func (*Payload) XXX_Unmarshal

func (m *Payload) XXX_Unmarshal(b []byte) error

type PegasusConfig

type PegasusConfig struct {
	KeyType KeyType `protobuf:"varint,1,opt,name=key_type,json=keyType,proto3,enum=common.KeyType" json:"key_type,omitempty"`
	// 每个桶的标签数量,在纸上是 b。tag是指纹,在纸上是f。
	TagsPerBucket uint32 `protobuf:"varint,2,opt,name=tags_per_bucket,json=tagsPerBucket,proto3" json:"tags_per_bucket,omitempty"`
	// 每个项的位数,即标签长度(指纹)
	BitsPerItem uint32 `protobuf:"varint,3,opt,name=bits_per_item,json=bitsPerItem,proto3" json:"bits_per_item,omitempty"`
	// 过滤器将存储的键数。 这个值应该接近并低于
	// nextPow2(maxNumKeys/tagsPerBucket) * maxLoadFactor。
	// 因为 table.NumBuckets 始终是 2 的幂
	MaxNumKeys uint32 `protobuf:"varint,4,opt,name=max_num_keys,json=maxNumKeys,proto3" json:"max_num_keys,omitempty"`
	// 有两个常数参数可供选择:
	// TableTypeSingle 普通单表
	// TableTypePacked 打包表,使用半排序每项节省 1 位
	TableType uint32 `protobuf:"varint,5,opt,name=table_type,json=tableType,proto3" json:"table_type,omitempty"`
}

天马交易过滤器配置

func (*PegasusConfig) Descriptor

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

func (*PegasusConfig) GetBitsPerItem

func (m *PegasusConfig) GetBitsPerItem() uint32

func (*PegasusConfig) GetKeyType

func (m *PegasusConfig) GetKeyType() KeyType

func (*PegasusConfig) GetMaxNumKeys

func (m *PegasusConfig) GetMaxNumKeys() uint32

func (*PegasusConfig) GetTableType

func (m *PegasusConfig) GetTableType() uint32

func (*PegasusConfig) GetTagsPerBucket

func (m *PegasusConfig) GetTagsPerBucket() uint32

func (*PegasusConfig) Marshal

func (m *PegasusConfig) Marshal() (dAtA []byte, err error)

func (*PegasusConfig) MarshalTo

func (m *PegasusConfig) MarshalTo(dAtA []byte) (int, error)

func (*PegasusConfig) MarshalToSizedBuffer

func (m *PegasusConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PegasusConfig) ProtoMessage

func (*PegasusConfig) ProtoMessage()

func (*PegasusConfig) Reset

func (m *PegasusConfig) Reset()

func (*PegasusConfig) Size

func (m *PegasusConfig) Size() (n int)

func (*PegasusConfig) String

func (m *PegasusConfig) String() string

func (*PegasusConfig) Unmarshal

func (m *PegasusConfig) Unmarshal(dAtA []byte) error

func (*PegasusConfig) XXX_DiscardUnknown

func (m *PegasusConfig) XXX_DiscardUnknown()

func (*PegasusConfig) XXX_Marshal

func (m *PegasusConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PegasusConfig) XXX_Merge

func (m *PegasusConfig) XXX_Merge(src proto.Message)

func (*PegasusConfig) XXX_Size

func (m *PegasusConfig) XXX_Size() int

func (*PegasusConfig) XXX_Unmarshal

func (m *PegasusConfig) XXX_Unmarshal(b []byte) error

type PegasusFilter

type PegasusFilter struct {
	// “pegasus”字段用于保存 pegasus Pb限制的序列化数据:字节大小不能大于4GB
	Pegasus []byte `protobuf:"bytes,1,opt,name=pegasus,proto3" json:"pegasus,omitempty"`
	// 携带当时的身份标识
	Extension []byte `protobuf:"bytes,2,opt,name=extension,proto3" json:"extension,omitempty"`
	// 天马配置
	Config []byte `protobuf:"bytes,3,opt,name=config,proto3" json:"config,omitempty"`
}

天马交易过滤器

func (*PegasusFilter) Descriptor

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

func (*PegasusFilter) GetConfig

func (m *PegasusFilter) GetConfig() []byte

func (*PegasusFilter) GetExtension

func (m *PegasusFilter) GetExtension() []byte

func (*PegasusFilter) GetPegasus

func (m *PegasusFilter) GetPegasus() []byte

func (*PegasusFilter) Marshal

func (m *PegasusFilter) Marshal() (dAtA []byte, err error)

func (*PegasusFilter) MarshalTo

func (m *PegasusFilter) MarshalTo(dAtA []byte) (int, error)

func (*PegasusFilter) MarshalToSizedBuffer

func (m *PegasusFilter) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PegasusFilter) ProtoMessage

func (*PegasusFilter) ProtoMessage()

func (*PegasusFilter) Reset

func (m *PegasusFilter) Reset()

func (*PegasusFilter) Size

func (m *PegasusFilter) Size() (n int)

func (*PegasusFilter) String

func (m *PegasusFilter) String() string

func (*PegasusFilter) Unmarshal

func (m *PegasusFilter) Unmarshal(dAtA []byte) error

func (*PegasusFilter) XXX_DiscardUnknown

func (m *PegasusFilter) XXX_DiscardUnknown()

func (*PegasusFilter) XXX_Marshal

func (m *PegasusFilter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PegasusFilter) XXX_Merge

func (m *PegasusFilter) XXX_Merge(src proto.Message)

func (*PegasusFilter) XXX_Size

func (m *PegasusFilter) XXX_Size() int

func (*PegasusFilter) XXX_Unmarshal

func (m *PegasusFilter) XXX_Unmarshal(b []byte) error

type PrivateGetContract

type PrivateGetContract struct {
	ContractCode []byte `protobuf:"bytes,1,opt,name=contract_code,json=contractCode,proto3" json:"contract_code,omitempty"`
	Version      string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
	GasLimit     uint64 `protobuf:"varint,3,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit,omitempty"`
}

func (*PrivateGetContract) Descriptor

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

func (*PrivateGetContract) GetContractCode

func (m *PrivateGetContract) GetContractCode() []byte

func (*PrivateGetContract) GetGasLimit

func (m *PrivateGetContract) GetGasLimit() uint64

func (*PrivateGetContract) GetVersion

func (m *PrivateGetContract) GetVersion() string

func (*PrivateGetContract) Marshal

func (m *PrivateGetContract) Marshal() (dAtA []byte, err error)

func (*PrivateGetContract) MarshalTo

func (m *PrivateGetContract) MarshalTo(dAtA []byte) (int, error)

func (*PrivateGetContract) MarshalToSizedBuffer

func (m *PrivateGetContract) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PrivateGetContract) ProtoMessage

func (*PrivateGetContract) ProtoMessage()

func (*PrivateGetContract) Reset

func (m *PrivateGetContract) Reset()

func (*PrivateGetContract) Size

func (m *PrivateGetContract) Size() (n int)

func (*PrivateGetContract) String

func (m *PrivateGetContract) String() string

func (*PrivateGetContract) Unmarshal

func (m *PrivateGetContract) Unmarshal(dAtA []byte) error

func (*PrivateGetContract) XXX_DiscardUnknown

func (m *PrivateGetContract) XXX_DiscardUnknown()

func (*PrivateGetContract) XXX_Marshal

func (m *PrivateGetContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PrivateGetContract) XXX_Merge

func (m *PrivateGetContract) XXX_Merge(src proto.Message)

func (*PrivateGetContract) XXX_Size

func (m *PrivateGetContract) XXX_Size() int

func (*PrivateGetContract) XXX_Unmarshal

func (m *PrivateGetContract) XXX_Unmarshal(b []byte) error

type Result

type Result struct {
	// 响应码
	Code TxStatusCode `protobuf:"varint,1,opt,name=code,proto3,enum=common.TxStatusCode" json:"code,omitempty"`
	// 返回的数据,在智能合约中设置
	ContractResult *ContractResult `protobuf:"bytes,2,opt,name=contract_result,json=contractResult,proto3" json:"contract_result,omitempty"`
	// 事务读写集的哈希
	RwSetHash []byte `protobuf:"bytes,3,opt,name=rw_set_hash,json=rwSetHash,proto3" json:"rw_set_hash,omitempty"`
	// 消息
	Message string `protobuf:"bytes,4,opt,name=message,proto3" json:"message,omitempty"`
}

tx 结果,块中交易的一部分

func (*Result) Descriptor

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

func (*Result) GetCode

func (m *Result) GetCode() TxStatusCode

func (*Result) GetContractResult

func (m *Result) GetContractResult() *ContractResult

func (*Result) GetMessage

func (m *Result) GetMessage() string

func (*Result) GetRwSetHash

func (m *Result) GetRwSetHash() []byte

func (*Result) Marshal

func (m *Result) Marshal() (dAtA []byte, err error)

func (*Result) MarshalTo

func (m *Result) MarshalTo(dAtA []byte) (int, error)

func (*Result) MarshalToSizedBuffer

func (m *Result) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Result) ProtoMessage

func (*Result) ProtoMessage()

func (*Result) Reset

func (m *Result) Reset()

func (*Result) Size

func (m *Result) Size() (n int)

func (*Result) String

func (m *Result) String() string

func (*Result) Unmarshal

func (m *Result) Unmarshal(dAtA []byte) error

func (*Result) XXX_DiscardUnknown

func (m *Result) XXX_DiscardUnknown()

func (*Result) XXX_Marshal

func (m *Result) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Result) XXX_Merge

func (m *Result) XXX_Merge(src proto.Message)

func (*Result) XXX_Size

func (m *Result) XXX_Size() int

func (*Result) XXX_Unmarshal

func (m *Result) XXX_Unmarshal(b []byte) error

type RuleType

type RuleType int32
const (
	RuleType_AbsoluteExpireTime RuleType = 0
)

func (RuleType) EnumDescriptor

func (RuleType) EnumDescriptor() ([]byte, []int)

func (RuleType) String

func (x RuleType) String() string

type RulesConfig

type RulesConfig struct {
	// 绝对过期时间秒
	AbsoluteExpireTime int64 `protobuf:"varint,1,opt,name=absolute_expire_time,json=absoluteExpireTime,proto3" json:"absolute_expire_time,omitempty"`
}

func (*RulesConfig) Descriptor

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

func (*RulesConfig) GetAbsoluteExpireTime

func (m *RulesConfig) GetAbsoluteExpireTime() int64

func (*RulesConfig) Marshal

func (m *RulesConfig) Marshal() (dAtA []byte, err error)

func (*RulesConfig) MarshalTo

func (m *RulesConfig) MarshalTo(dAtA []byte) (int, error)

func (*RulesConfig) MarshalToSizedBuffer

func (m *RulesConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*RulesConfig) ProtoMessage

func (*RulesConfig) ProtoMessage()

func (*RulesConfig) Reset

func (m *RulesConfig) Reset()

func (*RulesConfig) Size

func (m *RulesConfig) Size() (n int)

func (*RulesConfig) String

func (m *RulesConfig) String() string

func (*RulesConfig) Unmarshal

func (m *RulesConfig) Unmarshal(dAtA []byte) error

func (*RulesConfig) XXX_DiscardUnknown

func (m *RulesConfig) XXX_DiscardUnknown()

func (*RulesConfig) XXX_Marshal

func (m *RulesConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RulesConfig) XXX_Merge

func (m *RulesConfig) XXX_Merge(src proto.Message)

func (*RulesConfig) XXX_Size

func (m *RulesConfig) XXX_Size() int

func (*RulesConfig) XXX_Unmarshal

func (m *RulesConfig) XXX_Unmarshal(b []byte) error

type RuntimeType

type RuntimeType int32

/ 智能合约运行时,包含 vm 类型和语言类型

const (
	RuntimeType_INVALID RuntimeType = 0
	// native implement in perseus-go
	RuntimeType_NATIVE RuntimeType = 1
	// vm-wasmer, language-c++
	RuntimeType_WASMER RuntimeType = 2
	// vm-wxvm, language-cpp
	RuntimeType_WXVM RuntimeType = 3
	// wasm interpreter in go
	RuntimeType_GASM RuntimeType = 4
	// vm-evm
	RuntimeType_EVM RuntimeType = 5
	// vm-docker, language-golang
	RuntimeType_DOCKER_GO RuntimeType = 6
	// vm-docker, language-java
	RuntimeType_DOCKER_JAVA RuntimeType = 7
)

func (RuntimeType) EnumDescriptor

func (RuntimeType) EnumDescriptor() ([]byte, []int)

func (RuntimeType) String

func (x RuntimeType) String() string

type SerializeIntervalType

type SerializeIntervalType int32
const (
	// 高度序列化类型
	SerializeIntervalType_Height SerializeIntervalType = 0
	// 定时序列化类型
	SerializeIntervalType_Timed SerializeIntervalType = 1
	// 退出序列化类型
	SerializeIntervalType_Exit SerializeIntervalType = 2
)

func (SerializeIntervalType) EnumDescriptor

func (SerializeIntervalType) EnumDescriptor() ([]byte, []int)

func (SerializeIntervalType) String

func (x SerializeIntervalType) String() string

type ShardingMilkyWay

type ShardingMilkyWay struct {
	Length uint32 `protobuf:"varint,1,opt,name=length,proto3" json:"length,omitempty"`
	// 最终高度
	Height uint64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"`
	// 天河分片配置
	Config *ShardingMilkyWayConfig `protobuf:"bytes,3,opt,name=config,proto3" json:"config,omitempty"`
}

天河交易过滤器分片

func (*ShardingMilkyWay) Descriptor

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

func (*ShardingMilkyWay) GetConfig

func (m *ShardingMilkyWay) GetConfig() *ShardingMilkyWayConfig

func (*ShardingMilkyWay) GetHeight

func (m *ShardingMilkyWay) GetHeight() uint64

func (*ShardingMilkyWay) GetLength

func (m *ShardingMilkyWay) GetLength() uint32

func (*ShardingMilkyWay) Marshal

func (m *ShardingMilkyWay) Marshal() (dAtA []byte, err error)

func (*ShardingMilkyWay) MarshalTo

func (m *ShardingMilkyWay) MarshalTo(dAtA []byte) (int, error)

func (*ShardingMilkyWay) MarshalToSizedBuffer

func (m *ShardingMilkyWay) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ShardingMilkyWay) ProtoMessage

func (*ShardingMilkyWay) ProtoMessage()

func (*ShardingMilkyWay) Reset

func (m *ShardingMilkyWay) Reset()

func (*ShardingMilkyWay) Size

func (m *ShardingMilkyWay) Size() (n int)

func (*ShardingMilkyWay) String

func (m *ShardingMilkyWay) String() string

func (*ShardingMilkyWay) Unmarshal

func (m *ShardingMilkyWay) Unmarshal(dAtA []byte) error

func (*ShardingMilkyWay) XXX_DiscardUnknown

func (m *ShardingMilkyWay) XXX_DiscardUnknown()

func (*ShardingMilkyWay) XXX_Marshal

func (m *ShardingMilkyWay) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ShardingMilkyWay) XXX_Merge

func (m *ShardingMilkyWay) XXX_Merge(src proto.Message)

func (*ShardingMilkyWay) XXX_Size

func (m *ShardingMilkyWay) XXX_Size() int

func (*ShardingMilkyWay) XXX_Unmarshal

func (m *ShardingMilkyWay) XXX_Unmarshal(b []byte) error

type ShardingMilkyWayConfig

type ShardingMilkyWayConfig struct {
	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	Length  uint32 `protobuf:"varint,2,opt,name=length,proto3" json:"length,omitempty"`
	// 分片任务超时
	Timeout int64 `protobuf:"varint,3,opt,name=timeout,proto3" json:"timeout,omitempty"`
	// 天河配置
	Milkyway *MilkyWayConfig `protobuf:"bytes,4,opt,name=milkyway,proto3" json:"milkyway,omitempty"`
	// 快照配置
	Snapshot *SnapshotSerializerConfig `protobuf:"bytes,5,opt,name=snapshot,proto3" json:"snapshot,omitempty"`
}

天河交易过滤器分片配置

func (*ShardingMilkyWayConfig) Descriptor

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

func (*ShardingMilkyWayConfig) GetChainId

func (m *ShardingMilkyWayConfig) GetChainId() string

func (*ShardingMilkyWayConfig) GetLength

func (m *ShardingMilkyWayConfig) GetLength() uint32

func (*ShardingMilkyWayConfig) GetMilkyway

func (m *ShardingMilkyWayConfig) GetMilkyway() *MilkyWayConfig

func (*ShardingMilkyWayConfig) GetSnapshot

func (*ShardingMilkyWayConfig) GetTimeout

func (m *ShardingMilkyWayConfig) GetTimeout() int64

func (*ShardingMilkyWayConfig) Marshal

func (m *ShardingMilkyWayConfig) Marshal() (dAtA []byte, err error)

func (*ShardingMilkyWayConfig) MarshalTo

func (m *ShardingMilkyWayConfig) MarshalTo(dAtA []byte) (int, error)

func (*ShardingMilkyWayConfig) MarshalToSizedBuffer

func (m *ShardingMilkyWayConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ShardingMilkyWayConfig) ProtoMessage

func (*ShardingMilkyWayConfig) ProtoMessage()

func (*ShardingMilkyWayConfig) Reset

func (m *ShardingMilkyWayConfig) Reset()

func (*ShardingMilkyWayConfig) Size

func (m *ShardingMilkyWayConfig) Size() (n int)

func (*ShardingMilkyWayConfig) String

func (m *ShardingMilkyWayConfig) String() string

func (*ShardingMilkyWayConfig) Unmarshal

func (m *ShardingMilkyWayConfig) Unmarshal(dAtA []byte) error

func (*ShardingMilkyWayConfig) XXX_DiscardUnknown

func (m *ShardingMilkyWayConfig) XXX_DiscardUnknown()

func (*ShardingMilkyWayConfig) XXX_Marshal

func (m *ShardingMilkyWayConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ShardingMilkyWayConfig) XXX_Merge

func (m *ShardingMilkyWayConfig) XXX_Merge(src proto.Message)

func (*ShardingMilkyWayConfig) XXX_Size

func (m *ShardingMilkyWayConfig) XXX_Size() int

func (*ShardingMilkyWayConfig) XXX_Unmarshal

func (m *ShardingMilkyWayConfig) XXX_Unmarshal(b []byte) error

type SnapshotSerializerConfig

type SnapshotSerializerConfig struct {
	// 序列化类型
	Type  SerializeIntervalType         `protobuf:"varint,1,opt,name=type,proto3,enum=common.SerializeIntervalType" json:"type,omitempty"`
	Timed *TimedSerializeIntervalConfig `protobuf:"bytes,2,opt,name=timed,proto3" json:"timed,omitempty"`
	// 区块高度序列化间隔
	BlockHeight *BlockHeightSerializeIntervalConfig `protobuf:"bytes,3,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	// 文件路径
	Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"`
}

快照序列化程序配置

func (*SnapshotSerializerConfig) Descriptor

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

func (*SnapshotSerializerConfig) GetBlockHeight

func (*SnapshotSerializerConfig) GetPath

func (m *SnapshotSerializerConfig) GetPath() string

func (*SnapshotSerializerConfig) GetTimed

func (*SnapshotSerializerConfig) GetType

func (*SnapshotSerializerConfig) Marshal

func (m *SnapshotSerializerConfig) Marshal() (dAtA []byte, err error)

func (*SnapshotSerializerConfig) MarshalTo

func (m *SnapshotSerializerConfig) MarshalTo(dAtA []byte) (int, error)

func (*SnapshotSerializerConfig) MarshalToSizedBuffer

func (m *SnapshotSerializerConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*SnapshotSerializerConfig) ProtoMessage

func (*SnapshotSerializerConfig) ProtoMessage()

func (*SnapshotSerializerConfig) Reset

func (m *SnapshotSerializerConfig) Reset()

func (*SnapshotSerializerConfig) Size

func (m *SnapshotSerializerConfig) Size() (n int)

func (*SnapshotSerializerConfig) String

func (m *SnapshotSerializerConfig) String() string

func (*SnapshotSerializerConfig) Unmarshal

func (m *SnapshotSerializerConfig) Unmarshal(dAtA []byte) error

func (*SnapshotSerializerConfig) XXX_DiscardUnknown

func (m *SnapshotSerializerConfig) XXX_DiscardUnknown()

func (*SnapshotSerializerConfig) XXX_Marshal

func (m *SnapshotSerializerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SnapshotSerializerConfig) XXX_Merge

func (m *SnapshotSerializerConfig) XXX_Merge(src proto.Message)

func (*SnapshotSerializerConfig) XXX_Size

func (m *SnapshotSerializerConfig) XXX_Size() int

func (*SnapshotSerializerConfig) XXX_Unmarshal

func (m *SnapshotSerializerConfig) XXX_Unmarshal(b []byte) error

type StrSlice

type StrSlice struct {
	StrArr []string `protobuf:"bytes,1,rep,name=str_arr,json=strArr,proto3" json:"str_arr,omitempty"`
}

func (*StrSlice) Descriptor

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

func (*StrSlice) GetStrArr

func (m *StrSlice) GetStrArr() []string

func (*StrSlice) Marshal

func (m *StrSlice) Marshal() (dAtA []byte, err error)

func (*StrSlice) MarshalTo

func (m *StrSlice) MarshalTo(dAtA []byte) (int, error)

func (*StrSlice) MarshalToSizedBuffer

func (m *StrSlice) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*StrSlice) ProtoMessage

func (*StrSlice) ProtoMessage()

func (*StrSlice) Reset

func (m *StrSlice) Reset()

func (*StrSlice) Size

func (m *StrSlice) Size() (n int)

func (*StrSlice) String

func (m *StrSlice) String() string

func (*StrSlice) Unmarshal

func (m *StrSlice) Unmarshal(dAtA []byte) error

func (*StrSlice) XXX_DiscardUnknown

func (m *StrSlice) XXX_DiscardUnknown()

func (*StrSlice) XXX_Marshal

func (m *StrSlice) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StrSlice) XXX_Merge

func (m *StrSlice) XXX_Merge(src proto.Message)

func (*StrSlice) XXX_Size

func (m *StrSlice) XXX_Size() int

func (*StrSlice) XXX_Unmarshal

func (m *StrSlice) XXX_Unmarshal(b []byte) error

type SubscribeResult

type SubscribeResult struct {
	// 当 TxType == SUBSCRIBE_BLOCK_INFO 时,数据类型为 pb.BlockInfo;
	// 当 TxType == SUBSCRIBE_TX_INFO 时,数据类型为 pb.Transaction。
	Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
}

func (*SubscribeResult) Descriptor

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

func (*SubscribeResult) GetData

func (m *SubscribeResult) GetData() []byte

func (*SubscribeResult) Marshal

func (m *SubscribeResult) Marshal() (dAtA []byte, err error)

func (*SubscribeResult) MarshalTo

func (m *SubscribeResult) MarshalTo(dAtA []byte) (int, error)

func (*SubscribeResult) MarshalToSizedBuffer

func (m *SubscribeResult) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*SubscribeResult) ProtoMessage

func (*SubscribeResult) ProtoMessage()

func (*SubscribeResult) Reset

func (m *SubscribeResult) Reset()

func (*SubscribeResult) Size

func (m *SubscribeResult) Size() (n int)

func (*SubscribeResult) String

func (m *SubscribeResult) String() string

func (*SubscribeResult) Unmarshal

func (m *SubscribeResult) Unmarshal(dAtA []byte) error

func (*SubscribeResult) XXX_DiscardUnknown

func (m *SubscribeResult) XXX_DiscardUnknown()

func (*SubscribeResult) XXX_Marshal

func (m *SubscribeResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SubscribeResult) XXX_Merge

func (m *SubscribeResult) XXX_Merge(src proto.Message)

func (*SubscribeResult) XXX_Size

func (m *SubscribeResult) XXX_Size() int

func (*SubscribeResult) XXX_Unmarshal

func (m *SubscribeResult) XXX_Unmarshal(b []byte) error

type TimedSerializeIntervalConfig

type TimedSerializeIntervalConfig struct {
	Interval int64 `protobuf:"varint,2,opt,name=interval,proto3" json:"interval,omitempty"`
}

定时序列化间隔

func (*TimedSerializeIntervalConfig) Descriptor

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

func (*TimedSerializeIntervalConfig) GetInterval

func (m *TimedSerializeIntervalConfig) GetInterval() int64

func (*TimedSerializeIntervalConfig) Marshal

func (m *TimedSerializeIntervalConfig) Marshal() (dAtA []byte, err error)

func (*TimedSerializeIntervalConfig) MarshalTo

func (m *TimedSerializeIntervalConfig) MarshalTo(dAtA []byte) (int, error)

func (*TimedSerializeIntervalConfig) MarshalToSizedBuffer

func (m *TimedSerializeIntervalConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TimedSerializeIntervalConfig) ProtoMessage

func (*TimedSerializeIntervalConfig) ProtoMessage()

func (*TimedSerializeIntervalConfig) Reset

func (m *TimedSerializeIntervalConfig) Reset()

func (*TimedSerializeIntervalConfig) Size

func (m *TimedSerializeIntervalConfig) Size() (n int)

func (*TimedSerializeIntervalConfig) String

func (*TimedSerializeIntervalConfig) Unmarshal

func (m *TimedSerializeIntervalConfig) Unmarshal(dAtA []byte) error

func (*TimedSerializeIntervalConfig) XXX_DiscardUnknown

func (m *TimedSerializeIntervalConfig) XXX_DiscardUnknown()

func (*TimedSerializeIntervalConfig) XXX_Marshal

func (m *TimedSerializeIntervalConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TimedSerializeIntervalConfig) XXX_Merge

func (m *TimedSerializeIntervalConfig) XXX_Merge(src proto.Message)

func (*TimedSerializeIntervalConfig) XXX_Size

func (m *TimedSerializeIntervalConfig) XXX_Size() int

func (*TimedSerializeIntervalConfig) XXX_Unmarshal

func (m *TimedSerializeIntervalConfig) XXX_Unmarshal(b []byte) error

type Transaction

type Transaction struct {
	// 有效数据
	Payload *Payload `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"`
	// 发件人帐户和签名
	Sender *EndorsementEntry `protobuf:"bytes,2,opt,name=sender,proto3" json:"sender,omitempty"`
	// 背书人账户和签名
	Endorsers []*EndorsementEntry `protobuf:"bytes,3,rep,name=endorsers,proto3" json:"endorsers,omitempty"`
	// 交易结果
	Result *Result `protobuf:"bytes,4,opt,name=result,proto3" json:"result,omitempty"`
}

事务包括请求及其结果

func (*Transaction) Descriptor

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

func (*Transaction) GetEndorsers

func (m *Transaction) GetEndorsers() []*EndorsementEntry

func (*Transaction) GetPayload

func (m *Transaction) GetPayload() *Payload

func (*Transaction) GetResult

func (m *Transaction) GetResult() *Result

func (*Transaction) GetSender

func (m *Transaction) GetSender() *EndorsementEntry

func (*Transaction) GetSenderAccountId

func (t *Transaction) GetSenderAccountId() []byte

GetSenderAccountId 获得交易的发起人的唯一账户标识,这个标识如果大于200字节,则返回的是SHA256 Hash

func (*Transaction) Marshal

func (m *Transaction) Marshal() (dAtA []byte, err error)

func (*Transaction) MarshalTo

func (m *Transaction) MarshalTo(dAtA []byte) (int, error)

func (*Transaction) MarshalToSizedBuffer

func (m *Transaction) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Transaction) ProtoMessage

func (*Transaction) ProtoMessage()

func (*Transaction) Reset

func (m *Transaction) Reset()

func (*Transaction) Size

func (m *Transaction) Size() (n int)

func (*Transaction) String

func (m *Transaction) String() string

func (*Transaction) Unmarshal

func (m *Transaction) Unmarshal(dAtA []byte) error

func (*Transaction) XXX_DiscardUnknown

func (m *Transaction) XXX_DiscardUnknown()

func (*Transaction) XXX_Marshal

func (m *Transaction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Transaction) XXX_Merge

func (m *Transaction) XXX_Merge(src proto.Message)

func (*Transaction) XXX_Size

func (m *Transaction) XXX_Size() int

func (*Transaction) XXX_Unmarshal

func (m *Transaction) XXX_Unmarshal(b []byte) error

type TransactionInfo

type TransactionInfo struct {
	// 交易原始数据
	Transaction *Transaction `protobuf:"bytes,1,opt,name=transaction,proto3" json:"transaction,omitempty"`
	// 块高度
	BlockHeight uint64 `protobuf:"varint,2,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	// 块哈希
	BlockHash []byte `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"`
	// 区块中的交易索引
	TxIndex uint32 `protobuf:"varint,4,opt,name=tx_index,json=txIndex,proto3" json:"tx_index,omitempty"`
	// 区块头时间戳
	BlockTimestamp int64 `protobuf:"varint,5,opt,name=block_timestamp,json=blockTimestamp,proto3" json:"block_timestamp,omitempty"`
}

交易信息包括交易及其区块高度哈希和交易索引

func (*TransactionInfo) Descriptor

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

func (*TransactionInfo) GetBlockHash

func (m *TransactionInfo) GetBlockHash() []byte

func (*TransactionInfo) GetBlockHeight

func (m *TransactionInfo) GetBlockHeight() uint64

func (*TransactionInfo) GetBlockTimestamp

func (m *TransactionInfo) GetBlockTimestamp() int64

func (*TransactionInfo) GetTransaction

func (m *TransactionInfo) GetTransaction() *Transaction

func (*TransactionInfo) GetTxIndex

func (m *TransactionInfo) GetTxIndex() uint32

func (*TransactionInfo) Marshal

func (m *TransactionInfo) Marshal() (dAtA []byte, err error)

func (*TransactionInfo) MarshalTo

func (m *TransactionInfo) MarshalTo(dAtA []byte) (int, error)

func (*TransactionInfo) MarshalToSizedBuffer

func (m *TransactionInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TransactionInfo) ProtoMessage

func (*TransactionInfo) ProtoMessage()

func (*TransactionInfo) Reset

func (m *TransactionInfo) Reset()

func (*TransactionInfo) Size

func (m *TransactionInfo) Size() (n int)

func (*TransactionInfo) String

func (m *TransactionInfo) String() string

func (*TransactionInfo) Unmarshal

func (m *TransactionInfo) Unmarshal(dAtA []byte) error

func (*TransactionInfo) XXX_DiscardUnknown

func (m *TransactionInfo) XXX_DiscardUnknown()

func (*TransactionInfo) XXX_Marshal

func (m *TransactionInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TransactionInfo) XXX_Merge

func (m *TransactionInfo) XXX_Merge(src proto.Message)

func (*TransactionInfo) XXX_Size

func (m *TransactionInfo) XXX_Size() int

func (*TransactionInfo) XXX_Unmarshal

func (m *TransactionInfo) XXX_Unmarshal(b []byte) error

type TransactionInfoWithRWSet

type TransactionInfoWithRWSet struct {
	// 交易原始数据
	Transaction *Transaction `protobuf:"bytes,1,opt,name=transaction,proto3" json:"transaction,omitempty"`
	// 块高度
	BlockHeight uint64 `protobuf:"varint,2,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	// 块哈希
	BlockHash []byte `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"`
	// 区块中的交易索引
	TxIndex uint32 `protobuf:"varint,4,opt,name=tx_index,json=txIndex,proto3" json:"tx_index,omitempty"`
	// 区块头时间戳
	BlockTimestamp int64    `protobuf:"varint,5,opt,name=block_timestamp,json=blockTimestamp,proto3" json:"block_timestamp,omitempty"`
	RwSet          *TxRWSet `protobuf:"bytes,6,opt,name=rw_set,json=rwSet,proto3" json:"rw_set,omitempty"`
}

func (*TransactionInfoWithRWSet) Descriptor

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

func (*TransactionInfoWithRWSet) GetBlockHash

func (m *TransactionInfoWithRWSet) GetBlockHash() []byte

func (*TransactionInfoWithRWSet) GetBlockHeight

func (m *TransactionInfoWithRWSet) GetBlockHeight() uint64

func (*TransactionInfoWithRWSet) GetBlockTimestamp

func (m *TransactionInfoWithRWSet) GetBlockTimestamp() int64

func (*TransactionInfoWithRWSet) GetRwSet

func (m *TransactionInfoWithRWSet) GetRwSet() *TxRWSet

func (*TransactionInfoWithRWSet) GetTransaction

func (m *TransactionInfoWithRWSet) GetTransaction() *Transaction

func (*TransactionInfoWithRWSet) GetTxIndex

func (m *TransactionInfoWithRWSet) GetTxIndex() uint32

func (*TransactionInfoWithRWSet) Marshal

func (m *TransactionInfoWithRWSet) Marshal() (dAtA []byte, err error)

func (*TransactionInfoWithRWSet) MarshalTo

func (m *TransactionInfoWithRWSet) MarshalTo(dAtA []byte) (int, error)

func (*TransactionInfoWithRWSet) MarshalToSizedBuffer

func (m *TransactionInfoWithRWSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TransactionInfoWithRWSet) ProtoMessage

func (*TransactionInfoWithRWSet) ProtoMessage()

func (*TransactionInfoWithRWSet) Reset

func (m *TransactionInfoWithRWSet) Reset()

func (*TransactionInfoWithRWSet) Size

func (m *TransactionInfoWithRWSet) Size() (n int)

func (*TransactionInfoWithRWSet) String

func (m *TransactionInfoWithRWSet) String() string

func (*TransactionInfoWithRWSet) Unmarshal

func (m *TransactionInfoWithRWSet) Unmarshal(dAtA []byte) error

func (*TransactionInfoWithRWSet) XXX_DiscardUnknown

func (m *TransactionInfoWithRWSet) XXX_DiscardUnknown()

func (*TransactionInfoWithRWSet) XXX_Marshal

func (m *TransactionInfoWithRWSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TransactionInfoWithRWSet) XXX_Merge

func (m *TransactionInfoWithRWSet) XXX_Merge(src proto.Message)

func (*TransactionInfoWithRWSet) XXX_Size

func (m *TransactionInfoWithRWSet) XXX_Size() int

func (*TransactionInfoWithRWSet) XXX_Unmarshal

func (m *TransactionInfoWithRWSet) XXX_Unmarshal(b []byte) error

type TransactionWithRWSet

type TransactionWithRWSet struct {
	// 交易原始数据
	Transaction *Transaction `protobuf:"bytes,1,opt,name=transaction,proto3" json:"transaction,omitempty"`
	RwSet       *TxRWSet     `protobuf:"bytes,2,opt,name=rw_set,json=rwSet,proto3" json:"rw_set,omitempty"`
}

交易和读写集

func (*TransactionWithRWSet) Descriptor

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

func (*TransactionWithRWSet) GetRwSet

func (m *TransactionWithRWSet) GetRwSet() *TxRWSet

func (*TransactionWithRWSet) GetTransaction

func (m *TransactionWithRWSet) GetTransaction() *Transaction

func (*TransactionWithRWSet) Marshal

func (m *TransactionWithRWSet) Marshal() (dAtA []byte, err error)

func (*TransactionWithRWSet) MarshalTo

func (m *TransactionWithRWSet) MarshalTo(dAtA []byte) (int, error)

func (*TransactionWithRWSet) MarshalToSizedBuffer

func (m *TransactionWithRWSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TransactionWithRWSet) ProtoMessage

func (*TransactionWithRWSet) ProtoMessage()

func (*TransactionWithRWSet) Reset

func (m *TransactionWithRWSet) Reset()

func (*TransactionWithRWSet) Size

func (m *TransactionWithRWSet) Size() (n int)

func (*TransactionWithRWSet) String

func (m *TransactionWithRWSet) String() string

func (*TransactionWithRWSet) Unmarshal

func (m *TransactionWithRWSet) Unmarshal(dAtA []byte) error

func (*TransactionWithRWSet) XXX_DiscardUnknown

func (m *TransactionWithRWSet) XXX_DiscardUnknown()

func (*TransactionWithRWSet) XXX_Marshal

func (m *TransactionWithRWSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TransactionWithRWSet) XXX_Merge

func (m *TransactionWithRWSet) XXX_Merge(src proto.Message)

func (*TransactionWithRWSet) XXX_Size

func (m *TransactionWithRWSet) XXX_Size() int

func (*TransactionWithRWSet) XXX_Unmarshal

func (m *TransactionWithRWSet) XXX_Unmarshal(b []byte) error

type TxRWSet

type TxRWSet struct {
	// 交易标识符
	TxId string `protobuf:"bytes,1,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"`
	// 读集
	TxReads []*TxRead `protobuf:"bytes,2,rep,name=tx_reads,json=txReads,proto3" json:"tx_reads,omitempty"`
	// 写集
	TxWrites []*TxWrite `protobuf:"bytes,3,rep,name=tx_writes,json=txWrites,proto3" json:"tx_writes,omitempty"`
}

TxRWSet 描述账本上交易的所有操作

func (*TxRWSet) Descriptor

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

func (*TxRWSet) GetTxId

func (m *TxRWSet) GetTxId() string

func (*TxRWSet) GetTxReads

func (m *TxRWSet) GetTxReads() []*TxRead

func (*TxRWSet) GetTxWrites

func (m *TxRWSet) GetTxWrites() []*TxWrite

func (*TxRWSet) Marshal

func (m *TxRWSet) Marshal() (dAtA []byte, err error)

func (*TxRWSet) MarshalTo

func (m *TxRWSet) MarshalTo(dAtA []byte) (int, error)

func (*TxRWSet) MarshalToSizedBuffer

func (m *TxRWSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TxRWSet) ProtoMessage

func (*TxRWSet) ProtoMessage()

func (*TxRWSet) Reset

func (m *TxRWSet) Reset()

func (*TxRWSet) Size

func (m *TxRWSet) Size() (n int)

func (*TxRWSet) String

func (m *TxRWSet) String() string

func (*TxRWSet) Unmarshal

func (m *TxRWSet) Unmarshal(dAtA []byte) error

func (*TxRWSet) XXX_DiscardUnknown

func (m *TxRWSet) XXX_DiscardUnknown()

func (*TxRWSet) XXX_Marshal

func (m *TxRWSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TxRWSet) XXX_Merge

func (m *TxRWSet) XXX_Merge(src proto.Message)

func (*TxRWSet) XXX_Size

func (m *TxRWSet) XXX_Size() int

func (*TxRWSet) XXX_Unmarshal

func (m *TxRWSet) XXX_Unmarshal(b []byte) error

type TxRead

type TxRead struct {
	// 读键
	Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// 键的值
	Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// 合约名称,用于跨合约调用,如果仅调用交易请求中的合约,则设置为 null
	ContractName string `protobuf:"bytes,3,opt,name=contract_name,json=contractName,proto3" json:"contract_name,omitempty"`
	// 键读版本
	Version *KeyVersion `protobuf:"bytes,4,opt,name=version,proto3" json:"version,omitempty"`
}

TxRead 描述一个键的读操作

func (*TxRead) Descriptor

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

func (*TxRead) GetContractName

func (m *TxRead) GetContractName() string

func (*TxRead) GetKey

func (m *TxRead) GetKey() []byte

func (*TxRead) GetValue

func (m *TxRead) GetValue() []byte

func (*TxRead) GetVersion

func (m *TxRead) GetVersion() *KeyVersion

func (*TxRead) Marshal

func (m *TxRead) Marshal() (dAtA []byte, err error)

func (*TxRead) MarshalTo

func (m *TxRead) MarshalTo(dAtA []byte) (int, error)

func (*TxRead) MarshalToSizedBuffer

func (m *TxRead) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TxRead) ProtoMessage

func (*TxRead) ProtoMessage()

func (*TxRead) Reset

func (m *TxRead) Reset()

func (*TxRead) Size

func (m *TxRead) Size() (n int)

func (*TxRead) String

func (m *TxRead) String() string

func (*TxRead) Unmarshal

func (m *TxRead) Unmarshal(dAtA []byte) error

func (*TxRead) XXX_DiscardUnknown

func (m *TxRead) XXX_DiscardUnknown()

func (*TxRead) XXX_Marshal

func (m *TxRead) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TxRead) XXX_Merge

func (m *TxRead) XXX_Merge(src proto.Message)

func (*TxRead) XXX_Size

func (m *TxRead) XXX_Size() int

func (*TxRead) XXX_Unmarshal

func (m *TxRead) XXX_Unmarshal(b []byte) error

type TxRequest

type TxRequest struct {
	// 有效数据
	Payload *Payload `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"`
	// 发件人帐户和发件人签名
	Sender *EndorsementEntry `protobuf:"bytes,2,opt,name=sender,proto3" json:"sender,omitempty"`
	// 背书人账户和签名
	Endorsers []*EndorsementEntry `protobuf:"bytes,3,rep,name=endorsers,proto3" json:"endorsers,omitempty"`
}

用户提出的交易请求

func (*TxRequest) Descriptor

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

func (*TxRequest) GetEndorsers

func (m *TxRequest) GetEndorsers() []*EndorsementEntry

func (*TxRequest) GetPayload

func (m *TxRequest) GetPayload() *Payload

func (*TxRequest) GetSender

func (m *TxRequest) GetSender() *EndorsementEntry

func (*TxRequest) Marshal

func (m *TxRequest) Marshal() (dAtA []byte, err error)

func (*TxRequest) MarshalTo

func (m *TxRequest) MarshalTo(dAtA []byte) (int, error)

func (*TxRequest) MarshalToSizedBuffer

func (m *TxRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TxRequest) ProtoMessage

func (*TxRequest) ProtoMessage()

func (*TxRequest) Reset

func (m *TxRequest) Reset()

func (*TxRequest) Size

func (m *TxRequest) Size() (n int)

func (*TxRequest) String

func (m *TxRequest) String() string

func (*TxRequest) Unmarshal

func (m *TxRequest) Unmarshal(dAtA []byte) error

func (*TxRequest) XXX_DiscardUnknown

func (m *TxRequest) XXX_DiscardUnknown()

func (*TxRequest) XXX_Marshal

func (m *TxRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TxRequest) XXX_Merge

func (m *TxRequest) XXX_Merge(src proto.Message)

func (*TxRequest) XXX_Size

func (m *TxRequest) XXX_Size() int

func (*TxRequest) XXX_Unmarshal

func (m *TxRequest) XXX_Unmarshal(b []byte) error

type TxResponse

type TxResponse struct {
	// 响应码
	Code TxStatusCode `protobuf:"varint,1,opt,name=code,proto3,enum=common.TxStatusCode" json:"code,omitempty"`
	// 响应消息
	Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// 返回的数据,在智能合约中设置
	ContractResult *ContractResult `protobuf:"bytes,3,opt,name=contract_result,json=contractResult,proto3" json:"contract_result,omitempty"`
	// 请求的 tx id
	TxId string `protobuf:"bytes,4,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"`
}

tx request - tx 响应,仅用于 RPC 响应

func (*TxResponse) Descriptor

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

func (*TxResponse) GetCode

func (m *TxResponse) GetCode() TxStatusCode

func (*TxResponse) GetContractResult

func (m *TxResponse) GetContractResult() *ContractResult

func (*TxResponse) GetMessage

func (m *TxResponse) GetMessage() string

func (*TxResponse) GetTxId

func (m *TxResponse) GetTxId() string

func (*TxResponse) Marshal

func (m *TxResponse) Marshal() (dAtA []byte, err error)

func (*TxResponse) MarshalTo

func (m *TxResponse) MarshalTo(dAtA []byte) (int, error)

func (*TxResponse) MarshalToSizedBuffer

func (m *TxResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TxResponse) ProtoMessage

func (*TxResponse) ProtoMessage()

func (*TxResponse) Reset

func (m *TxResponse) Reset()

func (*TxResponse) Size

func (m *TxResponse) Size() (n int)

func (*TxResponse) String

func (m *TxResponse) String() string

func (*TxResponse) Unmarshal

func (m *TxResponse) Unmarshal(dAtA []byte) error

func (*TxResponse) XXX_DiscardUnknown

func (m *TxResponse) XXX_DiscardUnknown()

func (*TxResponse) XXX_Marshal

func (m *TxResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TxResponse) XXX_Merge

func (m *TxResponse) XXX_Merge(src proto.Message)

func (*TxResponse) XXX_Size

func (m *TxResponse) XXX_Size() int

func (*TxResponse) XXX_Unmarshal

func (m *TxResponse) XXX_Unmarshal(b []byte) error

type TxStatusCode

type TxStatusCode int32
const (
	TxStatusCode_SUCCESS                                   TxStatusCode = 0
	TxStatusCode_TIMEOUT                                   TxStatusCode = 1
	TxStatusCode_INVALID_PARAMETER                         TxStatusCode = 2
	TxStatusCode_NO_PERMISSION                             TxStatusCode = 3
	TxStatusCode_CONTRACT_FAIL                             TxStatusCode = 4
	TxStatusCode_INTERNAL_ERROR                            TxStatusCode = 5
	TxStatusCode_INVALID_CONTRACT_TRANSACTION_TYPE         TxStatusCode = 10
	TxStatusCode_INVALID_CONTRACT_PARAMETER_CONTRACT_NAME  TxStatusCode = 11
	TxStatusCode_INVALID_CONTRACT_PARAMETER_METHOD         TxStatusCode = 12
	TxStatusCode_INVALID_CONTRACT_PARAMETER_INIT_METHOD    TxStatusCode = 13
	TxStatusCode_INVALID_CONTRACT_PARAMETER_UPGRADE_METHOD TxStatusCode = 14
	TxStatusCode_INVALID_CONTRACT_PARAMETER_BYTE_CODE      TxStatusCode = 15
	TxStatusCode_INVALID_CONTRACT_PARAMETER_RUNTIME_TYPE   TxStatusCode = 16
	TxStatusCode_INVALID_CONTRACT_PARAMETER_VERSION        TxStatusCode = 17
	TxStatusCode_GET_FROM_TX_CONTEXT_FAILED                TxStatusCode = 20
	TxStatusCode_PUT_INTO_TX_CONTEXT_FAILED                TxStatusCode = 21
	TxStatusCode_CONTRACT_VERSION_EXIST_FAILED             TxStatusCode = 22
	TxStatusCode_CONTRACT_VERSION_NOT_EXIST_FAILED         TxStatusCode = 23
	TxStatusCode_CONTRACT_BYTE_CODE_NOT_EXIST_FAILED       TxStatusCode = 24
	TxStatusCode_MARSHAL_SENDER_FAILED                     TxStatusCode = 25
	TxStatusCode_INVOKE_INIT_METHOD_FAILED                 TxStatusCode = 26
	TxStatusCode_INVOKE_UPGRADE_METHOD_FAILED              TxStatusCode = 27
	TxStatusCode_CREATE_RUNTIME_INSTANCE_FAILED            TxStatusCode = 28
	TxStatusCode_UNMARSHAL_CREATOR_FAILED                  TxStatusCode = 29
	TxStatusCode_UNMARSHAL_SENDER_FAILED                   TxStatusCode = 30
	TxStatusCode_GET_SENDER_PK_FAILED                      TxStatusCode = 31
	TxStatusCode_GET_CREATOR_PK_FAILED                     TxStatusCode = 32
	TxStatusCode_GET_CREATOR_FAILED                        TxStatusCode = 33
	TxStatusCode_GET_CREATOR_CERT_FAILED                   TxStatusCode = 34
	TxStatusCode_GET_SENDER_CERT_FAILED                    TxStatusCode = 35
	TxStatusCode_CONTRACT_FREEZE_FAILED                    TxStatusCode = 36
	TxStatusCode_CONTRACT_TOO_DEEP_FAILED                  TxStatusCode = 37
	TxStatusCode_CONTRACT_REVOKE_FAILED                    TxStatusCode = 38
	TxStatusCode_CONTRACT_INVOKE_METHOD_FAILED             TxStatusCode = 39
	TxStatusCode_ARCHIVED_TX                               TxStatusCode = 40
	TxStatusCode_ARCHIVED_BLOCK                            TxStatusCode = 41
	TxStatusCode_GAS_BALANCE_NOT_ENOUGH_FAILED             TxStatusCode = 42
)

func (TxStatusCode) EnumDescriptor

func (TxStatusCode) EnumDescriptor() ([]byte, []int)

func (TxStatusCode) String

func (x TxStatusCode) String() string

type TxType

type TxType int32

交易类型定义

const (
	// 调用预先创建的合约,tx 包含在块中
	TxType_INVOKE_CONTRACT TxType = 0
	// 查询预先创建的合约,tx 不包含在区块中
	TxType_QUERY_CONTRACT TxType = 1
	// 订阅区块信息、交易信息和合约信息。tx 不包含在块中
	TxType_SUBSCRIBE TxType = 2
	// 存档/恢复块,tx 不包含在块中
	TxType_ARCHIVE TxType = 3
)

func (TxType) EnumDescriptor

func (TxType) EnumDescriptor() ([]byte, []int)

func (TxType) String

func (x TxType) String() string

type TxWrite

type TxWrite struct {
	// 写键
	Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// 写值
	Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// 合约名称,用于跨合约调用,如果仅调用交易请求中的合约,则设置为 null
	ContractName string `protobuf:"bytes,3,opt,name=contract_name,json=contractName,proto3" json:"contract_name,omitempty"`
}

TxRead 描述了一个键的写/删除操作

func (*TxWrite) Descriptor

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

func (*TxWrite) GetContractName

func (m *TxWrite) GetContractName() string

func (*TxWrite) GetKey

func (m *TxWrite) GetKey() []byte

func (*TxWrite) GetValue

func (m *TxWrite) GetValue() []byte

func (*TxWrite) Marshal

func (m *TxWrite) Marshal() (dAtA []byte, err error)

func (*TxWrite) MarshalTo

func (m *TxWrite) MarshalTo(dAtA []byte) (int, error)

func (*TxWrite) MarshalToSizedBuffer

func (m *TxWrite) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TxWrite) ProtoMessage

func (*TxWrite) ProtoMessage()

func (*TxWrite) Reset

func (m *TxWrite) Reset()

func (*TxWrite) Size

func (m *TxWrite) Size() (n int)

func (*TxWrite) String

func (m *TxWrite) String() string

func (*TxWrite) Unmarshal

func (m *TxWrite) Unmarshal(dAtA []byte) error

func (*TxWrite) XXX_DiscardUnknown

func (m *TxWrite) XXX_DiscardUnknown()

func (*TxWrite) XXX_Marshal

func (m *TxWrite) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TxWrite) XXX_Merge

func (m *TxWrite) XXX_Merge(src proto.Message)

func (*TxWrite) XXX_Size

func (m *TxWrite) XXX_Size() int

func (*TxWrite) XXX_Unmarshal

func (m *TxWrite) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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