Documentation
¶
Index ¶
- Variables
- func ErrAccountNotFound() sdk.Error
- func ErrCensorshipPostIsDeleted(permlink types.Permlink) sdk.Error
- func ErrCensorshipPostNotFound() sdk.Error
- func ErrIllegalParameter() sdk.Error
- func ErrIncorrectProposalType() sdk.Error
- func ErrInvalidLink() sdk.Error
- func ErrInvalidPermlink() sdk.Error
- func ErrInvalidUsername() sdk.Error
- func ErrNotOngoingProposal() sdk.Error
- func ErrOngoingProposalNotFound() sdk.Error
- func ErrPostNotFound() sdk.Error
- func ErrReasonTooLong() sdk.Error
- func ErrVoterNotFound() sdk.Error
- func InitGlobalManager(ctx sdk.Context, gm global.GlobalManager) error
- func NewHandler(am acc.AccountManager, proposalManager ProposalManager, ...) sdk.Handler
- func RegisterWire(cdc *wire.Codec)
- type ChangeAccountParamMsg
- func (msg ChangeAccountParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeAccountParamMsg) GetCreator() types.AccountKey
- func (msg ChangeAccountParamMsg) GetParameter() param.Parameter
- func (msg ChangeAccountParamMsg) GetPermission() types.Permission
- func (msg ChangeAccountParamMsg) GetReason() string
- func (msg ChangeAccountParamMsg) GetSignBytes() []byte
- func (msg ChangeAccountParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeAccountParamMsg) String() string
- func (msg ChangeAccountParamMsg) Type() string
- func (msg ChangeAccountParamMsg) ValidateBasic() sdk.Error
- type ChangeBandwidthParamMsg
- func (msg ChangeBandwidthParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeBandwidthParamMsg) GetCreator() types.AccountKey
- func (msg ChangeBandwidthParamMsg) GetParameter() param.Parameter
- func (msg ChangeBandwidthParamMsg) GetPermission() types.Permission
- func (msg ChangeBandwidthParamMsg) GetReason() string
- func (msg ChangeBandwidthParamMsg) GetSignBytes() []byte
- func (msg ChangeBandwidthParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeBandwidthParamMsg) String() string
- func (msg ChangeBandwidthParamMsg) Type() string
- func (msg ChangeBandwidthParamMsg) ValidateBasic() sdk.Error
- type ChangeDeveloperParamMsg
- func (msg ChangeDeveloperParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeDeveloperParamMsg) GetCreator() types.AccountKey
- func (msg ChangeDeveloperParamMsg) GetParameter() param.Parameter
- func (msg ChangeDeveloperParamMsg) GetPermission() types.Permission
- func (msg ChangeDeveloperParamMsg) GetReason() string
- func (msg ChangeDeveloperParamMsg) GetSignBytes() []byte
- func (msg ChangeDeveloperParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeDeveloperParamMsg) String() string
- func (msg ChangeDeveloperParamMsg) Type() string
- func (msg ChangeDeveloperParamMsg) ValidateBasic() sdk.Error
- type ChangeEvaluateOfContentValueParamMsg
- func (msg ChangeEvaluateOfContentValueParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeEvaluateOfContentValueParamMsg) GetCreator() types.AccountKey
- func (msg ChangeEvaluateOfContentValueParamMsg) GetParameter() param.Parameter
- func (msg ChangeEvaluateOfContentValueParamMsg) GetPermission() types.Permission
- func (msg ChangeEvaluateOfContentValueParamMsg) GetReason() string
- func (msg ChangeEvaluateOfContentValueParamMsg) GetSignBytes() []byte
- func (msg ChangeEvaluateOfContentValueParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeEvaluateOfContentValueParamMsg) String() string
- func (msg ChangeEvaluateOfContentValueParamMsg) Type() string
- func (msg ChangeEvaluateOfContentValueParamMsg) ValidateBasic() sdk.Error
- type ChangeGlobalAllocationParamMsg
- func (msg ChangeGlobalAllocationParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeGlobalAllocationParamMsg) GetCreator() types.AccountKey
- func (msg ChangeGlobalAllocationParamMsg) GetParameter() param.Parameter
- func (msg ChangeGlobalAllocationParamMsg) GetPermission() types.Permission
- func (msg ChangeGlobalAllocationParamMsg) GetReason() string
- func (msg ChangeGlobalAllocationParamMsg) GetSignBytes() []byte
- func (msg ChangeGlobalAllocationParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeGlobalAllocationParamMsg) String() string
- func (msg ChangeGlobalAllocationParamMsg) Type() string
- func (msg ChangeGlobalAllocationParamMsg) ValidateBasic() sdk.Error
- type ChangeInfraInternalAllocationParamMsg
- func (msg ChangeInfraInternalAllocationParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeInfraInternalAllocationParamMsg) GetCreator() types.AccountKey
- func (msg ChangeInfraInternalAllocationParamMsg) GetParameter() param.Parameter
- func (msg ChangeInfraInternalAllocationParamMsg) GetPermission() types.Permission
- func (msg ChangeInfraInternalAllocationParamMsg) GetReason() string
- func (msg ChangeInfraInternalAllocationParamMsg) GetSignBytes() []byte
- func (msg ChangeInfraInternalAllocationParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeInfraInternalAllocationParamMsg) String() string
- func (msg ChangeInfraInternalAllocationParamMsg) Type() string
- func (msg ChangeInfraInternalAllocationParamMsg) ValidateBasic() sdk.Error
- type ChangeParamMsg
- type ChangePostParamMsg
- func (msg ChangePostParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangePostParamMsg) GetCreator() types.AccountKey
- func (msg ChangePostParamMsg) GetParameter() param.Parameter
- func (msg ChangePostParamMsg) GetPermission() types.Permission
- func (msg ChangePostParamMsg) GetReason() string
- func (msg ChangePostParamMsg) GetSignBytes() []byte
- func (msg ChangePostParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangePostParamMsg) String() string
- func (msg ChangePostParamMsg) Type() string
- func (msg ChangePostParamMsg) ValidateBasic() sdk.Error
- type ChangeProposalParamMsg
- func (msg ChangeProposalParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeProposalParamMsg) GetCreator() types.AccountKey
- func (msg ChangeProposalParamMsg) GetParameter() param.Parameter
- func (msg ChangeProposalParamMsg) GetPermission() types.Permission
- func (msg ChangeProposalParamMsg) GetReason() string
- func (msg ChangeProposalParamMsg) GetSignBytes() []byte
- func (msg ChangeProposalParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeProposalParamMsg) String() string
- func (msg ChangeProposalParamMsg) Type() string
- func (msg ChangeProposalParamMsg) ValidateBasic() sdk.Error
- type ChangeValidatorParamMsg
- func (msg ChangeValidatorParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeValidatorParamMsg) GetCreator() types.AccountKey
- func (msg ChangeValidatorParamMsg) GetParameter() param.Parameter
- func (msg ChangeValidatorParamMsg) GetPermission() types.Permission
- func (msg ChangeValidatorParamMsg) GetReason() string
- func (msg ChangeValidatorParamMsg) GetSignBytes() []byte
- func (msg ChangeValidatorParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeValidatorParamMsg) String() string
- func (msg ChangeValidatorParamMsg) Type() string
- func (msg ChangeValidatorParamMsg) ValidateBasic() sdk.Error
- type ChangeVoteParamMsg
- func (msg ChangeVoteParamMsg) GetConsumeAmount() types.Coin
- func (msg ChangeVoteParamMsg) GetCreator() types.AccountKey
- func (msg ChangeVoteParamMsg) GetParameter() param.Parameter
- func (msg ChangeVoteParamMsg) GetPermission() types.Permission
- func (msg ChangeVoteParamMsg) GetReason() string
- func (msg ChangeVoteParamMsg) GetSignBytes() []byte
- func (msg ChangeVoteParamMsg) GetSigners() []sdk.AccAddress
- func (msg ChangeVoteParamMsg) String() string
- func (msg ChangeVoteParamMsg) Type() string
- func (msg ChangeVoteParamMsg) ValidateBasic() sdk.Error
- type ContentCensorshipMsg
- type DecideProposalEvent
- func (dpe DecideProposalEvent) Execute(ctx sdk.Context, voteManager vote.VoteManager, valManager val.ValidatorManager, ...) sdk.Error
- func (dpe DecideProposalEvent) ExecuteChangeParam(ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager, ...) sdk.Error
- func (dpe DecideProposalEvent) ExecuteContentCensorship(ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager, ...) sdk.Error
- func (dpe DecideProposalEvent) ExecuteProtocolUpgrade(ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager) sdk.Error
- type DeletePostContentMsg
- func (msg DeletePostContentMsg) GetConsumeAmount() types.Coin
- func (msg DeletePostContentMsg) GetCreator() types.AccountKey
- func (msg DeletePostContentMsg) GetPermission() types.Permission
- func (msg DeletePostContentMsg) GetPermlink() types.Permlink
- func (msg DeletePostContentMsg) GetReason() string
- func (msg DeletePostContentMsg) GetSignBytes() []byte
- func (msg DeletePostContentMsg) GetSigners() []sdk.AccAddress
- func (msg DeletePostContentMsg) String() string
- func (msg DeletePostContentMsg) Type() string
- func (msg DeletePostContentMsg) ValidateBasic() sdk.Error
- type ProposalManager
- func (pm ProposalManager) AddProposal(ctx sdk.Context, creator types.AccountKey, proposal model.Proposal, ...) (types.ProposalKey, sdk.Error)
- func (pm ProposalManager) CreateChangeParamProposal(ctx sdk.Context, parameter param.Parameter, reason string) model.Proposal
- func (pm ProposalManager) CreateContentCensorshipProposal(ctx sdk.Context, permlink types.Permlink, reason string) model.Proposal
- func (pm ProposalManager) CreateDecideProposalEvent(ctx sdk.Context, proposalType types.ProposalType, proposalID types.ProposalKey) (types.Event, sdk.Error)
- func (pm ProposalManager) CreateParamChangeEvent(ctx sdk.Context, proposalID types.ProposalKey) (types.Event, sdk.Error)
- func (pm ProposalManager) CreateProtocolUpgradeProposal(ctx sdk.Context, link string, reason string) model.Proposal
- func (pm ProposalManager) DoesProposalExist(ctx sdk.Context, proposalID types.ProposalKey) bool
- func (pm ProposalManager) GetNextProposalID(ctx sdk.Context) (types.ProposalKey, sdk.Error)
- func (pm ProposalManager) GetPermlink(ctx sdk.Context, proposalID types.ProposalKey) (types.Permlink, sdk.Error)
- func (pm ProposalManager) GetProposalList(ctx sdk.Context) (*model.ProposalList, sdk.Error)
- func (pm ProposalManager) GetProposalPassParam(ctx sdk.Context, proposalType types.ProposalType) (sdk.Rat, types.Coin, sdk.Error)
- func (pm ProposalManager) IncreaseNextProposalID(ctx sdk.Context) sdk.Error
- func (pm ProposalManager) InitGenesis(ctx sdk.Context) error
- func (pm ProposalManager) IsOngoingProposal(ctx sdk.Context, proposalID types.ProposalKey) bool
- func (pm ProposalManager) UpdateProposalPassStatus(ctx sdk.Context, proposalType types.ProposalType, proposalID types.ProposalKey) (types.ProposalResult, sdk.Error)
- func (pm ProposalManager) UpdateProposalVotingStatus(ctx sdk.Context, proposalID types.ProposalKey, voter types.AccountKey, ...) sdk.Error
- type ProtocolUpgradeMsg
- type UpgradeProtocolMsg
- func (msg UpgradeProtocolMsg) GetConsumeAmount() types.Coin
- func (msg UpgradeProtocolMsg) GetCreator() types.AccountKey
- func (msg UpgradeProtocolMsg) GetLink() string
- func (msg UpgradeProtocolMsg) GetPermission() types.Permission
- func (msg UpgradeProtocolMsg) GetReason() string
- func (msg UpgradeProtocolMsg) GetSignBytes() []byte
- func (msg UpgradeProtocolMsg) GetSigners() []sdk.AccAddress
- func (msg UpgradeProtocolMsg) String() string
- func (msg UpgradeProtocolMsg) Type() string
- func (msg UpgradeProtocolMsg) ValidateBasic() sdk.Error
- type VoteProposalMsg
- func (msg VoteProposalMsg) GetConsumeAmount() types.Coin
- func (msg VoteProposalMsg) GetPermission() types.Permission
- func (msg VoteProposalMsg) GetSignBytes() []byte
- func (msg VoteProposalMsg) GetSigners() []sdk.AccAddress
- func (msg VoteProposalMsg) String() string
- func (msg VoteProposalMsg) Type() string
- func (msg VoteProposalMsg) ValidateBasic() sdk.Error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( TestAccountKVStoreKey = sdk.NewKVStoreKey("account") TestGlobalKVStoreKey = sdk.NewKVStoreKey("global") TestProposalKVStoreKey = sdk.NewKVStoreKey("proposal") TestVoteKVStoreKey = sdk.NewKVStoreKey("vote") TestParamKVStoreKey = sdk.NewKVStoreKey("param") TestValidatorKVStoreKey = sdk.NewKVStoreKey("validator") TestPostKVStoreKey = sdk.NewKVStoreKey("post") )
Construct some global addrs and txs for tests.
Functions ¶
func ErrAccountNotFound ¶
func ErrIllegalParameter ¶
func ErrInvalidLink ¶
func ErrInvalidPermlink ¶
func ErrInvalidUsername ¶
func ErrNotOngoingProposal ¶
func ErrPostNotFound ¶
func ErrReasonTooLong ¶
func ErrVoterNotFound ¶
func InitGlobalManager ¶
func InitGlobalManager(ctx sdk.Context, gm global.GlobalManager) error
func NewHandler ¶
func NewHandler( am acc.AccountManager, proposalManager ProposalManager, postManager post.PostManager, gm global.GlobalManager, vm vote.VoteManager) sdk.Handler
Types ¶
type ChangeAccountParamMsg ¶
type ChangeAccountParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.AccountParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeAccountParamMsg ¶
func NewChangeAccountParamMsg( creator string, parameter param.AccountParam, reason string) ChangeAccountParamMsg
func (ChangeAccountParamMsg) GetConsumeAmount ¶
func (msg ChangeAccountParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeAccountParamMsg) GetCreator ¶
func (msg ChangeAccountParamMsg) GetCreator() types.AccountKey
func (ChangeAccountParamMsg) GetParameter ¶
func (msg ChangeAccountParamMsg) GetParameter() param.Parameter
func (ChangeAccountParamMsg) GetPermission ¶
func (msg ChangeAccountParamMsg) GetPermission() types.Permission
func (ChangeAccountParamMsg) GetReason ¶
func (msg ChangeAccountParamMsg) GetReason() string
func (ChangeAccountParamMsg) GetSignBytes ¶
func (msg ChangeAccountParamMsg) GetSignBytes() []byte
func (ChangeAccountParamMsg) GetSigners ¶
func (msg ChangeAccountParamMsg) GetSigners() []sdk.AccAddress
func (ChangeAccountParamMsg) String ¶
func (msg ChangeAccountParamMsg) String() string
func (ChangeAccountParamMsg) Type ¶
func (msg ChangeAccountParamMsg) Type() string
func (ChangeAccountParamMsg) ValidateBasic ¶
func (msg ChangeAccountParamMsg) ValidateBasic() sdk.Error
type ChangeBandwidthParamMsg ¶
type ChangeBandwidthParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.BandwidthParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeBandwidthParamMsg ¶
func NewChangeBandwidthParamMsg( creator string, parameter param.BandwidthParam, reason string) ChangeBandwidthParamMsg
func (ChangeBandwidthParamMsg) GetConsumeAmount ¶
func (msg ChangeBandwidthParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeBandwidthParamMsg) GetCreator ¶
func (msg ChangeBandwidthParamMsg) GetCreator() types.AccountKey
func (ChangeBandwidthParamMsg) GetParameter ¶
func (msg ChangeBandwidthParamMsg) GetParameter() param.Parameter
func (ChangeBandwidthParamMsg) GetPermission ¶
func (msg ChangeBandwidthParamMsg) GetPermission() types.Permission
func (ChangeBandwidthParamMsg) GetReason ¶
func (msg ChangeBandwidthParamMsg) GetReason() string
func (ChangeBandwidthParamMsg) GetSignBytes ¶
func (msg ChangeBandwidthParamMsg) GetSignBytes() []byte
func (ChangeBandwidthParamMsg) GetSigners ¶
func (msg ChangeBandwidthParamMsg) GetSigners() []sdk.AccAddress
func (ChangeBandwidthParamMsg) String ¶
func (msg ChangeBandwidthParamMsg) String() string
func (ChangeBandwidthParamMsg) Type ¶
func (msg ChangeBandwidthParamMsg) Type() string
func (ChangeBandwidthParamMsg) ValidateBasic ¶
func (msg ChangeBandwidthParamMsg) ValidateBasic() sdk.Error
type ChangeDeveloperParamMsg ¶
type ChangeDeveloperParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.DeveloperParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeDeveloperParamMsg ¶
func NewChangeDeveloperParamMsg( creator string, parameter param.DeveloperParam, reason string) ChangeDeveloperParamMsg
func (ChangeDeveloperParamMsg) GetConsumeAmount ¶
func (msg ChangeDeveloperParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeDeveloperParamMsg) GetCreator ¶
func (msg ChangeDeveloperParamMsg) GetCreator() types.AccountKey
func (ChangeDeveloperParamMsg) GetParameter ¶
func (msg ChangeDeveloperParamMsg) GetParameter() param.Parameter
func (ChangeDeveloperParamMsg) GetPermission ¶
func (msg ChangeDeveloperParamMsg) GetPermission() types.Permission
func (ChangeDeveloperParamMsg) GetReason ¶
func (msg ChangeDeveloperParamMsg) GetReason() string
func (ChangeDeveloperParamMsg) GetSignBytes ¶
func (msg ChangeDeveloperParamMsg) GetSignBytes() []byte
func (ChangeDeveloperParamMsg) GetSigners ¶
func (msg ChangeDeveloperParamMsg) GetSigners() []sdk.AccAddress
func (ChangeDeveloperParamMsg) String ¶
func (msg ChangeDeveloperParamMsg) String() string
func (ChangeDeveloperParamMsg) Type ¶
func (msg ChangeDeveloperParamMsg) Type() string
func (ChangeDeveloperParamMsg) ValidateBasic ¶
func (msg ChangeDeveloperParamMsg) ValidateBasic() sdk.Error
type ChangeEvaluateOfContentValueParamMsg ¶
type ChangeEvaluateOfContentValueParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.EvaluateOfContentValueParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeEvaluateOfContentValueParamMsg ¶
func NewChangeEvaluateOfContentValueParamMsg( creator string, parameter param.EvaluateOfContentValueParam, reason string) ChangeEvaluateOfContentValueParamMsg
func (ChangeEvaluateOfContentValueParamMsg) GetConsumeAmount ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeEvaluateOfContentValueParamMsg) GetCreator ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetCreator() types.AccountKey
func (ChangeEvaluateOfContentValueParamMsg) GetParameter ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetParameter() param.Parameter
func (ChangeEvaluateOfContentValueParamMsg) GetPermission ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetPermission() types.Permission
func (ChangeEvaluateOfContentValueParamMsg) GetReason ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetReason() string
func (ChangeEvaluateOfContentValueParamMsg) GetSignBytes ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetSignBytes() []byte
func (ChangeEvaluateOfContentValueParamMsg) GetSigners ¶
func (msg ChangeEvaluateOfContentValueParamMsg) GetSigners() []sdk.AccAddress
func (ChangeEvaluateOfContentValueParamMsg) String ¶
func (msg ChangeEvaluateOfContentValueParamMsg) String() string
func (ChangeEvaluateOfContentValueParamMsg) Type ¶
func (msg ChangeEvaluateOfContentValueParamMsg) Type() string
func (ChangeEvaluateOfContentValueParamMsg) ValidateBasic ¶
func (msg ChangeEvaluateOfContentValueParamMsg) ValidateBasic() sdk.Error
type ChangeGlobalAllocationParamMsg ¶
type ChangeGlobalAllocationParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.GlobalAllocationParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeGlobalAllocationParamMsg ¶
func NewChangeGlobalAllocationParamMsg( creator string, parameter param.GlobalAllocationParam, reason string) ChangeGlobalAllocationParamMsg
func (ChangeGlobalAllocationParamMsg) GetConsumeAmount ¶
func (msg ChangeGlobalAllocationParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeGlobalAllocationParamMsg) GetCreator ¶
func (msg ChangeGlobalAllocationParamMsg) GetCreator() types.AccountKey
func (ChangeGlobalAllocationParamMsg) GetParameter ¶
func (msg ChangeGlobalAllocationParamMsg) GetParameter() param.Parameter
func (ChangeGlobalAllocationParamMsg) GetPermission ¶
func (msg ChangeGlobalAllocationParamMsg) GetPermission() types.Permission
func (ChangeGlobalAllocationParamMsg) GetReason ¶
func (msg ChangeGlobalAllocationParamMsg) GetReason() string
func (ChangeGlobalAllocationParamMsg) GetSignBytes ¶
func (msg ChangeGlobalAllocationParamMsg) GetSignBytes() []byte
func (ChangeGlobalAllocationParamMsg) GetSigners ¶
func (msg ChangeGlobalAllocationParamMsg) GetSigners() []sdk.AccAddress
func (ChangeGlobalAllocationParamMsg) String ¶
func (msg ChangeGlobalAllocationParamMsg) String() string
func (ChangeGlobalAllocationParamMsg) Type ¶
func (msg ChangeGlobalAllocationParamMsg) Type() string
func (ChangeGlobalAllocationParamMsg) ValidateBasic ¶
func (msg ChangeGlobalAllocationParamMsg) ValidateBasic() sdk.Error
type ChangeInfraInternalAllocationParamMsg ¶
type ChangeInfraInternalAllocationParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.InfraInternalAllocationParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeInfraInternalAllocationParamMsg ¶
func NewChangeInfraInternalAllocationParamMsg( creator string, parameter param.InfraInternalAllocationParam, reason string) ChangeInfraInternalAllocationParamMsg
func (ChangeInfraInternalAllocationParamMsg) GetConsumeAmount ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeInfraInternalAllocationParamMsg) GetCreator ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetCreator() types.AccountKey
func (ChangeInfraInternalAllocationParamMsg) GetParameter ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetParameter() param.Parameter
func (ChangeInfraInternalAllocationParamMsg) GetPermission ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetPermission() types.Permission
func (ChangeInfraInternalAllocationParamMsg) GetReason ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetReason() string
func (ChangeInfraInternalAllocationParamMsg) GetSignBytes ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetSignBytes() []byte
func (ChangeInfraInternalAllocationParamMsg) GetSigners ¶
func (msg ChangeInfraInternalAllocationParamMsg) GetSigners() []sdk.AccAddress
func (ChangeInfraInternalAllocationParamMsg) String ¶
func (msg ChangeInfraInternalAllocationParamMsg) String() string
func (ChangeInfraInternalAllocationParamMsg) Type ¶
func (msg ChangeInfraInternalAllocationParamMsg) Type() string
func (ChangeInfraInternalAllocationParamMsg) ValidateBasic ¶
func (msg ChangeInfraInternalAllocationParamMsg) ValidateBasic() sdk.Error
type ChangeParamMsg ¶
type ChangeParamMsg interface {
GetParameter() param.Parameter
GetCreator() types.AccountKey
GetReason() string
}
type ChangePostParamMsg ¶
type ChangePostParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.PostParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangePostParamMsg ¶
func NewChangePostParamMsg( creator string, parameter param.PostParam, reason string) ChangePostParamMsg
func (ChangePostParamMsg) GetConsumeAmount ¶
func (msg ChangePostParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangePostParamMsg) GetCreator ¶
func (msg ChangePostParamMsg) GetCreator() types.AccountKey
func (ChangePostParamMsg) GetParameter ¶
func (msg ChangePostParamMsg) GetParameter() param.Parameter
func (ChangePostParamMsg) GetPermission ¶
func (msg ChangePostParamMsg) GetPermission() types.Permission
func (ChangePostParamMsg) GetReason ¶
func (msg ChangePostParamMsg) GetReason() string
func (ChangePostParamMsg) GetSignBytes ¶
func (msg ChangePostParamMsg) GetSignBytes() []byte
func (ChangePostParamMsg) GetSigners ¶
func (msg ChangePostParamMsg) GetSigners() []sdk.AccAddress
func (ChangePostParamMsg) String ¶
func (msg ChangePostParamMsg) String() string
func (ChangePostParamMsg) Type ¶
func (msg ChangePostParamMsg) Type() string
func (ChangePostParamMsg) ValidateBasic ¶
func (msg ChangePostParamMsg) ValidateBasic() sdk.Error
type ChangeProposalParamMsg ¶
type ChangeProposalParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.ProposalParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeProposalParamMsg ¶
func NewChangeProposalParamMsg( creator string, parameter param.ProposalParam, reason string) ChangeProposalParamMsg
func (ChangeProposalParamMsg) GetConsumeAmount ¶
func (msg ChangeProposalParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeProposalParamMsg) GetCreator ¶
func (msg ChangeProposalParamMsg) GetCreator() types.AccountKey
func (ChangeProposalParamMsg) GetParameter ¶
func (msg ChangeProposalParamMsg) GetParameter() param.Parameter
func (ChangeProposalParamMsg) GetPermission ¶
func (msg ChangeProposalParamMsg) GetPermission() types.Permission
func (ChangeProposalParamMsg) GetReason ¶
func (msg ChangeProposalParamMsg) GetReason() string
func (ChangeProposalParamMsg) GetSignBytes ¶
func (msg ChangeProposalParamMsg) GetSignBytes() []byte
func (ChangeProposalParamMsg) GetSigners ¶
func (msg ChangeProposalParamMsg) GetSigners() []sdk.AccAddress
func (ChangeProposalParamMsg) String ¶
func (msg ChangeProposalParamMsg) String() string
func (ChangeProposalParamMsg) Type ¶
func (msg ChangeProposalParamMsg) Type() string
func (ChangeProposalParamMsg) ValidateBasic ¶
func (msg ChangeProposalParamMsg) ValidateBasic() sdk.Error
type ChangeValidatorParamMsg ¶
type ChangeValidatorParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.ValidatorParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeValidatorParamMsg ¶
func NewChangeValidatorParamMsg(creator string, parameter param.ValidatorParam, reason string) ChangeValidatorParamMsg
func (ChangeValidatorParamMsg) GetConsumeAmount ¶
func (msg ChangeValidatorParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeValidatorParamMsg) GetCreator ¶
func (msg ChangeValidatorParamMsg) GetCreator() types.AccountKey
func (ChangeValidatorParamMsg) GetParameter ¶
func (msg ChangeValidatorParamMsg) GetParameter() param.Parameter
func (ChangeValidatorParamMsg) GetPermission ¶
func (msg ChangeValidatorParamMsg) GetPermission() types.Permission
func (ChangeValidatorParamMsg) GetReason ¶
func (msg ChangeValidatorParamMsg) GetReason() string
func (ChangeValidatorParamMsg) GetSignBytes ¶
func (msg ChangeValidatorParamMsg) GetSignBytes() []byte
func (ChangeValidatorParamMsg) GetSigners ¶
func (msg ChangeValidatorParamMsg) GetSigners() []sdk.AccAddress
func (ChangeValidatorParamMsg) String ¶
func (msg ChangeValidatorParamMsg) String() string
func (ChangeValidatorParamMsg) Type ¶
func (msg ChangeValidatorParamMsg) Type() string
func (ChangeValidatorParamMsg) ValidateBasic ¶
func (msg ChangeValidatorParamMsg) ValidateBasic() sdk.Error
type ChangeVoteParamMsg ¶
type ChangeVoteParamMsg struct {
Creator types.AccountKey `json:"creator"`
Parameter param.VoteParam `json:"parameter"`
Reason string `json:"reason"`
}
func NewChangeVoteParamMsg ¶
func NewChangeVoteParamMsg( creator string, parameter param.VoteParam, reason string) ChangeVoteParamMsg
func (ChangeVoteParamMsg) GetConsumeAmount ¶
func (msg ChangeVoteParamMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (ChangeVoteParamMsg) GetCreator ¶
func (msg ChangeVoteParamMsg) GetCreator() types.AccountKey
func (ChangeVoteParamMsg) GetParameter ¶
func (msg ChangeVoteParamMsg) GetParameter() param.Parameter
func (ChangeVoteParamMsg) GetPermission ¶
func (msg ChangeVoteParamMsg) GetPermission() types.Permission
func (ChangeVoteParamMsg) GetReason ¶
func (msg ChangeVoteParamMsg) GetReason() string
func (ChangeVoteParamMsg) GetSignBytes ¶
func (msg ChangeVoteParamMsg) GetSignBytes() []byte
func (ChangeVoteParamMsg) GetSigners ¶
func (msg ChangeVoteParamMsg) GetSigners() []sdk.AccAddress
func (ChangeVoteParamMsg) String ¶
func (msg ChangeVoteParamMsg) String() string
func (ChangeVoteParamMsg) Type ¶
func (msg ChangeVoteParamMsg) Type() string
func (ChangeVoteParamMsg) ValidateBasic ¶
func (msg ChangeVoteParamMsg) ValidateBasic() sdk.Error
type ContentCensorshipMsg ¶
type ContentCensorshipMsg interface {
GetCreator() types.AccountKey
GetPermlink() types.Permlink
GetReason() string
}
type DecideProposalEvent ¶
type DecideProposalEvent struct {
ProposalType types.ProposalType `json:"proposal_type"`
ProposalID types.ProposalKey `json:"proposal_id"`
}
func (DecideProposalEvent) Execute ¶
func (dpe DecideProposalEvent) Execute( ctx sdk.Context, voteManager vote.VoteManager, valManager val.ValidatorManager, am acc.AccountManager, proposalManager ProposalManager, postManager post.PostManager, gm global.GlobalManager) sdk.Error
func (DecideProposalEvent) ExecuteChangeParam ¶
func (dpe DecideProposalEvent) ExecuteChangeParam( ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager, gm global.GlobalManager) sdk.Error
func (DecideProposalEvent) ExecuteContentCensorship ¶
func (dpe DecideProposalEvent) ExecuteContentCensorship( ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager, postManager post.PostManager) sdk.Error
func (DecideProposalEvent) ExecuteProtocolUpgrade ¶
func (dpe DecideProposalEvent) ExecuteProtocolUpgrade( ctx sdk.Context, curID types.ProposalKey, proposalManager ProposalManager) sdk.Error
type DeletePostContentMsg ¶
type DeletePostContentMsg struct {
Creator types.AccountKey `json:"creator"`
Permlink types.Permlink `json:"permlink"`
Reason string `json:"reason"`
}
func NewDeletePostContentMsg ¶
func NewDeletePostContentMsg( creator string, permlink types.Permlink, reason string) DeletePostContentMsg
func (DeletePostContentMsg) GetConsumeAmount ¶
func (msg DeletePostContentMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (DeletePostContentMsg) GetCreator ¶
func (msg DeletePostContentMsg) GetCreator() types.AccountKey
func (DeletePostContentMsg) GetPermission ¶
func (msg DeletePostContentMsg) GetPermission() types.Permission
func (DeletePostContentMsg) GetPermlink ¶
func (msg DeletePostContentMsg) GetPermlink() types.Permlink
func (DeletePostContentMsg) GetReason ¶
func (msg DeletePostContentMsg) GetReason() string
func (DeletePostContentMsg) GetSignBytes ¶
func (msg DeletePostContentMsg) GetSignBytes() []byte
func (DeletePostContentMsg) GetSigners ¶
func (msg DeletePostContentMsg) GetSigners() []sdk.AccAddress
func (DeletePostContentMsg) String ¶
func (msg DeletePostContentMsg) String() string
func (DeletePostContentMsg) Type ¶
func (msg DeletePostContentMsg) Type() string
func (DeletePostContentMsg) ValidateBasic ¶
func (msg DeletePostContentMsg) ValidateBasic() sdk.Error
type ProposalManager ¶
type ProposalManager struct {
// contains filtered or unexported fields
}
func NewProposalManager ¶
func NewProposalManager(key sdk.StoreKey, holder param.ParamHolder) ProposalManager
func (ProposalManager) AddProposal ¶
func (pm ProposalManager) AddProposal( ctx sdk.Context, creator types.AccountKey, proposal model.Proposal, decideHr int64) (types.ProposalKey, sdk.Error)
func (ProposalManager) CreateChangeParamProposal ¶
func (ProposalManager) CreateContentCensorshipProposal ¶
func (ProposalManager) CreateDecideProposalEvent ¶
func (pm ProposalManager) CreateDecideProposalEvent( ctx sdk.Context, proposalType types.ProposalType, proposalID types.ProposalKey) (types.Event, sdk.Error)
func (ProposalManager) CreateParamChangeEvent ¶
func (pm ProposalManager) CreateParamChangeEvent( ctx sdk.Context, proposalID types.ProposalKey) (types.Event, sdk.Error)
func (ProposalManager) CreateProtocolUpgradeProposal ¶
func (ProposalManager) DoesProposalExist ¶
func (pm ProposalManager) DoesProposalExist(ctx sdk.Context, proposalID types.ProposalKey) bool
func (ProposalManager) GetNextProposalID ¶
func (pm ProposalManager) GetNextProposalID(ctx sdk.Context) (types.ProposalKey, sdk.Error)
func (ProposalManager) GetPermlink ¶
func (pm ProposalManager) GetPermlink(ctx sdk.Context, proposalID types.ProposalKey) (types.Permlink, sdk.Error)
func (ProposalManager) GetProposalList ¶
func (pm ProposalManager) GetProposalList(ctx sdk.Context) (*model.ProposalList, sdk.Error)
func (ProposalManager) GetProposalPassParam ¶
func (ProposalManager) IncreaseNextProposalID ¶
func (pm ProposalManager) IncreaseNextProposalID(ctx sdk.Context) sdk.Error
func (ProposalManager) InitGenesis ¶
func (pm ProposalManager) InitGenesis(ctx sdk.Context) error
func (ProposalManager) IsOngoingProposal ¶
func (pm ProposalManager) IsOngoingProposal(ctx sdk.Context, proposalID types.ProposalKey) bool
func (ProposalManager) UpdateProposalPassStatus ¶
func (pm ProposalManager) UpdateProposalPassStatus( ctx sdk.Context, proposalType types.ProposalType, proposalID types.ProposalKey) (types.ProposalResult, sdk.Error)
func (ProposalManager) UpdateProposalVotingStatus ¶
func (pm ProposalManager) UpdateProposalVotingStatus(ctx sdk.Context, proposalID types.ProposalKey, voter types.AccountKey, voteResult bool, votingPower types.Coin) sdk.Error
type ProtocolUpgradeMsg ¶
type ProtocolUpgradeMsg interface {
GetCreator() types.AccountKey
GetLink() string
GetReason() string
}
type UpgradeProtocolMsg ¶
type UpgradeProtocolMsg struct {
Creator types.AccountKey `json:"creator"`
Link string `json:"link"`
Reason string `json:"reason"`
}
func NewUpgradeProtocolMsg ¶
func NewUpgradeProtocolMsg( creator, link, reason string) UpgradeProtocolMsg
func (UpgradeProtocolMsg) GetConsumeAmount ¶
func (msg UpgradeProtocolMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (UpgradeProtocolMsg) GetCreator ¶
func (msg UpgradeProtocolMsg) GetCreator() types.AccountKey
func (UpgradeProtocolMsg) GetLink ¶
func (msg UpgradeProtocolMsg) GetLink() string
func (UpgradeProtocolMsg) GetPermission ¶
func (msg UpgradeProtocolMsg) GetPermission() types.Permission
func (UpgradeProtocolMsg) GetReason ¶
func (msg UpgradeProtocolMsg) GetReason() string
func (UpgradeProtocolMsg) GetSignBytes ¶
func (msg UpgradeProtocolMsg) GetSignBytes() []byte
func (UpgradeProtocolMsg) GetSigners ¶
func (msg UpgradeProtocolMsg) GetSigners() []sdk.AccAddress
func (UpgradeProtocolMsg) String ¶
func (msg UpgradeProtocolMsg) String() string
func (UpgradeProtocolMsg) Type ¶
func (msg UpgradeProtocolMsg) Type() string
func (UpgradeProtocolMsg) ValidateBasic ¶
func (msg UpgradeProtocolMsg) ValidateBasic() sdk.Error
type VoteProposalMsg ¶
type VoteProposalMsg struct {
Voter types.AccountKey `json:"voter"`
ProposalID types.ProposalKey `json:"proposal_id"`
Result bool `json:"result"`
}
func NewVoteProposalMsg ¶
func NewVoteProposalMsg(voter string, proposalID int64, result bool) VoteProposalMsg
func (VoteProposalMsg) GetConsumeAmount ¶
func (msg VoteProposalMsg) GetConsumeAmount() types.Coin
Implements Msg.
func (VoteProposalMsg) GetPermission ¶
func (msg VoteProposalMsg) GetPermission() types.Permission
func (VoteProposalMsg) GetSignBytes ¶
func (msg VoteProposalMsg) GetSignBytes() []byte
func (VoteProposalMsg) GetSigners ¶
func (msg VoteProposalMsg) GetSigners() []sdk.AccAddress
func (VoteProposalMsg) String ¶
func (msg VoteProposalMsg) String() string
func (VoteProposalMsg) Type ¶
func (msg VoteProposalMsg) Type() string
func (VoteProposalMsg) ValidateBasic ¶
func (msg VoteProposalMsg) ValidateBasic() sdk.Error
Click to show internal directories.
Click to hide internal directories.