package
0.0.0-20250108125741-e95afb000453
Repository: https://github.com/evmos/os.git
Documentation: pkg.go.dev
# Functions
CheckAllowanceArgs checks the arguments for the Allowance function.
CheckApprovalArgs checks the arguments passed to the approve function as well as the functions to change the allowance.
CheckAuthzAndAllowanceForGranter checks if the authorization exists and is not expired for the given spender and the allowance is not exceeded.
CheckAuthzExists checks if the authorization exists for the given granter and returns the authorization and its expiration time.
CheckRevokeArgs checks the arguments passed to the revoke function.
EmitIBCTransferAuthorizationEvent creates a new IBC transfer authorization event emitted on a TransferAuthorization transaction.
EmitRevocationEvent creates a new approval event emitted on a Revoke transaction.
# Constants
AllowanceMethod defines the ABI method name for the Allowance query.
ApproveMethod defines the ABI method name for the authorization Approve transaction.
DecreaseAllowanceMethod defines the ABI method name for the DecreaseAllowance transaction.
ErrAuthzDoesNotExistOrExpired is raised when the authorization does not exist.
ErrAuthzNotAccepted is raised when the authorization is not accepted.
ErrEmptyMethods is raised when the given methods array is empty.
ErrEmptyStringInMethods is raised when the given methods array contains an empty string.
ErrExceededAllowance is raised when the amount exceeds the set allowance.
ErrInvalidGrantee is raised when the grantee address is not valid.
ErrInvalidGranter is raised when the granter address is not valid.
ErrInvalidMethod is raised when the given method cannot be unpacked.
ErrInvalidMethods is raised when the given methods cannot be unpacked.
EventTypeAllowanceChange defines the event type for the staking IncreaseAllowance or DecreaseAllowance transactions.
EventTypeApproval defines the event type for the distribution Approve transaction.
#nosec G101 -- no hardcoded credentials here.
EventTypeRevocation defines the event type for the distribution Revoke transaction.
IncreaseAllowanceMethod defines the ABI method name for the IncreaseAllowance transaction.
RevokeMethod defines the ABI method name for the authorization Revoke transaction.
# Structs
EventAllowanceChange is the event emitted on successful IncreaseAllowance or DecreaseAllowance transactions.
EventApproval is the event emitted on a successful Approve transaction.
EventRevocation is the event emitted on a successful Revoke transaction.