Movatterモバイル変換


[0]ホーム

URL:


postgresql-binary-0.8: Encoders and decoders for the PostgreSQL's binary format

Safe HaskellNone
LanguageHaskell2010

PostgreSQL.Binary.Encoder

Contents

Synopsis

Documentation

run ::Encoder a -> a ->ByteStringSource

Value encoder

typeEncoder a = a ->BuilderSource

int2_int16 ::EncoderInt16Source

int2_word16 ::EncoderWord16Source

int4_int32 ::EncoderInt32Source

int4_word32 ::EncoderWord32Source

int8_int64 ::EncoderInt64Source

int8_word64 ::EncoderWord64Source

float4 ::EncoderFloatSource

float8 ::EncoderDoubleSource

composite ::EncoderCompositeSource

bool ::EncoderBoolSource

numeric ::EncoderScientificSource

uuid ::EncoderUUIDSource

json_ast ::EncoderValueSource

json_bytes ::EncoderByteStringSource

jsonb_ast ::EncoderValueSource

jsonb_bytes ::EncoderByteStringSource

char ::EncoderCharSource

A UTF-8-encoded char.

Note that since it's UTF-8-encoded not the "char" but the "text" OID should be used with it.

text_strict ::EncoderTextSource

text_lazy ::EncoderTextSource

bytea_strict ::EncoderByteStringSource

bytea_lazy ::EncoderByteStringSource

date ::EncoderDaySource

time_int ::EncoderTimeOfDaySource

time_float ::EncoderTimeOfDaySource

timetz_int ::Encoder (TimeOfDay,TimeZone)Source

timetz_float ::Encoder (TimeOfDay,TimeZone)Source

timestamp_int ::EncoderLocalTimeSource

timestamp_float ::EncoderLocalTimeSource

timestamptz_int ::EncoderUTCTimeSource

timestamptz_float ::EncoderUTCTimeSource

interval_int ::EncoderDiffTimeSource

interval_float ::EncoderDiffTimeSource

hstore :: (forall a. (a -> (Text,MaybeText) -> a) -> a -> b -> a) ->Encoder bSource

A polymorphic in-placeHSTORE encoder.

Accepts:

  • An implementation of thefoldl function (e.g.,Data.Foldable.foldl'), which determines the input value.

Here's how you can use it to produce a specific encoder:

hashMapHStore :: Encoder (Data.HashMap.Strict.HashMap Text (Maybe Text))hashMapHStore =  hstore foldl'

hstoreRep ::EncoderHStoreSource

array ::Word32 ->ArrayEncoder a ->Encoder aSource

Array encoder

dataArrayEncoder aSource

arrayValue ::Encoder a ->ArrayEncoder aSource

arrayNullableValue ::Encoder a ->ArrayEncoder (Maybe a)Source

arrayDimension :: (forall a. (a -> b -> a) -> a -> c -> a) ->ArrayEncoder b ->ArrayEncoder cSource

arrayRep ::EncoderArraySource

Enum

enum :: (a ->Text) ->Encoder aSource

Given a function, which maps the value into the textual enum label from the DB side, produces an encoder of that value

Produced byHaddock version 2.16.1


[8]ページ先頭

©2009-2025 Movatter.jp