Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Functionality related to Address
data type and related types.
Synopsis
- data Address = Address {}
- newtype Address' = Address' {}
- addressF ∷ Format r (Address → r)
- addressDetailedF ∷ Format r (Address → r)
- decCBORTextAddress ∷ Text → Either DecoderError Address
- checkAddrSpendingData ∷ AddrSpendingData → Address → Bool
- checkVerKeyAddress ∷ VerificationKey → Address → Bool
- checkRedeemAddress ∷ RedeemVerificationKey → Address → Bool
- addrToBase58 ∷ Address → ByteString
- encCBORAddr ∷ Address → Encoding
- encCBORAddrCRC32 ∷ Address → Encoding
- decodeAddressBase58 ∷ Text → Either DecoderError Address
- encodeAddressBase58 ∷ Address → Text
- addrAttributesUnwrapped ∷ Address → AddrAttributes
- addrNetworkMagic ∷ Address → NetworkMagic
- isRedeemAddress ∷ Address → Bool
- makeAddress ∷ AddrSpendingData → AddrAttributes → Address
- makeVerKeyAddress ∷ NetworkMagic → VerificationKey → Address
- makeVerKeyHdwAddress ∷ NetworkMagic → HDAddressPayload → VerificationKey → Address
- makeRedeemAddress ∷ NetworkMagic → RedeemVerificationKey → Address
Documentation
Address
is where you can send Lovelace
Address | |
|
Instances
Hash of this data is stored in Address
. This type exists mostly
for internal usage.
Instances
Generic Address' Source # | |
Show Address' Source # | |
FromCBOR Address' Source # | |
ToCBOR Address' Source # | |
DecCBOR Address' Source # | |
EncCBOR Address' Source # | |
Eq Address' Source # | |
type Rep Address' Source # | |
Defined in Cardano.Chain.Common.Address type Rep Address' = D1 ('MetaData "Address'" "Cardano.Chain.Common.Address" "cardano-ledger-byron-1.0.1.0-inplace" 'True) (C1 ('MetaCons "Address'" 'PrefixI 'True) (S1 ('MetaSel ('Just "unAddress'") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (AddrType, AddrSpendingData, Attributes AddrAttributes)))) |
Formatting
decCBORTextAddress ∷ Text → Either DecoderError Address Source #
Deprecated: Use decodeAddressBase58 instead
A function which decodes base58-encoded Address
Spending data checks
checkAddrSpendingData ∷ AddrSpendingData → Address → Bool Source #
Check whether given AddrSpendingData
corresponds to given Address
checkVerKeyAddress ∷ VerificationKey → Address → Bool Source #
Check if given Address
is created from given VerificationKey
checkRedeemAddress ∷ RedeemVerificationKey → Address → Bool Source #
Check if given Address
is created from given RedeemVerificationKey
Encoding/Decoding
decodeAddressBase58 ∷ Text → Either DecoderError Address Source #
Decode an address from Base58 encoded Text.
encodeAddressBase58 ∷ Address → Text Source #
Encode an address to Text. `decodeAddressBase58 (encodeAddressBase58 x) === Right x`
Utilities
addrAttributesUnwrapped ∷ Address → AddrAttributes Source #
Get AddrAttributes
from Address
addrNetworkMagic ∷ Address → NetworkMagic Source #
Get NetworkMagic
from Address
Pattern-matching helpers
Construction
makeAddress ∷ AddrSpendingData → AddrAttributes → Address Source #
Make an Address
from spending data and attributes.
makeVerKeyAddress ∷ NetworkMagic → VerificationKey → Address Source #
A function for making an address from VerificationKey
∷ NetworkMagic | |
→ HDAddressPayload | Derivation path |
→ VerificationKey | |
→ Address |
A function for making an HDW address
makeRedeemAddress ∷ NetworkMagic → RedeemVerificationKey → Address Source #
A function for making an address from RedeemVerificationKey