internal

package
v0.49.1 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeginBlocker

func BeginBlocker(ctx sdk.Context, k Keeper)

BeginBlocker withdraws rewards from fee-collector before the distribution module's withdraw.

func EndBlocker

func EndBlocker(ctx sdk.Context, k Keeper)

func ModuleAccountInvariant

func ModuleAccountInvariant(k Keeper) sdk.Invariant

func NewFoundationProposalsHandler

func NewFoundationProposalsHandler(k Keeper) govtypes.Handler

NewFoundationProposalsHandler creates a handler for the gov proposals.

func NewMsgServer

func NewMsgServer(keeper Keeper) foundation.MsgServer

NewMsgServer returns an implementation of the token MsgServer interface for the provided Keeper.

func NewQueryServer

func NewQueryServer(keeper Keeper) foundation.QueryServer

func ProposalInvariant

func ProposalInvariant(k Keeper) sdk.Invariant

func RegisterInvariants

func RegisterInvariants(ir sdk.InvariantRegistry, k Keeper)

func TotalWeightInvariant

func TotalWeightInvariant(k Keeper) sdk.Invariant

func Uint64FromBytes

func Uint64FromBytes(bz []byte) uint64

Uint64FromBytes converts a byte array to uint64

func Uint64ToBytes

func Uint64ToBytes(number uint64) []byte

Uint64ToBytes converts a number in uint64 to a byte array

Types

type Keeper

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

Keeper defines the foundation module Keeper

func NewKeeper

func NewKeeper(
	cdc codec.Codec,
	key sdk.StoreKey,
	router *baseapp.MsgServiceRouter,
	authKeeper foundation.AuthKeeper,
	bankKeeper foundation.BankKeeper,
	feeCollectorName string,
	config foundation.Config,
	authority string,
	paramSpace paramtypes.Subspace,
) Keeper

func (Keeper) Accept

func (k Keeper) Accept(ctx sdk.Context, grantee sdk.AccAddress, msg sdk.Msg) error

func (Keeper) CollectFoundationTax

func (k Keeper) CollectFoundationTax(ctx sdk.Context) error

func (Keeper) Exec

func (k Keeper) Exec(ctx sdk.Context, proposalID uint64) error

func (Keeper) ExportGenesis

func (k Keeper) ExportGenesis(ctx sdk.Context) *foundation.GenesisState

func (Keeper) FundTreasury

func (k Keeper) FundTreasury(ctx sdk.Context, from sdk.AccAddress, amt sdk.Coins) error

func (Keeper) GetAuthority

func (k Keeper) GetAuthority() string

GetAuthority returns the x/foundation module's authority.

func (Keeper) GetAuthorization

func (k Keeper) GetAuthorization(ctx sdk.Context, grantee sdk.AccAddress, msgTypeURL string) (foundation.Authorization, error)

func (Keeper) GetCensorship

func (k Keeper) GetCensorship(ctx sdk.Context, msgTypeURL string) (*foundation.Censorship, error)

func (Keeper) GetCensorships

func (k Keeper) GetCensorships(ctx sdk.Context) []foundation.Censorship

func (Keeper) GetFoundationInfo

func (k Keeper) GetFoundationInfo(ctx sdk.Context) foundation.FoundationInfo

func (Keeper) GetFoundationTax

func (k Keeper) GetFoundationTax(ctx sdk.Context) sdk.Dec

aliases

func (Keeper) GetGrants

func (k Keeper) GetGrants(ctx sdk.Context) []foundation.GrantAuthorization

func (Keeper) GetMember

func (k Keeper) GetMember(ctx sdk.Context, address sdk.AccAddress) (*foundation.Member, error)

func (Keeper) GetMembers

func (k Keeper) GetMembers(ctx sdk.Context) []foundation.Member

func (Keeper) GetParams

func (k Keeper) GetParams(ctx sdk.Context) foundation.Params

func (Keeper) GetPool

func (k Keeper) GetPool(ctx sdk.Context) foundation.Pool

func (Keeper) GetProposal

func (k Keeper) GetProposal(ctx sdk.Context, id uint64) (*foundation.Proposal, error)

func (Keeper) GetProposals

func (k Keeper) GetProposals(ctx sdk.Context) []foundation.Proposal

func (Keeper) GetTreasury

func (k Keeper) GetTreasury(ctx sdk.Context) sdk.DecCoins

func (Keeper) GetVote

func (k Keeper) GetVote(ctx sdk.Context, proposalID uint64, voter sdk.AccAddress) (*foundation.Vote, error)

func (Keeper) GetVotes

func (k Keeper) GetVotes(ctx sdk.Context, proposalID uint64) []foundation.Vote

func (Keeper) Grant

func (k Keeper) Grant(ctx sdk.Context, grantee sdk.AccAddress, authorization foundation.Authorization) error

func (Keeper) InitGenesis

func (k Keeper) InitGenesis(ctx sdk.Context, data *foundation.GenesisState) error

func (Keeper) IsCensoredMessage

func (k Keeper) IsCensoredMessage(ctx sdk.Context, msgTypeURL string) bool

func (Keeper) Logger

func (k Keeper) Logger(ctx sdk.Context) log.Logger

Logger returns a module-specific logger.

func (Keeper) PruneExpiredProposals

func (k Keeper) PruneExpiredProposals(ctx sdk.Context)

PruneExpiredProposals prunes all proposals which are expired, i.e. whose `submit_time + voting_period + max_execution_period` is smaller than (or equal to) now.

func (Keeper) Revoke

func (k Keeper) Revoke(ctx sdk.Context, grantee sdk.AccAddress, msgTypeURL string) error

func (Keeper) SetCensorship

func (k Keeper) SetCensorship(ctx sdk.Context, censorship foundation.Censorship)

func (Keeper) SetFoundationInfo

func (k Keeper) SetFoundationInfo(ctx sdk.Context, info foundation.FoundationInfo)

func (Keeper) SetMember

func (k Keeper) SetMember(ctx sdk.Context, member foundation.Member)

func (Keeper) SetParams

func (k Keeper) SetParams(ctx sdk.Context, params foundation.Params)

func (Keeper) SetPool

func (k Keeper) SetPool(ctx sdk.Context, pool foundation.Pool)

func (Keeper) SubmitProposal

func (k Keeper) SubmitProposal(ctx sdk.Context, proposers []string, metadata string, msgs []sdk.Msg) (*uint64, error)

func (Keeper) UpdateCensorship

func (k Keeper) UpdateCensorship(ctx sdk.Context, censorship foundation.Censorship) error

func (Keeper) UpdateDecisionPolicy

func (k Keeper) UpdateDecisionPolicy(ctx sdk.Context, policy foundation.DecisionPolicy) error

func (Keeper) UpdateMembers

func (k Keeper) UpdateMembers(ctx sdk.Context, members []foundation.MemberRequest) error

func (Keeper) UpdateTallyOfVPEndProposals

func (k Keeper) UpdateTallyOfVPEndProposals(ctx sdk.Context)

func (Keeper) Vote

func (k Keeper) Vote(ctx sdk.Context, vote foundation.Vote) error

func (Keeper) WithdrawFromTreasury

func (k Keeper) WithdrawFromTreasury(ctx sdk.Context, to sdk.AccAddress, amt sdk.Coins) error

func (Keeper) WithdrawProposal

func (k Keeper) WithdrawProposal(ctx sdk.Context, proposalID uint64) error

type Migrator

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

Migrator is a struct for handling in-place store migrations.

func NewMigrator

func NewMigrator(keeper Keeper) Migrator

NewMigrator returns a new Migrator.

func (Migrator) Register added in v0.47.1

func (m Migrator) Register(register func(moduleName string, fromVersion uint64, handler module.MigrationHandler) error) error

Directories

Path Synopsis
migrations
v2

Jump to

Keyboard shortcuts

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