úÎRúNâ5      !"#$%&'()*+,-./01234(c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone!"%&,59:;<=DIQRT[ ,Representation of a function's return value.4Representation of a resultant's column (name, type).TRepresentation of a PostrgeSQL function signature (schema, name, arguments, result).(Representation of a function's argument.DThe exception is thrown when something goes wrong with this package.yThrown when parser fails to process a function declaration. Arguments of the constructor: error message from the parser. Thrown when Argumenth expected to have default value while it doesn't. Actually this should never happen, but we all know... Thrown when ArgumentW is beign printed, but representation was't provided. Again, this should never happen.OTakes PostgreSQL function signature and represent it as an algebraic data type.    (c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone%&,59:;<=DIQRT #;Options that specify how to construct the function binding.%*Function that generates name of a binding.&-Which columns in returned tables can be null.'&How to process type in "setof" clause.(0Whether to add explicit type casts to arguments.)eWhether to use old-style call syntax (:=) instead of (=>). This is necessary for PostgreSQL < 9.5.*6Whether to print executed queries and their arguments.+/How to interpret results of function execution..Remove 5 constructor./Remove list and 5 constructors.#$%&'()*+,-./0 #$%&'()*+,-./ /.#$%&'()*+,-#$%&'()*+,-./0(c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone%&,59:;<=DIQRT1,Fetch function declaration(s) from database.2Generate module with bindings.12Database connection Full path to PostgresBindOptions record Module nameFunction names to match121212(c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone!"%&,59:;<=DIQRT[ 3/Mapping from PostgreSQL types to Haskell types.4RFunction that constructs binding for PostgreSQL stored function by it's signature.6,Example: "varchar" -> PostgresType "varchar"7MExample: ''FromField "varchar" a -> [PostgresType "varchar" ~ a, FromField a]8ÿ[Examples: (PGSingle "varchar") -> (["y"], [PostgresType "varchar" ~ y, FromField y], y) (PGSetOf "varchar") -> (["y"], [PostgresType "varchar" ~ y, FromField y], [y]) (PGTable ["bigint", "varchar"]) -> ( ["y", "z"] , [PostgresType "bigint" ~ y, FromField y, PostgresType "varchar" ~ z, FromField z] , (y, z))9ÿ,Example: [ PGArgument { pgaName = "x", pgaType = "varchar", pgaOptional = True } , PGArgument { pgaName = "y", pgaType = "bigint", pgaOptional = False } ] -> ( ["x1", "x2"] , [PostgresType "varchar" ~ x1, ToField x1, PostgresType "bigint" ~ x2, ToField x2] , [x1, Maybe x2] ):ÿExample: PGFunction { pgfSchema = "public" , pgfName = "foo" , pgfResult = PGSingle "varchar" , pgfArguments = [ PGArgument { pgaName = "x", pgaType = "varchar", pgaOptional = True } , PGArgument { pgaName = "y", pgaType = "bigint", pgaOptional = False } ] } -> { foo :: forall x1 x2 x3. ( PostgresType "varchar" ~ x1, ToField x1 , PostgresType "bigint" ~ x2, ToField x2 , PostgresType "varchar" ~ x2, FromField x3 ) => Connection -> x1 -> Maybe x2 -> x3 };ÿŒExample: PGFunction { pgfSchema = "public" , pgfName = "foo" , pgfResult = PGSingle "varchar" , pgfArguments = [ PGArgument { pgaName = "x", pgaType = "varchar", pgaOptional = True } , PGArgument { pgaName = "y", pgaType = "bigint", pgaOptional = False } ] } -> { Query $ BS.pack $ concat ["select public.foo (", (formatArguments args), ")"] }<xExamples: (PGSingle _) q -> { unwrapRow q } (PGSetOf _) q -> { unwrapColumn q } (PGTable _) q -> { q }=ÿöExample: PGFunction { pgfSchema = "public" , pgfName = "foo" , pgfResult = PGSingle "varchar" , pgfArguments = [ PGArgument { pgaName = "x", pgaType = "varchar", pgaOptional = True } , PGArgument { pgaName = "y", pgaType = "bigint", pgaOptional = False } ] } -> { foo conn x1 x2 = query conn (Query $ BS.pack $ concat ["select public.foo (", (formatArguments args), ")"]) (filterArguments [MandatoryArg "x1" x1, OptionalArg "x2" x2]) }>?@ABCDE34FGHIJK6789:;L<M=NO34> ?@ABCDABCE34FGHIJK6789:;L<M=NO(c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone%&,59:;<=DIQRT33(c) 2016 Al ZohaliBSD3Al Zohali <zohl@fmap.me> experimentalNone$ #$%&'()*+,-34$4#$%&'()*+,-3 P       !"#$%&''()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTU3postgresql-simple-bind-0.4.0-FiaYApxpxNQ5XLsCvt6RR8.Database.PostgreSQL.Simple.Bind.Representation&Database.PostgreSQL.Simple.Bind.Common%Database.PostgreSQL.Simple.Bind.Utils%Database.PostgreSQL.Simple.Bind.TypesDatabase.PostgreSQL.Simple.Bind.Database.PostgreSQL.Simple.Bind.ImplementationPGResultPGSinglePGSetOfPGTablePGColumnpgcNamepgcType PGFunction pgfSchemapgfName pgfArguments pgfResult PGArgumentpgaNamepgaType pgaOptionalPostgresBindException ParserFailedDefaultValueNotFoundRepresentationNotFoundparsePGFunction $fExceptionPostgresBindException$fEqPostgresBindException$fShowPostgresBindException$fShowPGArgument$fEqPGArgument$fShowPGColumn $fEqPGColumn$fShowPGResult $fEqPGResult$fShowPGFunction$fEqPGFunctionPostgresBindOptionspboFunctionName pboIsNullablepboSetOfReturnTypepboExplicitCastspboOlderCallSyntaxpboDebugQueries ReturnTypeAsRowAsField unwrapColumn unwrapRow$fDefaultPostgresBindOptionsgetFunctionDeclarationgenerateBindingsModule PostgresType bindFunction0postgresql-simple-0.5.2.1-B6PRtHUrnVQCIFd0i6Sd4w Database.PostgreSQL.Simple.TypesOnly postgresT mkContextT mkResultTmkArgsT mkFunctionT mkSqlQueryunwrapE mkFunctionEArgument MandatoryArg OptionalArgargNameargTypeargRepresentation margValue morgValue mkFunctionuntypedPlaceholdertypedPlaceholderformatArgumentformatArgumentsfilterArgumentsunwrapE'wrapArg$fShowArgument$fToFieldArgument