Safe Haskell | None |
---|---|
Language | Haskell2010 |
Morley.Micheline.Class
Description
Module that provides type classes for converting to and from low-level Micheline representation.
Synopsis
- class ToExpression a where
- toExpression :: a -> Expression
- data FromExpressionError = FromExpressionError Expression Text
- class FromExpression a where
Documentation
class ToExpression a where Source #
Type class that provides an ability to convert something to Micheline Expression.
Methods
toExpression :: a -> Expression Source #
Instances
data FromExpressionError Source #
Errors that can happen when we convert an Expression
to our
data type.
Constructors
FromExpressionError Expression Text |
Instances
Eq FromExpressionError Source # | |
Defined in Morley.Micheline.Class Methods (==) :: FromExpressionError -> FromExpressionError -> Bool # (/=) :: FromExpressionError -> FromExpressionError -> Bool # | |
Show FromExpressionError Source # | |
Defined in Morley.Micheline.Class Methods showsPrec :: Int -> FromExpressionError -> ShowS # show :: FromExpressionError -> String # showList :: [FromExpressionError] -> ShowS # | |
Exception FromExpressionError Source # | |
Defined in Morley.Micheline.Class Methods toException :: FromExpressionError -> SomeException # fromException :: SomeException -> Maybe FromExpressionError # | |
Buildable FromExpressionError Source # | |
Defined in Morley.Micheline.Class Methods build :: FromExpressionError -> Builder # |
class FromExpression a where Source #
Type class that provides the ability to convert something from a Micheline Expression.
Methods
fromExpression :: Expression -> Either FromExpressionError a Source #