tx

package
v0.0.0-...-095f669 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2023 License: Apache-2.0 Imports: 21 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTextualWithBankKeeper

func NewTextualWithBankKeeper(bk BankKeeper) *textual.SignModeHandler

NewTextualWithBankKeeper creates a new Textual struct using the given BankKeeper to retrieve coin metadata.

Note: Once we switch to ADR-033, and keepers become ADR-033 clients to each other, this function could probably be deprecated in favor of `NewTextualWithGRPCConn`.

func NewTextualWithGRPCConn

func NewTextualWithGRPCConn(grpcConn grpc.ClientConnInterface) *textual.SignModeHandler

NewTextualWithGRPCConn returns a new Textual instance where the metadata queries are done via gRPC using the provided GRPC client connection. In the SDK, you can pass a client.Context as the GRPC connection.

Example:

clientCtx := client.GetClientContextFromCmd(cmd)
txt := tx.NewTextualWithGRPCConn(clientCtxx)

Types

type BankKeeper

type BankKeeper interface {
	DenomMetadata(c context.Context, req *types.QueryDenomMetadataRequest) (*types.QueryDenomMetadataResponse, error)
}

BankKeeper defines the contract needed for tx-related APIs

type TxInputs

type TxInputs struct {
	depinject.In

	Config              *txconfigv1.Config
	ProtoCodecMarshaler codec.ProtoCodecMarshaler

	AccountKeeper ante.AccountKeeper `optional:"true"`
	// BankKeeper is the expected bank keeper to be passed to AnteHandlers
	BankKeeper authtypes.BankKeeper `optional:"true"`
	// TxBankKeeper is the expected bank keeper to be passed to Textual
	TxBankKeeper   BankKeeper
	FeeGrantKeeper ante.FeegrantKeeper `optional:"true"`

	CustomSignModeHandlers func() []signing.SignModeHandler `optional:"true"`
}

type TxOutputs

type TxOutputs struct {
	depinject.Out

	TxConfig      client.TxConfig
	BaseAppOption runtime.BaseAppOption
}

func ProvideModule

func ProvideModule(in TxInputs) TxOutputs

Jump to

Keyboard shortcuts

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