packages feed

rethinkdb 1.16.0.0 → 2.0.0.0

raw patch · 12 files changed

+148/−79 lines, 12 filesdep ~aesondep ~basedep ~timenew-uploaderPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: aeson, base, time, utf8-string

API changes (from Hackage documentation)

- Database.RethinkDB: type Line = Vector LonLat
- Database.RethinkDB: type Polygon = Vector (Vector LonLat)
- Database.RethinkDB.Datum: type Line = Vector LonLat
- Database.RethinkDB.Datum: type Polygon = Vector (Vector LonLat)
- Database.RethinkDB.Wire.Response: SUCCESS_ATOM_FEED :: ResponseType
- Database.RethinkDB.Wire.Response: SUCCESS_FEED :: ResponseType
- Database.RethinkDB.Wire.Term: ALL :: TermType
- Database.RethinkDB.Wire.Term: ANY :: TermType
- Database.RethinkDB.Wire.Term: INDEXES_OF :: TermType
+ Database.RethinkDB: GeoLine :: Vector LonLat -> GeoLine
+ Database.RethinkDB: GeoPolygon :: Vector (Vector LonLat) -> GeoPolygon
+ Database.RethinkDB: MaxVal :: Bound a
+ Database.RethinkDB: MinVal :: Bound a
+ Database.RethinkDB: geoLinePoints :: GeoLine -> Vector LonLat
+ Database.RethinkDB: geoPolygonLines :: GeoPolygon -> Vector (Vector LonLat)
+ Database.RethinkDB: maxval :: Bound a
+ Database.RethinkDB: minval :: Bound a
+ Database.RethinkDB: newtype GeoLine
+ Database.RethinkDB: newtype GeoPolygon
+ Database.RethinkDB.Datum: GeoLine :: Vector LonLat -> GeoLine
+ Database.RethinkDB.Datum: GeoPolygon :: Vector (Vector LonLat) -> GeoPolygon
+ Database.RethinkDB.Datum: geoLinePoints :: GeoLine -> Vector LonLat
+ Database.RethinkDB.Datum: geoPolygonLines :: GeoPolygon -> Vector (Vector LonLat)
+ Database.RethinkDB.Datum: instance [overlap ok] Eq GeoLine
+ Database.RethinkDB.Datum: instance [overlap ok] Eq GeoPolygon
+ Database.RethinkDB.Datum: instance [overlap ok] FromDatum GeoLine
+ Database.RethinkDB.Datum: instance [overlap ok] FromDatum GeoPolygon
+ Database.RethinkDB.Datum: instance [overlap ok] Ord GeoLine
+ Database.RethinkDB.Datum: instance [overlap ok] Ord GeoPolygon
+ Database.RethinkDB.Datum: newtype GeoLine
+ Database.RethinkDB.Datum: newtype GeoPolygon
+ Database.RethinkDB.Functions: includeStates :: Attribute a
+ Database.RethinkDB.ReQL: MaxVal :: Bound a
+ Database.RethinkDB.ReQL: MinVal :: Bound a
+ Database.RethinkDB.ReQL: instance Expr a => Expr (Bound a)
+ Database.RethinkDB.ReQL: maxval :: Bound a
+ Database.RethinkDB.ReQL: minval :: Bound a
+ Database.RethinkDB.Wire.Response: ATOM_FEED :: ResponseNote
+ Database.RethinkDB.Wire.Response: INCLUDES_STATES :: ResponseNote
+ Database.RethinkDB.Wire.Response: ORDER_BY_LIMIT_FEED :: ResponseNote
+ Database.RethinkDB.Wire.Response: SEQUENCE_FEED :: ResponseNote
+ Database.RethinkDB.Wire.Response: UNIONED_FEED :: ResponseNote
+ Database.RethinkDB.Wire.Response: data ResponseNote
+ Database.RethinkDB.Wire.Response: instance Eq ResponseNote
+ Database.RethinkDB.Wire.Response: instance Show ResponseNote
+ Database.RethinkDB.Wire.Response: instance WireValue ResponseNote
+ Database.RethinkDB.Wire.Term: AND :: TermType
+ Database.RethinkDB.Wire.Term: BETWEEN_DEPRECATED :: TermType
+ Database.RethinkDB.Wire.Term: MAXVAL :: TermType
+ Database.RethinkDB.Wire.Term: MINVAL :: TermType
+ Database.RethinkDB.Wire.Term: OFFSETS_OF :: TermType
+ Database.RethinkDB.Wire.Term: OR :: TermType
+ Database.RethinkDB.Wire.VersionDummy: V0_4 :: Version
- Database.RethinkDB: Line :: Line -> Datum
+ Database.RethinkDB: Line :: GeoLine -> Datum
- Database.RethinkDB: Polygon :: Polygon -> Datum
+ Database.RethinkDB: Polygon :: GeoPolygon -> Datum
- Database.RethinkDB: dbCreate :: String -> ReQL
+ Database.RethinkDB: dbCreate :: Text -> ReQL
- Database.RethinkDB: forEach :: (Expr s, Expr a) => s -> (ReQL -> a) -> ReQL
+ Database.RethinkDB: forEach :: (Expr a, Expr s) => (ReQL -> a) -> s -> ReQL
- Database.RethinkDB: indexCreate :: Expr fun => String -> fun -> Table -> ReQL
+ Database.RethinkDB: indexCreate :: Expr fun => Text -> fun -> Table -> ReQL
- Database.RethinkDB.Datum: Line :: Line -> Datum
+ Database.RethinkDB.Datum: Line :: GeoLine -> Datum
- Database.RethinkDB.Datum: Polygon :: Polygon -> Datum
+ Database.RethinkDB.Datum: Polygon :: GeoPolygon -> Datum
- Database.RethinkDB.Functions: dbCreate :: String -> ReQL
+ Database.RethinkDB.Functions: dbCreate :: Text -> ReQL
- Database.RethinkDB.Functions: forEach :: (Expr s, Expr a) => s -> (ReQL -> a) -> ReQL
+ Database.RethinkDB.Functions: forEach :: (Expr a, Expr s) => (ReQL -> a) -> s -> ReQL
- Database.RethinkDB.Functions: indexCreate :: Expr fun => String -> fun -> Table -> ReQL
+ Database.RethinkDB.Functions: indexCreate :: Expr fun => Text -> fun -> Table -> ReQL

Files

Database/RethinkDB.hs view
@@ -1,4 +1,4 @@--- | Haskell client driver for RethinkDB+-- | Haskell client driver for RethinkDB  -- -- Based upon the official Javascript, Python and Ruby API: <http://www.rethinkdb.com/api/> --@@ -9,7 +9,7 @@ -- > import qualified Database.RethinkDB.NoClash  module Database.RethinkDB (-+     -- * Accessing RethinkDB    connect,@@ -26,12 +26,12 @@   ErrorCode(..),   Response,   Result(..),-+     -- * Cursors-+     next, collect, collect', each,   Cursor,-+     -- * Manipulating databases    Database(..),@@ -60,7 +60,7 @@    db, table,   get, getAll,-  filter, between,+  filter, between, minval, maxval,   Bound(..),    -- * Joins@@ -97,15 +97,15 @@   setInsert, setUnion, setIntersection, setDifference,   (!), (!?),   hasFields,-  insertAt, spliceAt, deleteAt, changeAt, keys,+  insertAt, spliceAt, deleteAt, changeAt, keys,     literal, remove,   Attribute(..),    -- * String manipulation-+     match, upcase, downcase,   split, splitOn, splitMax,-+     -- * Math and logic    (+), (-), (*), (/), mod,@@ -113,14 +113,14 @@   (==), (/=), (>), (>=), (<), (<=),   not,   random, randomTo, randomFromTo,-+     -- * Dates and times-+     now, time, epochTime, iso8601, inTimezone, during,   timezone, date, timeOfDay, year, month, day, dayOfWeek,   dayOfYear, hours, minutes, seconds,   toIso8601, toEpochTime,-+     -- * Control structures    args, apply, js, branch, forEach,@@ -132,28 +132,27 @@   http,   HttpOptions(..), HttpResultFormat(..),   HttpMethod(..), PaginationStrategy(..),-+     -- * Geospatial commands-+     circle, distance, fill, geoJSON,   toGeoJSON, getIntersecting,   getNearest, includes, intersects,   line, point, polygon, polygonSub,-  LonLat(..), Line, Polygon,+  LonLat(..), GeoLine(..), GeoPolygon(..),   maxResults, maxDist, unit, numVertices,   Unit(..),-+     -- * Administration-+     config, rebalance, reconfigure,   status, wait,--+     -- * Helpers    ex, str, num, (#), note, empty,   def-+     ) where  import Prelude ()
Database/RethinkDB/Datum.hs view
@@ -1,10 +1,15 @@-{-# LANGUAGE OverloadedStrings, PatternGuards, DefaultSignatures,-    FlexibleInstances, OverlappingInstances #-}+{-# LANGUAGE CPP, OverloadedStrings, PatternGuards, DefaultSignatures, FlexibleInstances #-}+#if __GLASGOW_HASKELL__ < 710+{-# LANGUAGE OverlappingInstances #-}+#define PRAGMA_OVERLAPPING+#else+#define PRAGMA_OVERLAPPING {-# OVERLAPPING #-}+#endif  module Database.RethinkDB.Datum (   parse, Parser, Result(..),   Datum(..), ToDatum(..), FromDatum(..), fromDatum,-  LonLat(..), Array, Object, Line, Polygon,+  LonLat(..), Array, Object, GeoLine(..), GeoPolygon(..),   (.=), (.:), (.:?),   encode, decode, eitherDecode,   resultToMaybe, resultToEither,@@ -48,8 +53,8 @@   Object Object |   Time ZonedTime |   Point LonLat |-  Line Line |-  Polygon Polygon |+  Line GeoLine |+  Polygon GeoPolygon |   Binary SB.ByteString  class FromDatum a where@@ -141,19 +146,24 @@   parseDatum (Time t) = return $ zonedTimeToUTC t   parseDatum d = errorExpected "Time" d --- TODO: This instance breaks (fmap toDatum . fromDatum) == return instance FromDatum a => FromDatum (Vector a) where   parseDatum (Array v) = fmap V.fromList . mapM parseDatum $ V.toList v-  parseDatum (Line l) = fmap V.fromList . mapM (parseDatum . toDatum) $ V.toList l-  parseDatum (Polygon p) = fmap V.fromList . mapM (parseDatum . toDatum) $ V.toList p-  parseDatum d = errorExpected "Array, Line or Polygon" d+  parseDatum d = errorExpected "Array" d +instance FromDatum GeoLine where+  parseDatum (Line l) = return l+  parseDatum d = errorExpected "Line" d++instance FromDatum GeoPolygon where+  parseDatum (Polygon p) = return p+  parseDatum d = errorExpected "Polygon" d+ instance FromDatum LonLat where   parseDatum (Point l) = return l   parseDatum d = errorExpected "Point" d  instance FromDatum Float-instance FromDatum String+instance PRAGMA_OVERLAPPING FromDatum String instance FromDatum Int instance FromDatum Int8 instance FromDatum Int16@@ -175,8 +185,10 @@  type Array = Vector Datum type Object = HM.HashMap ST.Text Datum-type Line = Vector LonLat-type Polygon = Vector (Vector LonLat)+newtype GeoLine = GeoLine { geoLinePoints :: Vector LonLat } +            deriving (Eq, Ord)+newtype GeoPolygon = GeoPolygon { geoPolygonLines :: Vector (Vector LonLat) }+            deriving (Eq, Ord)  data LonLat = LonLat { longitude, latitude :: Double }             deriving (Eq, Ord)@@ -208,8 +220,8 @@   show (Object o) = "{" ++ intercalate "," (map (\(k,v) -> show k ++ ":" ++ show v) $ HM.toList o) ++ "}"   show (Time t) = "Time<" ++ show t ++ ">"   show (Point p) = "Point<" ++ showLonLat p ++ ">"-  show (Line l) = "Line<[" ++ intercalate "],[" (map showLonLat $ V.toList l) ++ "]>"-  show (Polygon p) = "Polygon<[" ++ intercalate "],[" (map (\x -> "[" ++ intercalate "],[" (map showLonLat $ V.toList x) ++ "]") (V.toList p)) ++ "]>"+  show (Line l) = "Line<[" ++ intercalate "],[" (map showLonLat $ V.toList $ geoLinePoints l) ++ "]>"+  show (Polygon p) = "Polygon<[" ++ intercalate "],[" (map (\x -> "[" ++ intercalate "],[" (map showLonLat $ V.toList x) ++ "]") (V.toList $ geoPolygonLines p)) ++ "]>"   show (Binary b) = "Binary<" ++ show b ++ ">"  showLonLat :: LonLat -> String@@ -305,7 +317,7 @@ instance ToDatum Word32 instance ToDatum Word64 instance ToDatum Char-instance ToDatum [Char]+instance PRAGMA_OVERLAPPING ToDatum [Char] instance ToDatum Integer instance ToDatum ST.Text instance ToDatum LT.Text@@ -324,8 +336,8 @@         Just c <- HM.lookup "coordinates" o ->           case t of             "Point" | Success [lon, lat] <- fromJSON c -> Point (LonLat lon lat)-            "LineString" | Success l <- V.mapM toLonLat =<< fromJSON c -> Line l-            "Polygon" | Success p <- V.mapM (V.mapM toLonLat) =<< fromJSON c -> Polygon p+            "LineString" | Success l <- V.mapM toLonLat =<< fromJSON c -> Line (GeoLine l)+            "Polygon" | Success p <- V.mapM (V.mapM toLonLat) =<< fromJSON c -> Polygon (GeoPolygon p)             _ -> asObject       Just "TIME" |         Just (J.Number ts) <- HM.lookup "epoch_time" o,@@ -366,11 +378,11 @@   toJSON (Line l) = J.object [     "$reql_type$" J..= ("GEOMETRY" :: ST.Text),     "type" J..= ("LineString" :: ST.Text),-    "coordinates" J..= V.map pointToPair l]+    "coordinates" J..= V.map pointToPair (geoLinePoints l)]   toJSON (Polygon p) = J.object [     "$reql_type$" J..= ("GEOMETRY" :: ST.Text),     "type" J..= ("Polygon" :: ST.Text),-    "coordinates" J..= V.map (V.map pointToPair) p]+    "coordinates" J..= V.map (V.map pointToPair) (geoPolygonLines p)]   toJSON (Binary b) = J.object [     "$reql_type$" J..= ("BINARY" :: ST.Text),     "data" J..= Char8.unpack (Base64.encode b)]
Database/RethinkDB/Driver.hs view
@@ -1,4 +1,4 @@-{-# LANGUAGE OverloadedStrings, FlexibleInstances, DefaultSignatures, GADTs #-}+{-# LANGUAGE OverloadedStrings, FlexibleInstances, DefaultSignatures, GADTs, CPP #-}  module Database.RethinkDB.Driver (   run,@@ -14,7 +14,9 @@ import Control.Monad import Control.Concurrent.MVar (MVar, takeMVar) import Data.Text (Text)+#if __GLASGOW_HASKELL__ < 710 import Control.Applicative ((<$>), (<*>))+#endif import Data.List import Data.Maybe import Control.Exception (throwIO)
Database/RethinkDB/Functions.hs view
@@ -111,10 +111,10 @@ -- | Like map but for write queries -- -- >>> _ <- run' h $ table "users" # replace (without ["post_count"])--- >>> run h $ forEach (table "users") (\user -> table "users" # get (user!"name") # ex update [nonAtomic] (const ["post_count" := R.count (table "posts" # R.filter (\post -> post!"author" R.== user!"name"))])) :: IO WriteResponse+-- >>> run h $ forEach (\user -> table "users" # get (user!"name") # ex update [nonAtomic] (const ["post_count" := R.count (table "posts" # R.filter (\post -> post!"author" R.== user!"name"))])) (table "users") :: IO WriteResponse -- {replaced:2}-forEach :: (Expr s, Expr a) => s -> (ReQL -> a) -> ReQL-forEach s f = op FOR_EACH (s, expr P.. f)+forEach :: (Expr a, Expr s) => (ReQL -> a) -> s -> ReQL+forEach f s = op FOR_EACH (s, expr P.. f)  -- | A table --@@ -189,14 +189,14 @@ -- >>> run h $ True R.|| False -- true (||) :: (Expr a, Expr b) => a -> b -> ReQL-a || b = op ANY (a, b)+a || b = op OR (a, b)  -- | Boolean and -- -- >>> run h $ True R.&& False -- false (&&) :: (Expr a, Expr b) => a -> b -> ReQL-a && b = op ALL (a, b)+a && b = op AND (a, b)  infix 4 ==, /= @@ -549,8 +549,8 @@ -- -- >>> run' h $ dbCreate "dev" -- {"config_changes":[{"new_val":{"name":"dev","id":...},"old_val":null}],"dbs_created":1}-dbCreate :: P.String -> ReQL-dbCreate db_name = op DB_CREATE [str db_name]+dbCreate :: Text -> ReQL+dbCreate db_name = op DB_CREATE [expr db_name]  -- | Drop a database --@@ -573,8 +573,8 @@ -- {"created":1} -- >>> run' h $ table "users" # ex indexCreate ["geo":=True] "location" (!"location") -- {"created":1}-indexCreate :: (Expr fun) => P.String -> fun -> Table -> ReQL-indexCreate name f tbl = op INDEX_CREATE (tbl, str name, f)+indexCreate :: (Expr fun) => Text -> fun -> Table -> ReQL+indexCreate name f tbl = op INDEX_CREATE (tbl, expr name, f)  -- | Get the status of the given indexes --@@ -681,7 +681,7 @@ -- >>> run h $ indexesOf (match "ba.") [str "foo", "bar", "baz"] -- [1,2] indexesOf :: (Expr fun, Expr seq) => fun -> seq -> ReQL-indexesOf f s = op INDEXES_OF (s, f)+indexesOf f s = op OFFSETS_OF (s, f)  -- | Test if a sequence is empty --@@ -992,6 +992,10 @@ -- {inserted:1,changes:[{"old_val":null,"new_val":{"name":"sabrina"}}]} returnChanges :: Attribute a returnChanges = "return_changes" := P.True++-- | Optional argument for changes+includeStates :: Attribute a+includeStates = "include_states" := P.True  data Durability = Hard | Soft 
Database/RethinkDB/MapReduce.hs view
Database/RethinkDB/Network.hs view
@@ -168,7 +168,7 @@       else go (c : acc)  magicNumber :: Word32-magicNumber = fromIntegral $ toWire V0_3+magicNumber = fromIntegral $ toWire V0_4  withSocket :: RethinkDBHandle -> (Socket -> IO a) -> IO a withSocket RethinkDBHandle{ rdbSocket, rdbWriteLock } f =@@ -263,8 +263,6 @@   in case type_ of   Just SUCCESS_ATOM -> ResponseSingle <!< atom   Just SUCCESS_PARTIAL -> ResponseBatch (Just $ More False h t) <!< results-  Just SUCCESS_FEED -> ResponseBatch (Just $ More True h t) <!< results-  Just SUCCESS_ATOM_FEED -> ResponseBatch (Just $ More True h t) <!< results   Just SUCCESS_SEQUENCE -> ResponseBatch Nothing <!< results   Just CLIENT_ERROR -> ResponseError $ RethinkDBError ErrorBrokenClient q e bt   Just COMPILE_ERROR -> ResponseError $ RethinkDBError ErrorBadQuery q e bt
Database/RethinkDB/NoClash.hs view
Database/RethinkDB/ReQL.hs view
@@ -1,7 +1,7 @@ {-# LANGUAGE ExistentialQuantification, RecordWildCards,              ScopedTypeVariables, FlexibleInstances,              OverloadedStrings, PatternGuards, GADTs, -             EmptyDataDecls, DefaultSignatures #-}+             EmptyDataDecls, DefaultSignatures, CPP #-}  -- | Building RQL queries in Haskell module Database.RethinkDB.ReQL (@@ -31,7 +31,9 @@   WireBacktrace(..),   note,   (?:=),-  Arr(arr)+  Arr(arr),+  minval,+  maxval   ) where  import qualified Data.Aeson as J@@ -45,7 +47,9 @@ import Data.String (IsString(..)) import Data.List (intercalate) import Control.Monad.State (State, get, put, runState)+#if __GLASGOW_HASKELL__ < 710 import Control.Applicative ((<$>), (<*>))+#endif import Data.Default (Default, def) import qualified Data.Text as T import qualified Data.ByteString as SB@@ -54,7 +58,9 @@ import Data.Time import Control.Monad.Fix import Data.Int+#if __GLASGOW_HASKELL__ < 710 import Data.Monoid+#endif import Data.Char import Data.Ratio import Data.Word@@ -521,16 +527,35 @@   Open { getBound :: a } -- ^ An inclusive bound   | Closed { getBound :: a } -- ^ An exclusive bound   | DefaultBound { getBound :: a }+  | MinVal+  | MaxVal +instance Expr a => Expr (Bound a) where+  expr (Open a) = expr a+  expr (Closed a) = expr a+  expr (DefaultBound a) = expr a+  expr MinVal = op MINVAL ()+  expr MaxVal = op MAXVAL ()++minval :: Bound a+minval = MinVal++maxval :: Bound a+maxval = MaxVal+ instance Functor Bound where   fmap f (Open a) = Open (f a)   fmap f (Closed a) = Closed (f a)   fmap f (DefaultBound a) = DefaultBound (f a)+  fmap _ MinVal = MinVal+  fmap _ MaxVal = MaxVal  closedOrOpen :: Bound a -> Maybe T.Text closedOrOpen Open{} = Just "open" closedOrOpen Closed{} = Just "closed" closedOrOpen DefaultBound{} = Nothing+closedOrOpen MinVal = Nothing+closedOrOpen MaxVal = Nothing  boundOp :: (a -> a -> a) -> Bound a -> Bound a -> Bound a boundOp f (Closed a) (Closed b) = Closed $ f a b@@ -539,14 +564,23 @@ boundOp f (Open a) (Open b) = Open $ f a b boundOp f (DefaultBound a) b = fmap (f a) b boundOp f a (DefaultBound b) = fmap (flip f b) a+boundOp _ MaxVal a = a+boundOp _ MinVal a = a+boundOp _ a MaxVal = a+boundOp _ a MinVal = a  instance Num a => Num (Bound a) where   (+) = boundOp (+)   (-) = boundOp (-)   (*) = boundOp (*)-  negate = fmap negate-  abs = fmap abs-  signum = fmap signum+  negate MinVal = MaxVal+  negate MaxVal = MaxVal +  negate a = fmap negate a+  abs MinVal = MaxVal+  abs a = fmap abs a+  signum MinVal = Open (-1)+  signum MaxVal = Open 1+  signum a = fmap signum a   fromInteger = DefaultBound . fromInteger  -- | An empty object
Database/RethinkDB/Wire/Response.hs view
@@ -1,27 +1,39 @@ module Database.RethinkDB.Wire.Response where import Prelude (Maybe(..), Eq, Show) import Database.RethinkDB.Wire-data ResponseType = SUCCESS_ATOM | SUCCESS_SEQUENCE | SUCCESS_PARTIAL | SUCCESS_FEED | WAIT_COMPLETE | SUCCESS_ATOM_FEED | CLIENT_ERROR | COMPILE_ERROR | RUNTIME_ERROR+data ResponseType = SUCCESS_ATOM | SUCCESS_SEQUENCE | SUCCESS_PARTIAL | WAIT_COMPLETE | CLIENT_ERROR | COMPILE_ERROR | RUNTIME_ERROR   deriving (Eq, Show) instance WireValue ResponseType where   toWire SUCCESS_ATOM = 1   toWire SUCCESS_SEQUENCE = 2   toWire SUCCESS_PARTIAL = 3-  toWire SUCCESS_FEED = 5   toWire WAIT_COMPLETE = 4-  toWire SUCCESS_ATOM_FEED = 6   toWire CLIENT_ERROR = 16   toWire COMPILE_ERROR = 17   toWire RUNTIME_ERROR = 18   fromWire 1 = Just SUCCESS_ATOM   fromWire 2 = Just SUCCESS_SEQUENCE   fromWire 3 = Just SUCCESS_PARTIAL-  fromWire 5 = Just SUCCESS_FEED   fromWire 4 = Just WAIT_COMPLETE-  fromWire 6 = Just SUCCESS_ATOM_FEED   fromWire 16 = Just CLIENT_ERROR   fromWire 17 = Just COMPILE_ERROR   fromWire 18 = Just RUNTIME_ERROR+  fromWire _ = Nothing+++data ResponseNote = SEQUENCE_FEED | ATOM_FEED | ORDER_BY_LIMIT_FEED | UNIONED_FEED | INCLUDES_STATES+  deriving (Eq, Show)+instance WireValue ResponseNote where+  toWire SEQUENCE_FEED = 1+  toWire ATOM_FEED = 2+  toWire ORDER_BY_LIMIT_FEED = 3+  toWire UNIONED_FEED = 4+  toWire INCLUDES_STATES = 5+  fromWire 1 = Just SEQUENCE_FEED+  fromWire 2 = Just ATOM_FEED+  fromWire 3 = Just ORDER_BY_LIMIT_FEED+  fromWire 4 = Just UNIONED_FEED+  fromWire 5 = Just INCLUDES_STATES   fromWire _ = Nothing  
Database/RethinkDB/Wire/Term.hs view
@@ -1,7 +1,7 @@ module Database.RethinkDB.Wire.Term where import Prelude (Maybe(..), Eq, Show) import Database.RethinkDB.Wire-data TermType = DATUM | MAKE_ARRAY | MAKE_OBJ | VAR | JAVASCRIPT | UUID | HTTP | ERROR | IMPLICIT_VAR | DB | TABLE | GET | GET_ALL | EQ | NE | LT | LE | GT | GE | NOT | ADD | SUB | MUL | DIV | MOD | APPEND | PREPEND | DIFFERENCE | SET_INSERT | SET_INTERSECTION | SET_UNION | SET_DIFFERENCE | SLICE | SKIP | LIMIT | INDEXES_OF | CONTAINS | GET_FIELD | KEYS | OBJECT | HAS_FIELDS | WITH_FIELDS | PLUCK | WITHOUT | MERGE | BETWEEN | REDUCE | MAP | FILTER | CONCAT_MAP | ORDER_BY | DISTINCT | COUNT | IS_EMPTY | UNION | NTH | BRACKET | INNER_JOIN | OUTER_JOIN | EQ_JOIN | ZIP | RANGE | INSERT_AT | DELETE_AT | CHANGE_AT | SPLICE_AT | COERCE_TO | TYPE_OF | UPDATE | DELETE | REPLACE | INSERT | DB_CREATE | DB_DROP | DB_LIST | TABLE_CREATE | TABLE_DROP | TABLE_LIST | CONFIG | STATUS | WAIT | RECONFIGURE | REBALANCE | SYNC | INDEX_CREATE | INDEX_DROP | INDEX_LIST | INDEX_STATUS | INDEX_WAIT | INDEX_RENAME | FUNCALL | BRANCH | ANY | ALL | FOR_EACH | FUNC | ASC | DESC | INFO | MATCH | UPCASE | DOWNCASE | SAMPLE | DEFAULT | JSON | TO_JSON_STRING | ISO8601 | TO_ISO8601 | EPOCH_TIME | TO_EPOCH_TIME | NOW | IN_TIMEZONE | DURING | DATE | TIME_OF_DAY | TIMEZONE | YEAR | MONTH | DAY | DAY_OF_WEEK | DAY_OF_YEAR | HOURS | MINUTES | SECONDS | TIME | MONDAY | TUESDAY | WEDNESDAY | THURSDAY | FRIDAY | SATURDAY | SUNDAY | JANUARY | FEBRUARY | MARCH | APRIL | MAY | JUNE | JULY | AUGUST | SEPTEMBER | OCTOBER | NOVEMBER | DECEMBER | LITERAL | GROUP | SUM | AVG | MIN | MAX | SPLIT | UNGROUP | RANDOM | CHANGES | ARGS | BINARY | GEOJSON | TO_GEOJSON | POINT | LINE | POLYGON | DISTANCE | INTERSECTS | INCLUDES | CIRCLE | GET_INTERSECTING | FILL | GET_NEAREST | POLYGON_SUB+data TermType = DATUM | MAKE_ARRAY | MAKE_OBJ | VAR | JAVASCRIPT | UUID | HTTP | ERROR | IMPLICIT_VAR | DB | TABLE | GET | GET_ALL | EQ | NE | LT | LE | GT | GE | NOT | ADD | SUB | MUL | DIV | MOD | APPEND | PREPEND | DIFFERENCE | SET_INSERT | SET_INTERSECTION | SET_UNION | SET_DIFFERENCE | SLICE | SKIP | LIMIT | OFFSETS_OF | CONTAINS | GET_FIELD | KEYS | OBJECT | HAS_FIELDS | WITH_FIELDS | PLUCK | WITHOUT | MERGE | BETWEEN_DEPRECATED | BETWEEN | REDUCE | MAP | FILTER | CONCAT_MAP | ORDER_BY | DISTINCT | COUNT | IS_EMPTY | UNION | NTH | BRACKET | INNER_JOIN | OUTER_JOIN | EQ_JOIN | ZIP | RANGE | INSERT_AT | DELETE_AT | CHANGE_AT | SPLICE_AT | COERCE_TO | TYPE_OF | UPDATE | DELETE | REPLACE | INSERT | DB_CREATE | DB_DROP | DB_LIST | TABLE_CREATE | TABLE_DROP | TABLE_LIST | CONFIG | STATUS | WAIT | RECONFIGURE | REBALANCE | SYNC | INDEX_CREATE | INDEX_DROP | INDEX_LIST | INDEX_STATUS | INDEX_WAIT | INDEX_RENAME | FUNCALL | BRANCH | OR | AND | FOR_EACH | FUNC | ASC | DESC | INFO | MATCH | UPCASE | DOWNCASE | SAMPLE | DEFAULT | JSON | TO_JSON_STRING | ISO8601 | TO_ISO8601 | EPOCH_TIME | TO_EPOCH_TIME | NOW | IN_TIMEZONE | DURING | DATE | TIME_OF_DAY | TIMEZONE | YEAR | MONTH | DAY | DAY_OF_WEEK | DAY_OF_YEAR | HOURS | MINUTES | SECONDS | TIME | MONDAY | TUESDAY | WEDNESDAY | THURSDAY | FRIDAY | SATURDAY | SUNDAY | JANUARY | FEBRUARY | MARCH | APRIL | MAY | JUNE | JULY | AUGUST | SEPTEMBER | OCTOBER | NOVEMBER | DECEMBER | LITERAL | GROUP | SUM | AVG | MIN | MAX | SPLIT | UNGROUP | RANDOM | CHANGES | ARGS | BINARY | GEOJSON | TO_GEOJSON | POINT | LINE | POLYGON | DISTANCE | INTERSECTS | INCLUDES | CIRCLE | GET_INTERSECTING | FILL | GET_NEAREST | POLYGON_SUB | MINVAL | MAXVAL   deriving (Eq, Show) instance WireValue TermType where   toWire DATUM = 1@@ -39,7 +39,7 @@   toWire SLICE = 30   toWire SKIP = 70   toWire LIMIT = 71-  toWire INDEXES_OF = 87+  toWire OFFSETS_OF = 87   toWire CONTAINS = 93   toWire GET_FIELD = 31   toWire KEYS = 94@@ -49,7 +49,8 @@   toWire PLUCK = 33   toWire WITHOUT = 34   toWire MERGE = 35-  toWire BETWEEN = 36+  toWire BETWEEN_DEPRECATED = 36+  toWire BETWEEN = 182   toWire REDUCE = 37   toWire MAP = 38   toWire FILTER = 39@@ -96,8 +97,8 @@   toWire INDEX_RENAME = 156   toWire FUNCALL = 64   toWire BRANCH = 65-  toWire ANY = 66-  toWire ALL = 67+  toWire OR = 66+  toWire AND = 67   toWire FOR_EACH = 68   toWire FUNC = 69   toWire ASC = 73@@ -173,6 +174,8 @@   toWire FILL = 167   toWire GET_NEAREST = 168   toWire POLYGON_SUB = 171+  toWire MINVAL = 180+  toWire MAXVAL = 181   fromWire 1 = Just DATUM   fromWire 2 = Just MAKE_ARRAY   fromWire 3 = Just MAKE_OBJ@@ -208,7 +211,7 @@   fromWire 30 = Just SLICE   fromWire 70 = Just SKIP   fromWire 71 = Just LIMIT-  fromWire 87 = Just INDEXES_OF+  fromWire 87 = Just OFFSETS_OF   fromWire 93 = Just CONTAINS   fromWire 31 = Just GET_FIELD   fromWire 94 = Just KEYS@@ -218,7 +221,8 @@   fromWire 33 = Just PLUCK   fromWire 34 = Just WITHOUT   fromWire 35 = Just MERGE-  fromWire 36 = Just BETWEEN+  fromWire 36 = Just BETWEEN_DEPRECATED+  fromWire 182 = Just BETWEEN   fromWire 37 = Just REDUCE   fromWire 38 = Just MAP   fromWire 39 = Just FILTER@@ -265,8 +269,8 @@   fromWire 156 = Just INDEX_RENAME   fromWire 64 = Just FUNCALL   fromWire 65 = Just BRANCH-  fromWire 66 = Just ANY-  fromWire 67 = Just ALL+  fromWire 66 = Just OR+  fromWire 67 = Just AND   fromWire 68 = Just FOR_EACH   fromWire 69 = Just FUNC   fromWire 73 = Just ASC@@ -342,6 +346,8 @@   fromWire 167 = Just FILL   fromWire 168 = Just GET_NEAREST   fromWire 171 = Just POLYGON_SUB+  fromWire 180 = Just MINVAL+  fromWire 181 = Just MAXVAL   fromWire _ = Nothing  
Database/RethinkDB/Wire/VersionDummy.hs view
@@ -1,15 +1,17 @@ module Database.RethinkDB.Wire.VersionDummy where import Prelude (Maybe(..), Eq, Show) import Database.RethinkDB.Wire-data Version = V0_1 | V0_2 | V0_3+data Version = V0_1 | V0_2 | V0_3 | V0_4   deriving (Eq, Show) instance WireValue Version where   toWire V0_1 = 0x3f61ba36   toWire V0_2 = 0x723081e1   toWire V0_3 = 0x5f75e83e+  toWire V0_4 = 0x400c2d20   fromWire 0x3f61ba36 = Just V0_1   fromWire 0x723081e1 = Just V0_2   fromWire 0x5f75e83e = Just V0_3+  fromWire 0x400c2d20 = Just V0_4   fromWire _ = Nothing  
rethinkdb.cabal view
@@ -1,12 +1,12 @@ name: rethinkdb-version: 1.16.0.0+version: 2.0.0.0 cabal-version: >=1.8 build-type: Simple license: Apache license-file: LICENSE maintainer: Etienne Laurin <etienne@atnnn.com> homepage: http://github.com/atnnn/haskell-rethinkdb-synopsis: A driver for RethinkDB 1.16+synopsis: A driver for RethinkDB 2.0 description:     A driver for the RethinkDB database server category: Database@@ -22,18 +22,18 @@  library     build-depends:-        base >=4 && <4.8,+        base >=4 && <4.9,         unordered-containers ==0.2.*,         text >=0.11 && <1.3,-        aeson >=0.7 && <0.9,+        aeson >=0.7 && <0.10,         bytestring ==0.10.*,         containers ==0.5.*,         data-default ==0.5.*,         network >=2.4 && <2.7,         mtl >=2.1 && <2.3,         vector ==0.10.*,-        time ==1.4.*,-        utf8-string ==0.3.*,+        time >=1.4 && <1.6,+        utf8-string >=0.3 && <1.1,         binary >=0.5 && <0.8,         scientific ==0.3.*,         base64-bytestring ==1.0.*