generated

package
v0.0.0-...-c096a92 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewExecutableSchema

func NewExecutableSchema(cfg Config) graphql.ExecutableSchema

NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.

Types

type ComplexityRoot

type ComplexityRoot struct {
	Block struct {
		Difficulty      func(childComplexity int) int
		ExtraData       func(childComplexity int) int
		GasLimit        func(childComplexity int) int
		GasUsed         func(childComplexity int) int
		Hash            func(childComplexity int) int
		Miner           func(childComplexity int) int
		Nonce           func(childComplexity int) int
		Number          func(childComplexity int) int
		ParentHash      func(childComplexity int) int
		ReceiptRootHash func(childComplexity int) int
		Size            func(childComplexity int) int
		StateRootHash   func(childComplexity int) int
		Time            func(childComplexity int) int
		TxRootHash      func(childComplexity int) int
		UncleHash       func(childComplexity int) int
	}

	Event struct {
		BlockHash func(childComplexity int) int
		Data      func(childComplexity int) int
		Index     func(childComplexity int) int
		Origin    func(childComplexity int) int
		Topics    func(childComplexity int) int
		TxHash    func(childComplexity int) int
	}

	Query struct {
		BlockByHash                                  func(childComplexity int, hash string) int
		BlockByNumber                                func(childComplexity int, number string) int
		BlocksByNumberRange                          func(childComplexity int, from string, to string) int
		BlocksByTimeRange                            func(childComplexity int, from string, to string) int
		ContractsCreatedFromAccountByNumberRange     func(childComplexity int, account string, from string, to string) int
		ContractsCreatedFromAccountByTimeRange       func(childComplexity int, account string, from string, to string) int
		EventByBlockHashAndLogIndex                  func(childComplexity int, hash string, index string) int
		EventByBlockNumberAndLogIndex                func(childComplexity int, number string, index string) int
		EventsByBlockHash                            func(childComplexity int, hash string) int
		EventsByTxHash                               func(childComplexity int, hash string) int
		EventsFromContractByNumberRange              func(childComplexity int, contract string, from string, to string) int
		EventsFromContractByTimeRange                func(childComplexity int, contract string, from string, to string) int
		EventsFromContractWithTopicsByNumberRange    func(childComplexity int, contract string, from string, to string, topics []string) int
		EventsFromContractWithTopicsByTimeRange      func(childComplexity int, contract string, from string, to string, topics []string) int
		LastXEventsFromContract                      func(childComplexity int, contract string, x int) int
		Transaction                                  func(childComplexity int, hash string) int
		TransactionCountBetweenAccountsByNumberRange func(childComplexity int, fromAccount string, toAccount string, from string, to string) int
		TransactionCountBetweenAccountsByTimeRange   func(childComplexity int, fromAccount string, toAccount string, from string, to string) int
		TransactionCountByBlockHash                  func(childComplexity int, hash string) int
		TransactionCountByBlockNumber                func(childComplexity int, number string) int
		TransactionCountFromAccountByNumberRange     func(childComplexity int, account string, from string, to string) int
		TransactionCountFromAccountByTimeRange       func(childComplexity int, account string, from string, to string) int
		TransactionCountToAccountByNumberRange       func(childComplexity int, account string, from string, to string) int
		TransactionCountToAccountByTimeRange         func(childComplexity int, account string, from string, to string) int
		TransactionFromAccountWithNonce              func(childComplexity int, account string, nonce string) int
		TransactionsBetweenAccountsByNumberRange     func(childComplexity int, fromAccount string, toAccount string, from string, to string) int
		TransactionsBetweenAccountsByTimeRange       func(childComplexity int, fromAccount string, toAccount string, from string, to string) int
		TransactionsByBlockHash                      func(childComplexity int, hash string) int
		TransactionsByBlockNumber                    func(childComplexity int, number string) int
		TransactionsFromAccountByNumberRange         func(childComplexity int, account string, from string, to string) int
		TransactionsFromAccountByTimeRange           func(childComplexity int, account string, from string, to string) int
		TransactionsToAccountByNumberRange           func(childComplexity int, account string, from string, to string) int
		TransactionsToAccountByTimeRange             func(childComplexity int, account string, from string, to string) int
	}

	Transaction struct {
		BlockHash func(childComplexity int) int
		Contract  func(childComplexity int) int
		Cost      func(childComplexity int) int
		Data      func(childComplexity int) int
		From      func(childComplexity int) int
		Gas       func(childComplexity int) int
		GasPrice  func(childComplexity int) int
		Hash      func(childComplexity int) int
		Nonce     func(childComplexity int) int
		State     func(childComplexity int) int
		To        func(childComplexity int) int
		Value     func(childComplexity int) int
	}
}

type Config

type Config struct {
	Resolvers  ResolverRoot
	Directives DirectiveRoot
	Complexity ComplexityRoot
}

type DirectiveRoot

type DirectiveRoot struct {
}

type QueryResolver

type QueryResolver interface {
	BlockByHash(ctx context.Context, hash string) (*model.Block, error)
	BlockByNumber(ctx context.Context, number string) (*model.Block, error)
	BlocksByNumberRange(ctx context.Context, from string, to string) ([]*model.Block, error)
	BlocksByTimeRange(ctx context.Context, from string, to string) ([]*model.Block, error)
	Transaction(ctx context.Context, hash string) (*model.Transaction, error)
	TransactionCountByBlockHash(ctx context.Context, hash string) (int, error)
	TransactionsByBlockHash(ctx context.Context, hash string) ([]*model.Transaction, error)
	TransactionCountByBlockNumber(ctx context.Context, number string) (int, error)
	TransactionsByBlockNumber(ctx context.Context, number string) ([]*model.Transaction, error)
	TransactionCountFromAccountByNumberRange(ctx context.Context, account string, from string, to string) (int, error)
	TransactionsFromAccountByNumberRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	TransactionCountFromAccountByTimeRange(ctx context.Context, account string, from string, to string) (int, error)
	TransactionsFromAccountByTimeRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	TransactionCountToAccountByNumberRange(ctx context.Context, account string, from string, to string) (int, error)
	TransactionsToAccountByNumberRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	TransactionCountToAccountByTimeRange(ctx context.Context, account string, from string, to string) (int, error)
	TransactionsToAccountByTimeRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	TransactionCountBetweenAccountsByNumberRange(ctx context.Context, fromAccount string, toAccount string, from string, to string) (int, error)
	TransactionsBetweenAccountsByNumberRange(ctx context.Context, fromAccount string, toAccount string, from string, to string) ([]*model.Transaction, error)
	TransactionCountBetweenAccountsByTimeRange(ctx context.Context, fromAccount string, toAccount string, from string, to string) (int, error)
	TransactionsBetweenAccountsByTimeRange(ctx context.Context, fromAccount string, toAccount string, from string, to string) ([]*model.Transaction, error)
	ContractsCreatedFromAccountByNumberRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	ContractsCreatedFromAccountByTimeRange(ctx context.Context, account string, from string, to string) ([]*model.Transaction, error)
	TransactionFromAccountWithNonce(ctx context.Context, account string, nonce string) (*model.Transaction, error)
	EventsFromContractByNumberRange(ctx context.Context, contract string, from string, to string) ([]*model.Event, error)
	EventsFromContractByTimeRange(ctx context.Context, contract string, from string, to string) ([]*model.Event, error)
	EventsByBlockHash(ctx context.Context, hash string) ([]*model.Event, error)
	EventsByTxHash(ctx context.Context, hash string) ([]*model.Event, error)
	EventsFromContractWithTopicsByNumberRange(ctx context.Context, contract string, from string, to string, topics []string) ([]*model.Event, error)
	EventsFromContractWithTopicsByTimeRange(ctx context.Context, contract string, from string, to string, topics []string) ([]*model.Event, error)
	LastXEventsFromContract(ctx context.Context, contract string, x int) ([]*model.Event, error)
	EventByBlockHashAndLogIndex(ctx context.Context, hash string, index string) (*model.Event, error)
	EventByBlockNumberAndLogIndex(ctx context.Context, number string, index string) (*model.Event, error)
}

type ResolverRoot

type ResolverRoot interface {
	Query() QueryResolver
}

Jump to

Keyboard shortcuts

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