common

package
v0.0.0-...-c02a99c Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	METADATA_KEY_MIN   int = 1
	METADATA_KEY_MAX   int = 1024
	METADATA_VALUE_MAX int = 256000

	HASH_HEX_LENGTH int = 64
	OPT_TYPE_MIN    int = 0
	OPT_TYPE_MAX    int = 2
	// 交易默认值
	GAS_PRICE int64 = 100
	FEE_LIMIT int64 = 1000000
	// 合约查询类型
	CONTRACT_QUERY_OPT_TYPE int = 2

	// 账号参数
	VERSION    int64 = 0
	SUCCESS    int   = 0
	ERRORCODE  int   = 4
	INIT_NONCE int64 = 0
	INIT_ZERO  int64 = 0
	INIT_ONE   int64 = 1

	INIT_ZERO_L int64 = 0
	INIT_ONE_L  int64 = 1

	// CONTRACT_TYPE_EVM 合约类型evm合约
	CONTRACT_TYPE_EVM int = 1

	// DDO_CONTRACT ...
	DDO_CONTRACT string = "did:bid:efspy6btdcuzP5BH2N899Ycti5Sd7n3z"
)
View Source
const (
	// UNKNOWN Unknown operation
	UNKNOWN = 0

	// ACCOUNT_ACTIVATE Activate an account
	ACCOUNT_ACTIVATE = 1

	// ACCOUNT_SET_METADATA Set metadata
	ACCOUNT_SET_METADATA = 2

	// ACCOUNT_SET_PRIVILEGE Set privilege
	ACCOUNT_SET_PRIVILEGE = 3

	// GAS_SEND Send gas
	GAS_SEND = 6

	// CONTRACT_CREATE Create contract
	CONTRACT_CREATE = 13

	// CONTRACT_INVOKE Invoke contract by sending
	CONTRACT_INVOKE = 15

	// PRIVATE_CONTRACT_CREATE Create Private Contract
	PRIVATE_CONTRACT_CREATE = 17

	// PRIVATE_CONTRACT_CALL Call Private Contract
	PRIVATE_CONTRACT_CALL = 18
)

OperationType

Variables

This section is empty.

Functions

func AccountGetInfoURL

func AccountGetInfoURL(url string, address string) string

func AccountGetMetadataURL

func AccountGetMetadataURL(url string, address string, key string) string

func BlockGetInfoURL

func BlockGetInfoURL(url string, blockNumber int64) string

func BlockGetLatestInfoURL

func BlockGetLatestInfoURL(url string) string

func BlockGetLatestValidatorsURL

func BlockGetLatestValidatorsURL(url string) string

func BlockGetNumberURL

func BlockGetNumberURL(url string) string

func BlockGetTransactionsURL

func BlockGetTransactionsURL(url string, blockNumber int64) string

func BlockGetValidatorsURL

func BlockGetValidatorsURL(url string, blockNumber int64) string

func ContractCallURL

func ContractCallURL(url string) string

func GetOperationType

func GetOperationType(operationType int) string

func GetTxCacheData

func GetTxCacheData(url string, hash string) string

func GetTxCacheSize

func GetTxCacheSize(url string) string

func PriTxReceive

func PriTxReceive(url string, priTxHash string) string

func PriTxReceiveRaw

func PriTxReceiveRaw(url string, priTxHash string) string

func PriTxSend

func PriTxSend(url string) string

func PriTxStoreRaw

func PriTxStoreRaw(url string) string

func PrivatecontractCallURL

func PrivatecontractCallURL(url string) string

func TransactionEvaluationFee

func TransactionEvaluationFee(url string) string

func TransactionGetInfoURL

func TransactionGetInfoURL(url string, hash string) string

func TransactionSubmitURL

func TransactionSubmitURL(url string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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