hs-abci-sdk-0.1.0.0
Safe HaskellNone
LanguageHaskell2010

Tendermint.SDK.Modules.Bank

Contents

Synopsis

Module

bankModule :: Members (ModuleEffs Bank) r => Bank r Source #

data BankKeeper m a where Source #

Constructors

GetBalance :: Address -> CoinId -> BankKeeper m Coin 
Transfer :: Address -> Coin -> Address -> BankKeeper m () 
Burn :: Address -> Coin -> BankKeeper m () 
Mint :: Address -> Coin -> BankKeeper m () 

Instances

Instances details
type DefiningModule (BankKeeper :: k -> Type -> Type) Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Keeper

type DefiningModule (BankKeeper :: k -> Type -> Type) = "Tendermint.SDK.Modules.Bank.Keeper"

getBalance :: forall r. MemberWithError BankKeeper r => Address -> CoinId -> Sem r Coin Source #

transfer :: forall r. MemberWithError BankKeeper r => Address -> Coin -> Address -> Sem r () Source #

burn :: forall r. MemberWithError BankKeeper r => Address -> Coin -> Sem r () Source #

mint :: forall r. MemberWithError BankKeeper r => Address -> Coin -> Sem r () Source #

eval :: Members [Logger, Output Event, Error AppError] r => Members AuthEffs r => forall a. Sem (BankKeeper ': (Error BankError ': r)) a -> Sem r a Source #

data TransferMsg Source #

Instances

Instances details
Eq TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Show TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Generic TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Associated Types

type Rep TransferMsg :: Type -> Type #

Wrapped TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Associated Types

type Unwrapped TransferMsg

Methods

_Wrapped' :: Iso' TransferMsg (Unwrapped TransferMsg)

HasCodec TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

ValidateMessage TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

HasMessageType TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Rep TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Rep TransferMsg = D1 ('MetaData "TransferMsg" "Tendermint.SDK.Modules.Bank.Messages" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'False) (C1 ('MetaCons "TransferMsg" 'PrefixI 'True) ((S1 ('MetaSel ('Just "transferTo") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Address) :*: S1 ('MetaSel ('Just "transferFrom") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Address)) :*: (S1 ('MetaSel ('Just "transferCoinId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CoinId) :*: S1 ('MetaSel ('Just "transferAmount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Amount))))
type Unwrapped TransferMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Unwrapped TransferMsg = Transfer

data BurnMsg Source #

Constructors

BurnMsg 

Instances

Instances details
Eq BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Methods

(==) :: BurnMsg -> BurnMsg -> Bool #

(/=) :: BurnMsg -> BurnMsg -> Bool #

Show BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Generic BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Associated Types

type Rep BurnMsg :: Type -> Type #

Methods

from :: BurnMsg -> Rep BurnMsg x #

to :: Rep BurnMsg x -> BurnMsg #

Wrapped BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

Associated Types

type Unwrapped BurnMsg

Methods

_Wrapped' :: Iso' BurnMsg (Unwrapped BurnMsg)

HasCodec BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

ValidateMessage BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

HasMessageType BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Rep BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Rep BurnMsg = D1 ('MetaData "BurnMsg" "Tendermint.SDK.Modules.Bank.Messages" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'False) (C1 ('MetaCons "BurnMsg" 'PrefixI 'True) (S1 ('MetaSel ('Just "burnAddress") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Address) :*: (S1 ('MetaSel ('Just "burnCoinId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CoinId) :*: S1 ('MetaSel ('Just "burnAmount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Amount))))
type Unwrapped BurnMsg Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Messages

type Unwrapped BurnMsg = Burn

type GetAddressCoinBalance = "balance" :> (QA Address :> (QueryParam' '[Required, Strict] "coin_id" CoinId :> Leaf Coin)) Source #

Query Api

querier :: forall r. Member BankKeeper r => RouteQ QueryApi r Source #

data TransferEvent Source #

Instances

Instances details
Eq TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

Show TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

Generic TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

Associated Types

type Rep TransferEvent :: Type -> Type #

FromJSON TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

Methods

parseJSON :: Value -> Parser TransferEvent

parseJSONList :: Value -> Parser [TransferEvent]

ToJSON TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

Methods

toJSON :: TransferEvent -> Value

toEncoding :: TransferEvent -> Encoding

toJSONList :: [TransferEvent] -> Value

toEncodingList :: [TransferEvent] -> Encoding

Select TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

ToEvent TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

type Rep TransferEvent Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

type Rep TransferEvent = D1 ('MetaData "TransferEvent" "Tendermint.SDK.Modules.Bank.Types" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'False) (C1 ('MetaCons "TransferEvent" 'PrefixI 'True) ((S1 ('MetaSel ('Just "transferEventCoinId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CoinId) :*: S1 ('MetaSel ('Just "transferEventAmount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Amount)) :*: (S1 ('MetaSel ('Just "transferEventTo") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Address) :*: S1 ('MetaSel ('Just "transferEventFrom") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Address))))

data BankError Source #

Constructors

InsufficientFunds Text 

Instances

Instances details
IsAppError BankError Source # 
Instance details

Defined in Tendermint.SDK.Modules.Bank.Types

type BankName = "bank" Source #

newtype Amount Source #

Constructors

Amount 

Fields

Instances

Instances details
Eq Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

(==) :: Amount -> Amount -> Bool #

(/=) :: Amount -> Amount -> Bool #

Num Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Ord Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Show Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Generic Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Rep Amount :: Type -> Type #

Methods

from :: Amount -> Rep Amount x #

to :: Rep Amount x -> Amount #

FromJSON Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

parseJSON :: Value -> Parser Amount

parseJSONList :: Value -> Parser [Amount]

ToJSON Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

toJSON :: Amount -> Value

toEncoding :: Amount -> Encoding

toJSONList :: [Amount] -> Value

toEncodingList :: [Amount] -> Encoding

Wrapped Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Unwrapped Amount

Methods

_Wrapped' :: Iso' Amount (Unwrapped Amount)

HasCodec Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep Amount = D1 ('MetaData "Amount" "Tendermint.SDK.Modules.Auth.Types" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'True) (C1 ('MetaCons "Amount" 'PrefixI 'True) (S1 ('MetaSel ('Just "unAmount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Word64)))
type Unwrapped Amount Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Unwrapped Amount = Amount

data Coin Source #

Constructors

Coin 

Instances

Instances details
Eq Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

(==) :: Coin -> Coin -> Bool #

(/=) :: Coin -> Coin -> Bool #

Show Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

showsPrec :: Int -> Coin -> ShowS #

show :: Coin -> String #

showList :: [Coin] -> ShowS #

Generic Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Rep Coin :: Type -> Type #

Methods

from :: Coin -> Rep Coin x #

to :: Rep Coin x -> Coin #

Wrapped Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Unwrapped Coin

Methods

_Wrapped' :: Iso' Coin (Unwrapped Coin)

HasCodec Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep Coin = D1 ('MetaData "Coin" "Tendermint.SDK.Modules.Auth.Types" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'False) (C1 ('MetaCons "Coin" 'PrefixI 'True) (S1 ('MetaSel ('Just "coinId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CoinId) :*: S1 ('MetaSel ('Just "coinAmount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Amount)))
type Unwrapped Coin Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Unwrapped Coin = Coin

newtype CoinId Source #

Constructors

CoinId 

Fields

Instances

Instances details
Eq CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

(==) :: CoinId -> CoinId -> Bool #

(/=) :: CoinId -> CoinId -> Bool #

Show CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

IsString CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

fromString :: String -> CoinId #

Generic CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Rep CoinId :: Type -> Type #

Methods

from :: CoinId -> Rep CoinId x #

to :: Rep CoinId x -> CoinId #

FromJSON CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

parseJSON :: Value -> Parser CoinId

parseJSONList :: Value -> Parser [CoinId]

ToJSON CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Methods

toJSON :: CoinId -> Value

toEncoding :: CoinId -> Encoding

toJSONList :: [CoinId] -> Value

toEncodingList :: [CoinId] -> Encoding

Wrapped CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

Associated Types

type Unwrapped CoinId

Methods

_Wrapped' :: Iso' CoinId (Unwrapped CoinId)

HasCodec CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

FromHttpApiData CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

ToHttpApiData CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Rep CoinId = D1 ('MetaData "CoinId" "Tendermint.SDK.Modules.Auth.Types" "hs-abci-sdk-0.1.0.0-6BthCXrKFfHAhK2oYxZQI4" 'True) (C1 ('MetaCons "CoinId" 'PrefixI 'True) (S1 ('MetaSel ('Just "unCoinId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)))
type Unwrapped CoinId Source # 
Instance details

Defined in Tendermint.SDK.Modules.Auth.Types

type Unwrapped CoinId = CoinId