track

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModuleName                 = types.ModuleName
	StoreKey                   = types.StoreKey
	RouterKey                  = types.RouterKey
	QuerierRoute               = types.QuerierRoute
	MaxTrackInfoLength         = types.MaxTrackInfoLength
	TypeMsgTrackCreate         = types.TypeMsgTrackCreate
	TypeMsgTrackAddShare       = types.TypeMsgTrackAddShare
	TypeMsgTrackRemoveShare    = types.TypeMsgTrackRemoveShare
	EventTypeTrackCreate       = types.EventTypeTrackCreate
	EventTypeTrackAddShare     = types.EventTypeTrackAddShare
	AttributeKeyTrackID        = types.AttributeKeyTrackID
	AttributeKeyEntity         = types.AttributeKeyEntity
	AttributeKeyShare          = types.AttributeKeyShare
	AttributeKeyTokenAmount    = types.AttributeKeyTokenAmount
	AttributeKeyTokenRecipient = types.AttributeKeyTokenRecipient
	QueryParams                = types.QueryParams
	QueryTracks                = types.QueryTracks
	QueryID                    = types.QueryID
	QueryCreatorTracks         = types.QueryCreatorTracks
)

Variables

View Source
var (
	// functions aliases
	GetTxCmd                 = cli.GetTxCmd
	GetCmdCreate             = cli.GetCmdCreate
	GetCmdAddShare           = cli.GetCmdAddShare
	GetCmdRemoveShare        = cli.GetCmdRemoveShare
	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
	SharesKey                = types.SharesKey
	ShareKey                 = types.ShareKey
	NewMsgTrackCreate        = types.NewMsgTrackCreate
	NewMsgTrackAddShare      = types.NewMsgTrackAddShare
	NewMsgTrackRemoveShare   = types.NewMsgTrackRemoveShare
	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
	ErrUnknownShare        = types.ErrUnknownShare
	ErrInvalidAmount       = types.ErrInvalidAmount
	TrackKeyPrefix         = types.TrackKeyPrefix
	TracksCreatorKeyPrefix = types.TracksCreatorKeyPrefix
	SharesKeyPrefix        = types.SharesKeyPrefix
	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

func NewAppModule(k Keeper) AppModule

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

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) Name

func (AppModule) Name() string

Name returns the content module's name.

func (AppModule) NewHandler

func (am AppModule) NewHandler() sdk.Handler

NewHandler returns an sdk.Handler for the content module.

func (AppModule) NewQuerierHandler

func (am AppModule) NewQuerierHandler() sdk.Querier

NewQuerierHandler returns the content module sdk.Querier.

func (AppModule) ProposalContents added in v0.5.0

ProposalContents doesn't return any content functions for governance proposals.

func (AppModule) QuerierRoute

func (AppModule) QuerierRoute() string

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) Route

func (AppModule) Route() string

Route returns the message routing key for the content module.

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 Entity added in v0.5.0

type Entity = types.Entity

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 Keeper

type Keeper = keeper.Keeper

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

type Share added in v0.5.0

type Share = types.Share

type Track

type Track = types.Track

Directories

Path Synopsis
client
cli

Jump to

Keyboard shortcuts

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