Copyright | (c) 2016 Al Zohali |
---|---|
License | BSD3 |
Maintainer | Al Zohali <zohl@fmap.me> |
Stability | experimental |
Safe Haskell | None |
Language | Haskell2010 |
An algebraic data type that (partially) represents function declaration based on PostgreSQL documentation.
- data PGFunction = PGFunction {
- pgfSchema :: String
- pgfName :: String
- pgfArguments :: [PGArgument]
- pgfResult :: PGResult
- data PGArgument = PGArgument {}
- data PGColumn = PGColumn {}
- data PGResult
- data PostgresBindException
- parsePGFunction :: MonadThrow m => Text -> m PGFunction
Documentation
data PGFunction Source #
Representation of a PostrgeSQL function signature (schema, name, arguments, result).
PGFunction | |
|
Representation of a resultant's column (name, type).
Representation of a function's return value.
data PostgresBindException Source #
The exception is thrown when something goes wrong with this package.
ParserFailed String | Thrown when parser fails to process a function declaration. Arguments of the constructor: error message from the parser. |
DefaultValueNotFound String | Thrown when |
RepresentationNotFound String | Thrown when |
parsePGFunction :: MonadThrow m => Text -> m PGFunction Source #
Takes PostgreSQL function signature and represent it as an algebraic data type.