quorum

package
v0.0.0-...-6d87009 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2022 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClockTick = 3 * time.Second
	// event MixinTransaction(bytes);
	EventTopic = "0xdb53e751d28ed0d6e3682814bf8d23f7dd7b29c94f74a56fbb7f88e9dca9f39b"
	// function mixin(bytes calldata raw) public returns (bool)
	EventMethod = "0x5cae8005"

	GasLimit = 8000000
	GasPrice = 50000000

	NotifierMinimumBalance = 0.02
	NotifierMaximumBalance = 0.1
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Store      string `toml:"store"`
	RPC        string `toml:"rpc"`
	ChainId    int64  `toml:"chain"`
	Base       uint64 `toml:"base"`
	PrivateKey string `toml:"key"`
}

type Engine

type Engine struct {
	// contains filtered or unexported fields
}

func Boot

func Boot(conf *Configuration) (*Engine, error)

func (*Engine) EnsureSendGroupEvents

func (e *Engine) EnsureSendGroupEvents(address string, events []*encoding.Event) error

func (*Engine) EstimateCost

func (e *Engine) EstimateCost(events []*encoding.Event) (common.Integer, error)

func (*Engine) Hash

func (e *Engine) Hash(b []byte) []byte

func (*Engine) IsPublisher

func (e *Engine) IsPublisher() bool

func (*Engine) ReceiveGroupEvents

func (e *Engine) ReceiveGroupEvents(address string, offset uint64, limit int) ([]*encoding.Event, error)

func (*Engine) SetupNotifier

func (e *Engine) SetupNotifier(address string) error

func (*Engine) VerifyAddress

func (e *Engine) VerifyAddress(address string, _ []byte) error

func (*Engine) VerifyEvent

func (e *Engine) VerifyEvent(address string, event *encoding.Event) bool

type EthereumError

type EthereumError struct {
	Code    int    `json:"code"`
	Message string `json:"message"`
}

func (*EthereumError) Error

func (err *EthereumError) Error() string

type Log

type Log struct {
	// contains filtered or unexported fields
}

type RPC

type RPC struct {
	// contains filtered or unexported fields
}

func NewRPC

func NewRPC(host string, base uint64) (*RPC, error)

func (*RPC) GetAddressBalance

func (chain *RPC) GetAddressBalance(address string) (decimal.Decimal, error)

func (*RPC) GetAddressNonce

func (chain *RPC) GetAddressNonce(address string) (uint64, error)

func (*RPC) GetBlockHeight

func (chain *RPC) GetBlockHeight() (uint64, error)

func (*RPC) GetLogs

func (chain *RPC) GetLogs(topic string, from, to uint64) ([]*Log, error)

func (*RPC) SendRawTransaction

func (chain *RPC) SendRawTransaction(raw string) (string, error)

Directories

Path Synopsis
abi
contracts

Jump to

Keyboard shortcuts

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