Documentation ¶
Index ¶
- Constants
- Variables
- func InitGenesis(ctx sdk.Context, k Keeper, data GenesisState) []abci.ValidatorUpdate
- type AppModule
- func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock)
- func (AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate
- func (am AppModule) ExportGenesis(ctx sdk.Context) json.RawMessage
- func (AppModule) GenerateGenesisState(simState *module.SimulationState)
- func (am AppModule) InitGenesis(ctx sdk.Context, data json.RawMessage) []abci.ValidatorUpdate
- func (AppModule) Name() string
- func (am AppModule) NewHandler() sdk.Handler
- func (am AppModule) NewQuerierHandler() sdk.Querier
- func (AppModule) ProposalContents(_ module.SimulationState) []sim.WeightedProposalContent
- func (AppModule) QuerierRoute() string
- func (AppModule) RandomizedParams(r *rand.Rand) []sim.ParamChange
- func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry)
- func (AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry)
- func (AppModule) Route() string
- func (am AppModule) WeightedOperations(simState module.SimulationState) []sim.WeightedOperation
- type AppModuleBasic
- func (AppModuleBasic) DefaultGenesis() json.RawMessage
- func (AppModuleBasic) GetQueryCmd(cdc *codec.Codec) *cobra.Command
- func (AppModuleBasic) GetTxCmd(cdc *codec.Codec) *cobra.Command
- func (AppModuleBasic) Name() string
- func (AppModuleBasic) RegisterCodec(cdc *codec.Codec)
- func (AppModuleBasic) RegisterRESTRoutes(ctx context.CLIContext, rtr *mux.Router)
- func (AppModuleBasic) ValidateGenesis(bz json.RawMessage) error
- type AppModuleSimulation
- type Entity
- type GenesisState
- type Keeper
- type MsgTrackAddShare
- type MsgTrackCreate
- type MsgTrackRemoveShare
- type QueryCreatorTracksParams
- type QueryTrackParams
- type QueryTracksParams
- type Share
- type Track
Constants ¶
const ( ModuleName = types.ModuleName StoreKey = types.StoreKey RouterKey = types.RouterKey QuerierRoute = types.QuerierRoute MaxTrackInfoLength = types.MaxTrackInfoLength TypeMsgTrackCreate = types.TypeMsgTrackCreate EventTypeTrackCreate = types.EventTypeTrackCreate AttributeKeyTrackID = types.AttributeKeyTrackID AttributeKeyEntity = types.AttributeKeyEntity AttributeKeyTokenAmount = types.AttributeKeyTokenAmount AttributeKeyTokenRecipient = types.AttributeKeyTokenRecipient QueryParams = types.QueryParams QueryTracks = types.QueryTracks QueryID = types.QueryID QueryCreatorTracks = types.QueryCreatorTracks )
Variables ¶
var ( // functions aliases GetTxCmd = cli.GetTxCmd GetCmdCreate = cli.GetCmdCreate GetQueryCmd = cli.GetQueryCmd GetCmdAll = cli.GetCmdAll GetCmdID = cli.GetCmdID GetCmdCreator = cli.GetCmdCreator NewHandler = keeper.NewHandler NewQuerier = keeper.NewQuerier NewKeeper = keeper.NewKeeper GetTrackIDBytes = types.GetTrackIDBytes GetTrackKey = types.GetTrackKey GetCreatorKey = types.GetCreatorKey GetTrackByCreatorAddr = types.GetTrackByCreatorAddr NewMsgTrackCreate = types.NewMsgTrackCreate NewQueryContentParams = types.NewQueryContentParams DefaultQueryTracksParams = types.DefaultQueryTracksParams NewTrack = types.NewTrack NewGenesisState = types.NewGenesisState DefaultGenesisState = types.DefaultGenesisState ValidateGenesis = types.ValidateGenesis RegisterCodec = types.RegisterCodec // variable aliases DefaultCodespace = types.DefaultCodespace ErrUnknownTrack = types.ErrUnknownTrack ErrInvalidAmount = types.ErrInvalidAmount TrackKeyPrefix = types.TrackKeyPrefix TracksCreatorKeyPrefix = types.TracksCreatorKeyPrefix ModuleCdc = types.ModuleCdc )
Functions ¶
func InitGenesis ¶
func InitGenesis(ctx sdk.Context, k Keeper, data GenesisState) []abci.ValidatorUpdate
InitGenesis initialize default parameters and the keeper's address to pubkey map
Types ¶
type AppModule ¶
type AppModule struct { AppModuleBasic // contains filtered or unexported fields }
AppModule implements an application module for the content module.
func NewAppModule ¶
NewAppModule creates a new AppModule object
func (AppModule) BeginBlock ¶
func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock)
BeginBlock returns the begin blocker for the content module.
func (AppModule) EndBlock ¶
func (AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate
EndBlock returns the end blocker for the content module. It returns no validator updates.
func (AppModule) ExportGenesis ¶
func (am AppModule) ExportGenesis(ctx sdk.Context) json.RawMessage
ExportGenesis returns the exported genesis state as raw bytes for the content module.
func (AppModule) GenerateGenesisState ¶ added in v0.5.0
func (AppModule) GenerateGenesisState(simState *module.SimulationState)
GenerateGenesisState creates a randomized GenState of the bank module.
func (AppModule) InitGenesis ¶
func (am AppModule) InitGenesis(ctx sdk.Context, data json.RawMessage) []abci.ValidatorUpdate
InitGenesis performs genesis initialization for the content module. It returns no validator updates.
func (AppModule) NewHandler ¶
NewHandler returns an sdk.Handler for the content module.
func (AppModule) NewQuerierHandler ¶
NewQuerierHandler returns the content module sdk.Querier.
func (AppModule) ProposalContents ¶ added in v0.5.0
func (AppModule) ProposalContents(_ module.SimulationState) []sim.WeightedProposalContent
ProposalContents doesn't return any content functions for governance proposals.
func (AppModule) QuerierRoute ¶
QuerierRoute returns the content module's querier route name.
func (AppModule) RandomizedParams ¶ added in v0.5.0
func (AppModule) RandomizedParams(r *rand.Rand) []sim.ParamChange
RandomizedParams creates randomized posts param changes for the simulator.
func (AppModule) RegisterInvariants ¶
func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry)
RegisterInvariants registers the content module invariants.
func (AppModule) RegisterStoreDecoder ¶ added in v0.5.0
func (AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry)
RegisterStoreDecoder performs a no-op.
func (AppModule) WeightedOperations ¶ added in v0.5.0
func (am AppModule) WeightedOperations(simState module.SimulationState) []sim.WeightedOperation
WeightedOperations returns the all the posts module operations with their respective weights.
type AppModuleBasic ¶
type AppModuleBasic struct{}
AppModuleBasic defines the basic application module used by the content module.
func (AppModuleBasic) DefaultGenesis ¶
func (AppModuleBasic) DefaultGenesis() json.RawMessage
DefaultGenesis returns default genesis state as raw bytes for the content module.
func (AppModuleBasic) GetQueryCmd ¶
func (AppModuleBasic) GetQueryCmd(cdc *codec.Codec) *cobra.Command
GetQueryCmd returns no root query command for the content module.
func (AppModuleBasic) GetTxCmd ¶
func (AppModuleBasic) GetTxCmd(cdc *codec.Codec) *cobra.Command
GetTxCmd returns the root tx command for the content module.
func (AppModuleBasic) Name ¶
func (AppModuleBasic) Name() string
Name returns the content module's name.
func (AppModuleBasic) RegisterCodec ¶
func (AppModuleBasic) RegisterCodec(cdc *codec.Codec)
RegisterCodec registers the content module's types for the given codec.
func (AppModuleBasic) RegisterRESTRoutes ¶
func (AppModuleBasic) RegisterRESTRoutes(ctx context.CLIContext, rtr *mux.Router)
RegisterRESTRoutes registers the REST routes for the content module.
func (AppModuleBasic) ValidateGenesis ¶
func (AppModuleBasic) ValidateGenesis(bz json.RawMessage) error
ValidateGenesis performs genesis state validation for the content module.
type AppModuleSimulation ¶ added in v0.5.0
type AppModuleSimulation struct{}
AppModuleSimulation defines the module simulation functions used by the track module.
type GenesisState ¶
type GenesisState = types.GenesisState
func ExportGenesis ¶
func ExportGenesis(ctx sdk.Context, k Keeper) (data GenesisState)
ExportGenesis writes the current store values to a genesis file, which can be imported again with InitGenesis
type MsgTrackAddShare ¶ added in v0.5.0
type MsgTrackAddShare = types.MsgTrackAddShare
type MsgTrackCreate ¶ added in v0.4.0
type MsgTrackCreate = types.MsgTrackCreate
type MsgTrackRemoveShare ¶ added in v0.5.0
type MsgTrackRemoveShare = types.MsgTrackRemoveShare
type QueryCreatorTracksParams ¶ added in v0.4.0
type QueryCreatorTracksParams = types.QueryCreatorTracksParams
type QueryTrackParams ¶ added in v0.4.0
type QueryTrackParams = types.QueryTrackParams
type QueryTracksParams ¶ added in v0.4.0
type QueryTracksParams = types.QueryTracksParams