apitypes

package
v1.8.2 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	WARN = "WARNING"
	CRIT = "CRITICAL"
	INFO = "Info"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type SendTxArgs

type SendTxArgs struct {
	From                 common.MixedcaseAddress  `json:"from"`
	To                   *common.MixedcaseAddress `json:"to"`
	Gas                  hexutil.Uint64           `json:"gas"`
	GasPrice             *hexutil.Big             `json:"gasPrice"`
	MaxFeePerGas         *hexutil.Big             `json:"maxFeePerGas"`
	MaxPriorityFeePerGas *hexutil.Big             `json:"maxPriorityFeePerGas"`
	FeeCurrency          *common.MixedcaseAddress `json:"feeCurrency"`
	GatewayFeeRecipient  *common.MixedcaseAddress `json:"gatewayFeeRecipient"`
	GatewayFee           hexutil.Big              `json:"gatewayFee"`
	Value                hexutil.Big              `json:"value"`
	Nonce                hexutil.Uint64           `json:"nonce"`
	EthCompatible        bool                     `json:"ethCompatible"`
	// We accept "data" and "input" for backwards-compatibility reasons.
	// "input" is the newer name and should be preferred by clients.
	// Issue detail: https://github.com/ethereum/go-ethereum/issues/15628
	Data  *hexutil.Bytes `json:"data"`
	Input *hexutil.Bytes `json:"input,omitempty"`

	// For non-legacy transactions
	AccessList *types.AccessList `json:"accessList,omitempty"`
	ChainID    *hexutil.Big      `json:"chainId,omitempty"`
}

SendTxArgs represents the arguments to submit a transaction This struct is identical to ethapi.TransactionArgs, except for the usage of common.MixedcaseAddress in From and To

func (SendTxArgs) CheckEthCompatibility

func (args SendTxArgs) CheckEthCompatibility() error

func (SendTxArgs) String

func (args SendTxArgs) String() string

func (*SendTxArgs) ToTransaction

func (args *SendTxArgs) ToTransaction(isGingerbreadP2 bool) *types.Transaction

type ValidationInfo

type ValidationInfo struct {
	Typ     string `json:"type"`
	Message string `json:"message"`
}

type ValidationMessages

type ValidationMessages struct {
	Messages []ValidationInfo
}

func (*ValidationMessages) Crit

func (vs *ValidationMessages) Crit(msg string)

func (*ValidationMessages) GetWarnings

func (v *ValidationMessages) GetWarnings() error

getWarnings returns an error with all messages of type WARN of above, or nil if no warnings were present

func (*ValidationMessages) Info

func (vs *ValidationMessages) Info(msg string)

func (*ValidationMessages) Warn

func (vs *ValidationMessages) Warn(msg string)

Jump to

Keyboard shortcuts

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