Versions in this module Expand all Collapse all v0 v0.6.2 Nov 14, 2018 v0.6.1 Nov 12, 2018 Changes in this version + const CodeDuplicateTags + const CodeInvalidAuthor + const CodeInvalidBindingType + const CodeInvalidChainId + const CodeInvalidDefChainId + const CodeInvalidExpiration + const CodeInvalidIDL + const CodeInvalidLevel + const CodeInvalidMessagingType + const CodeInvalidMethodName + const CodeInvalidOutputCachedEnum + const CodeInvalidOutputPrivacyEnum + const CodeInvalidPriceCount + const CodeInvalidServiceName + const CodeInvalidUpdate + const CodeMoreTags + const CodeRefundDeposit + const CodeSvcBindingExists + const CodeSvcBindingNotExists + const CodeSvcDefExists + const CodeSvcDefNotExists + const DefaultCodespace + const MsgType + func ErrDuplicateTags(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidAuthor(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidBindingType(codespace sdk.CodespaceType, bindingType BindingType) sdk.Error + func ErrInvalidChainId(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidDefChainId(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidExpiration(codespace sdk.CodespaceType, expiration int64) sdk.Error + func ErrInvalidIDL(codespace sdk.CodespaceType, msg string) sdk.Error + func ErrInvalidLevel(codespace sdk.CodespaceType, level Level) sdk.Error + func ErrInvalidMessagingType(codespace sdk.CodespaceType, value MessagingType) sdk.Error + func ErrInvalidMethodName(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidOutputCachedEnum(codespace sdk.CodespaceType, value string) sdk.Error + func ErrInvalidOutputPrivacyEnum(codespace sdk.CodespaceType, value string) sdk.Error + func ErrInvalidPriceCount(codespace sdk.CodespaceType, priceCount int, methodCount int) sdk.Error + func ErrInvalidServiceName(codespace sdk.CodespaceType) sdk.Error + func ErrInvalidUpdate(codespace sdk.CodespaceType, msg string) sdk.Error + func ErrLtMinProviderDeposit(codespace sdk.CodespaceType, coins sdk.Coins) sdk.Error + func ErrMoreTags(codespace sdk.CodespaceType) sdk.Error + func ErrRefundDeposit(codespace sdk.CodespaceType, msg string) sdk.Error + func ErrSvcBindingExists(codespace sdk.CodespaceType) sdk.Error + func ErrSvcBindingNotExists(codespace sdk.CodespaceType) sdk.Error + func ErrSvcDefExists(codespace sdk.CodespaceType, defChainId, svcDefName string) sdk.Error + func ErrSvcDefNotExists(codespace sdk.CodespaceType, defChainId, svcDefName string) sdk.Error + func GetBindingsSubspaceKey(chainId, serviceName string) []byte + func GetMethodPropertyKey(chainId, serviceName string, id int) []byte + func GetMethodsSubspaceKey(chainId, serviceName string) []byte + func GetServiceBindingKey(defChainId, name, bindChainId string, provider sdk.AccAddress) []byte + func GetServiceDefinitionKey(chainId, name string) []byte + func NewError(codespace sdk.CodespaceType, code sdk.CodeType, msg string) sdk.Error + func NewHandler(k Keeper) sdk.Handler + func RegisterWire(cdc *wire.Codec) + func SvcBindingEqual(bindingA, bindingB SvcBinding) bool + type BindingType byte + const Global + const Local + func BindingTypeFromString(str string) (BindingType, error) + func (bt *BindingType) UnmarshalJSON(data []byte) error + func (bt BindingType) Format(s fmt.State, verb rune) + func (bt BindingType) MarshalJSON() ([]byte, error) + func (bt BindingType) String() string + type Keeper struct + func NewKeeper(cdc *wire.Codec, key sdk.StoreKey, ck bank.Keeper, codespace sdk.CodespaceType) Keeper + func (k Keeper) AddMethods(ctx sdk.Context, svcDef SvcDef) sdk.Error + func (k Keeper) AddServiceBinding(ctx sdk.Context, svcBinding SvcBinding) (sdk.Error, bool) + func (k Keeper) AddServiceDefinition(ctx sdk.Context, svcDef SvcDef) + func (k Keeper) Codespace() sdk.CodespaceType + func (k Keeper) GetMethods(ctx sdk.Context, chainId, name string) sdk.Iterator + func (k Keeper) GetServiceBinding(ctx sdk.Context, defChainID, defName, bindChainID string, ...) (svcBinding SvcBinding, found bool) + func (k Keeper) GetServiceDefinition(ctx sdk.Context, chainId, name string) (svcDef SvcDef, found bool) + func (k Keeper) RefundDeposit(ctx sdk.Context, defChainID, defName, bindChainID string, ...) (sdk.Error, bool) + func (k Keeper) UpdateServiceBinding(ctx sdk.Context, svcBinding SvcBinding) (sdk.Error, bool) + func (k Keeper) ValidateMethodPrices(ctx sdk.Context, svcBinding SvcBinding) sdk.Error + type Level struct + AvgRspTime int64 + UsableTime int64 + type MessagingType byte + const Multicast + const Unicast + func MessagingTypeFromString(str string) (MessagingType, error) + func (mt *MessagingType) UnmarshalJSON(data []byte) error + func (mt MessagingType) Format(s fmt.State, verb rune) + func (mt MessagingType) MarshalJSON() ([]byte, error) + func (mt MessagingType) String() string + type MethodProperty struct + Description string + ID int + Name string + OutputCached OutputCachedEnum + OutputPrivacy OutputPrivacyEnum + type MsgSvcBind struct + func NewMsgSvcBind(defChainID, defName, bindChainID string, provider sdk.AccAddress, ...) MsgSvcBind + func (msg MsgSvcBind) GetSignBytes() []byte + func (msg MsgSvcBind) GetSigners() []sdk.AccAddress + func (msg MsgSvcBind) Type() string + func (msg MsgSvcBind) ValidateBasic() sdk.Error + type MsgSvcBindingUpdate struct + func NewMsgSvcBindingUpdate(defChainID, defName, bindChainID string, provider sdk.AccAddress, ...) MsgSvcBindingUpdate + func (msg MsgSvcBindingUpdate) GetSignBytes() []byte + func (msg MsgSvcBindingUpdate) GetSigners() []sdk.AccAddress + func (msg MsgSvcBindingUpdate) Type() string + func (msg MsgSvcBindingUpdate) ValidateBasic() sdk.Error + type MsgSvcDef struct + func NewMsgSvcDef(name, chainId, description string, tags []string, author sdk.AccAddress, ...) MsgSvcDef + func (msg MsgSvcDef) GetSignBytes() []byte + func (msg MsgSvcDef) GetSigners() []sdk.AccAddress + func (msg MsgSvcDef) Type() string + func (msg MsgSvcDef) ValidateBasic() sdk.Error + type MsgSvcRefundDeposit struct + BindChainID string + DefChainID string + DefName string + Provider sdk.AccAddress + func NewMsgSvcRefundDeposit(defChainID, defName, bindChainID string, provider sdk.AccAddress) MsgSvcRefundDeposit + func (msg MsgSvcRefundDeposit) GetSignBytes() []byte + func (msg MsgSvcRefundDeposit) GetSigners() []sdk.AccAddress + func (msg MsgSvcRefundDeposit) Type() string + func (msg MsgSvcRefundDeposit) ValidateBasic() sdk.Error + type OutputCachedEnum byte + const NoCached + const OffChainCached + func OutputCachedEnumFromString(str string) (OutputCachedEnum, error) + func (oe *OutputCachedEnum) UnmarshalJSON(data []byte) error + func (oe OutputCachedEnum) Format(s fmt.State, verb rune) + func (oe OutputCachedEnum) MarshalJSON() ([]byte, error) + func (oe OutputCachedEnum) String() string + type OutputPrivacyEnum byte + const NoPrivacy + const PubKeyEncryption + func OutputPrivacyEnumFromString(str string) (OutputPrivacyEnum, error) + func (oe *OutputPrivacyEnum) UnmarshalJSON(data []byte) error + func (oe OutputPrivacyEnum) Format(s fmt.State, verb rune) + func (oe OutputPrivacyEnum) MarshalJSON() ([]byte, error) + func (oe OutputPrivacyEnum) String() string + type Params struct + MaxRequestTimeout int + MaxTagsNum int + MinProviderDeposit sdk.Coins + SlashDeposit sdk.Coins + func DefaultParams() Params + type SvcBinding struct + BindChainID string + BindingType BindingType + DefChainID string + DefName string + Deposit sdk.Coins + Expiration int64 + Level Level + Prices []sdk.Coin + Provider sdk.AccAddress + func NewSvcBinding(defChainID, defName, bindChainID string, provider sdk.AccAddress, ...) SvcBinding + type SvcDef struct + Author sdk.AccAddress + AuthorDescription string + ChainId string + Description string + IDLContent string + Messaging MessagingType + Name string + Tags []string + func NewSvcDef(name, chainId, description string, tags []string, author sdk.AccAddress, ...) SvcDef