{-# language DataKinds #-}
{-# language GADTs #-}
{-# language StandaloneKindSignatures #-}
module Rel8.Statement.Rows
( Rows (..)
)
where
import Data.Int (Int64)
import Data.Kind (Type)
import Prelude
import Rel8.Query (Query)
import Rel8.Table.Serialize (Serializable)
import Data.Vector (Vector)
type Rows :: Type -> Type -> Type
data Rows returning result where
Void :: Rows returning ()
RowsAffected :: Rows () Int64
Single :: Serializable exprs a => Rows (Query exprs) a
Maybe :: Serializable exprs a => Rows (Query exprs) (Maybe a)
List :: Serializable exprs a => Rows (Query exprs) [a]
Vector :: Serializable exprs a => Rows (Query exprs) (Vector a)