cardano-api:internal
Safe HaskellNone
LanguageHaskell2010

Cardano.Api.SerialiseBech32

Description

Bech32 Serialisation

Synopsis

Documentation

class (HasTypeProxy a, SerialiseAsRawBytes a) => SerialiseAsBech32 a where Source #

Methods

bech32PrefixFor :: a -> Text Source #

The human readable prefix to use when encoding this value to Bech32.

bech32PrefixesPermitted :: AsType a -> [Text] Source #

The set of human readable prefixes that can be used for this type.

Instances

Instances details
SerialiseAsBech32 StakeAddress Source # 
Instance details

Defined in Cardano.Api.Address

SerialiseAsBech32 (Address ShelleyAddr) Source # 
Instance details

Defined in Cardano.Api.Address

SerialiseAsBech32 (Hash CommitteeColdKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (Hash CommitteeHotKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (Hash DRepKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (Hash StakePoolKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey KesKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Praos

SerialiseAsBech32 (SigningKey VrfKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Praos

SerialiseAsBech32 (SigningKey CommitteeColdExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey CommitteeColdKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey CommitteeHotExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey CommitteeHotKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey DRepExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey DRepKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey PaymentExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey PaymentKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey StakeExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey StakeKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (SigningKey StakePoolKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey KesKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Praos

SerialiseAsBech32 (VerificationKey VrfKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Praos

SerialiseAsBech32 (VerificationKey CommitteeColdExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey CommitteeColdKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey CommitteeHotExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey CommitteeHotKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey DRepExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey DRepKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey PaymentExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey PaymentKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey StakeExtendedKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey StakeKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

SerialiseAsBech32 (VerificationKey StakePoolKey) Source # 
Instance details

Defined in Cardano.Api.Keys.Shelley

data Bech32DecodeError Source #

Bech32 decoding error.

Constructors

Bech32DecodingError !DecodingError

There was an error decoding the string as Bech32.

Bech32UnexpectedPrefix !Text !(Set Text)

The human-readable prefix in the Bech32-encoded string is not one of the ones expected.

Bech32DataPartToBytesError !Text

There was an error in extracting a ByteString from the data part of the Bech32-encoded string.

Bech32DeserialiseFromBytesError !ByteString

There was an error in deserialising the bytes into a value of the expected type.

Bech32WrongPrefix !Text !Text

The human-readable prefix in the Bech32-encoded string does not correspond to the prefix that should be used for the payload value.

Instances

Instances details
Data Bech32DecodeError Source # 
Instance details

Defined in Cardano.Api.SerialiseBech32

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Bech32DecodeError -> c Bech32DecodeError Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Bech32DecodeError Source #

toConstr :: Bech32DecodeError -> Constr Source #

dataTypeOf :: Bech32DecodeError -> DataType Source #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Bech32DecodeError) Source #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Bech32DecodeError) Source #

gmapT :: (forall b. Data b => b -> b) -> Bech32DecodeError -> Bech32DecodeError Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Bech32DecodeError -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Bech32DecodeError -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Bech32DecodeError -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Bech32DecodeError -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Bech32DecodeError -> m Bech32DecodeError Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Bech32DecodeError -> m Bech32DecodeError Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Bech32DecodeError -> m Bech32DecodeError Source #

Show Bech32DecodeError Source # 
Instance details

Defined in Cardano.Api.SerialiseBech32

Error Bech32DecodeError Source # 
Instance details

Defined in Cardano.Api.SerialiseBech32

Eq Bech32DecodeError Source # 
Instance details

Defined in Cardano.Api.SerialiseBech32