feegrant

package
v0.9.3-euphoria Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthFeegrant        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowFeegrant          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupFeegrant = fmt.Errorf("proto: unexpected end of group")
)
View Source
var ErrAddressNotAllowed = errorsmod.Register(feegrant.DefaultCodespace, 8, "address not allowed")

Functions

func RegisterInterfaces

func RegisterInterfaces(registry types.InterfaceRegistry)

RegisterInterfaces registers the interfaces types with the interface registry

Types

type AllowedContractAllowance

type AllowedContractAllowance struct {
	// allowance can be any of basic and periodic fee allowance.
	Allowance *types.Any `protobuf:"bytes,1,opt,name=allowance,proto3" json:"allowance,omitempty"`
	// allowed_address are the addresses for which the grantee has the access.
	AllowedAddress []string `protobuf:"bytes,2,rep,name=allowed_address,json=allowedAddress,proto3" json:"allowed_address,omitempty"`
}

AllowedContractAllowance creates allowance only for specified contract address.

func NewAllowedContractAllowance

func NewAllowedContractAllowance(allowance feegrant.FeeAllowanceI, allowedAddress []string) (*AllowedContractAllowance, error)

NewAllowedContractAllowance creates new filtered fee allowance.

func (*AllowedContractAllowance) Accept

func (a *AllowedContractAllowance) Accept(ctx sdk.Context, fee sdk.Coins, msgs []sdk.Msg) (remove bool, err error)

func (*AllowedContractAllowance) Descriptor

func (*AllowedContractAllowance) Descriptor() ([]byte, []int)

func (AllowedContractAllowance) ExpiresAt

func (a AllowedContractAllowance) ExpiresAt() (*time.Time, error)

ExpiresAt returns the expiry time of the AllowedMsgAllowance.

func (*AllowedContractAllowance) GetAllowance

GetAllowance returns allowed fee allowance.

func (*AllowedContractAllowance) Marshal

func (m *AllowedContractAllowance) Marshal() (dAtA []byte, err error)

func (*AllowedContractAllowance) MarshalTo

func (m *AllowedContractAllowance) MarshalTo(dAtA []byte) (int, error)

func (*AllowedContractAllowance) MarshalToSizedBuffer

func (m *AllowedContractAllowance) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AllowedContractAllowance) ProtoMessage

func (*AllowedContractAllowance) ProtoMessage()

func (*AllowedContractAllowance) Reset

func (m *AllowedContractAllowance) Reset()

func (*AllowedContractAllowance) SetAllowance

func (a *AllowedContractAllowance) SetAllowance(allowance feegrant.FeeAllowanceI) error

SetAllowance sets allowed fee allowance.

func (*AllowedContractAllowance) Size

func (m *AllowedContractAllowance) Size() (n int)

func (*AllowedContractAllowance) String

func (m *AllowedContractAllowance) String() string

func (*AllowedContractAllowance) Unmarshal

func (m *AllowedContractAllowance) Unmarshal(dAtA []byte) error

func (*AllowedContractAllowance) UnpackInterfaces

func (a *AllowedContractAllowance) UnpackInterfaces(unpacker types.AnyUnpacker) error

func (*AllowedContractAllowance) ValidateBasic

func (a *AllowedContractAllowance) ValidateBasic() error

func (*AllowedContractAllowance) XXX_DiscardUnknown

func (m *AllowedContractAllowance) XXX_DiscardUnknown()

func (*AllowedContractAllowance) XXX_Marshal

func (m *AllowedContractAllowance) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AllowedContractAllowance) XXX_Merge

func (m *AllowedContractAllowance) XXX_Merge(src proto.Message)

func (*AllowedContractAllowance) XXX_Size

func (m *AllowedContractAllowance) XXX_Size() int

func (*AllowedContractAllowance) XXX_Unmarshal

func (m *AllowedContractAllowance) XXX_Unmarshal(b []byte) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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