{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE DuplicateRecordFields #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE FunctionalDependencies #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} {-# OPTIONS_GHC -Wno-unused-imports #-} {-# OPTIONS_GHC -Wno-dodgy-exports #-} {-# OPTIONS_GHC -Wno-unused-matches #-} {-# OPTIONS_GHC -Wno-orphans #-} module Capnp.Gen.Capnp.Compat.Json.Pure(Value(..) ,Value'Field(..) ,Value'Call(..) ,FlattenOptions(..) ,DiscriminatorOptions(..)) where import qualified Capnp.GenHelpers.ReExports.Data.Vector as V import qualified Capnp.GenHelpers.ReExports.Data.Text as T import qualified Capnp.GenHelpers.ReExports.Data.ByteString as BS import qualified Capnp.GenHelpers.ReExports.Data.Default as Default import qualified GHC.Generics as Generics import qualified Control.Monad.IO.Class as MonadIO import qualified Capnp.Untyped.Pure as UntypedPure import qualified Capnp.Untyped as Untyped import qualified Capnp.Message as Message import qualified Capnp.Classes as Classes import qualified Capnp.Basics.Pure as BasicsPure import qualified Capnp.GenHelpers.Pure as GenHelpersPure import qualified Capnp.Gen.ById.X8ef99297a43a5e34 import qualified Prelude as Std_ import qualified Data.Word as Std_ import qualified Data.Int as Std_ import Prelude ((<$>), (<*>), (>>=)) data Value = Value'null | Value'boolean Std_.Bool | Value'number Std_.Double | Value'string T.Text | Value'array (V.Vector Value) | Value'object (V.Vector Value'Field) | Value'call Value'Call | Value'unknown' Std_.Word16 deriving(Int -> Value -> ShowS [Value] -> ShowS Value -> String (Int -> Value -> ShowS) -> (Value -> String) -> ([Value] -> ShowS) -> Show Value forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [Value] -> ShowS $cshowList :: [Value] -> ShowS show :: Value -> String $cshow :: Value -> String showsPrec :: Int -> Value -> ShowS $cshowsPrec :: Int -> Value -> ShowS Std_.Show ,Value -> Value -> Bool (Value -> Value -> Bool) -> (Value -> Value -> Bool) -> Eq Value forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: Value -> Value -> Bool $c/= :: Value -> Value -> Bool == :: Value -> Value -> Bool $c== :: Value -> Value -> Bool Std_.Eq ,(forall x. Value -> Rep Value x) -> (forall x. Rep Value x -> Value) -> Generic Value forall x. Rep Value x -> Value forall x. Value -> Rep Value x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep Value x -> Value $cfrom :: forall x. Value -> Rep Value x Generics.Generic) instance (Default.Default (Value)) where def :: Value def = Value forall a. (Decerialize a, FromStruct ConstMsg (Cerial ConstMsg a)) => a GenHelpersPure.defaultStruct instance (Classes.FromStruct Message.ConstMsg (Value)) where fromStruct :: Struct ConstMsg -> m Value fromStruct Struct ConstMsg struct = ((Struct ConstMsg -> m (Value ConstMsg) forall msg a (m :: * -> *). (FromStruct msg a, ReadCtx m msg) => Struct msg -> m a Classes.fromStruct Struct ConstMsg struct) m (Value ConstMsg) -> (Value ConstMsg -> m Value) -> m Value forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Value ConstMsg -> m Value forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) instance (Classes.Decerialize (Value)) where type Cerial msg (Value) = (Capnp.Gen.ById.X8ef99297a43a5e34.Value msg) decerialize :: Cerial ConstMsg Value -> m Value decerialize Cerial ConstMsg Value raw = (do Value' ConstMsg raw <- (Value ConstMsg -> m (Value' ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromStruct msg (Value' msg)) => Value msg -> m (Value' msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_Value' Cerial ConstMsg Value Value ConstMsg raw) case Value' ConstMsg raw of (Value' ConstMsg Capnp.Gen.ById.X8ef99297a43a5e34.Value'null) -> (Value -> m Value forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure Value Value'null) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'boolean Bool raw) -> (Value -> m Value forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure (Bool -> Value Value'boolean Bool raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'number Double raw) -> (Value -> m Value forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure (Double -> Value Value'number Double raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'string Text ConstMsg raw) -> (Text -> Value Value'string (Text -> Value) -> m Text -> m Value forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> (Cerial ConstMsg Text -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize Cerial ConstMsg Text Text ConstMsg raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'array List ConstMsg (Value ConstMsg) raw) -> (Vector Value -> Value Value'array (Vector Value -> Value) -> m (Vector Value) -> m Value forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> (Cerial ConstMsg (Vector Value) -> m (Vector Value) forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize Cerial ConstMsg (Vector Value) List ConstMsg (Value ConstMsg) raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'object List ConstMsg (Value'Field ConstMsg) raw) -> (Vector Value'Field -> Value Value'object (Vector Value'Field -> Value) -> m (Vector Value'Field) -> m Value forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> (Cerial ConstMsg (Vector Value'Field) -> m (Vector Value'Field) forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize Cerial ConstMsg (Vector Value'Field) List ConstMsg (Value'Field ConstMsg) raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'call Value'Call ConstMsg raw) -> (Value'Call -> Value Value'call (Value'Call -> Value) -> m Value'Call -> m Value forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> (Cerial ConstMsg Value'Call -> m Value'Call forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize Cerial ConstMsg Value'Call Value'Call ConstMsg raw)) (Capnp.Gen.ById.X8ef99297a43a5e34.Value'unknown' Word16 tag) -> (Value -> m Value forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure (Word16 -> Value Value'unknown' Word16 tag)) ) instance (Classes.Marshal s (Value)) where marshalInto :: Cerial (MutMsg s) Value -> Value -> m () marshalInto Cerial (MutMsg s) Value raw_ Value value_ = case Value value_ of (Value Value'null) -> (Value (MutMsg s) -> m () forall (m :: * -> *) s. RWCtx m s => Value (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'null Cerial (MutMsg s) Value Value (MutMsg s) raw_) (Value'boolean Bool arg_) -> (Value (MutMsg s) -> Bool -> m () forall (m :: * -> *) s. RWCtx m s => Value (MutMsg s) -> Bool -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'boolean Cerial (MutMsg s) Value Value (MutMsg s) raw_ Bool arg_) (Value'number Double arg_) -> (Value (MutMsg s) -> Double -> m () forall (m :: * -> *) s. RWCtx m s => Value (MutMsg s) -> Double -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'number Cerial (MutMsg s) Value Value (MutMsg s) raw_ Double arg_) (Value'string Text arg_) -> ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value (MutMsg s) -> InMessage (Value (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value Value (MutMsg s) raw_) Text arg_) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => Value (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'string Cerial (MutMsg s) Value Value (MutMsg s) raw_)) (Value'array Vector Value arg_) -> ((MutMsg s -> Vector Value -> m (Cerial (MutMsg s) (Vector Value)) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value (MutMsg s) -> InMessage (Value (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value Value (MutMsg s) raw_) Vector Value arg_) m (List (MutMsg s) (Value (MutMsg s))) -> (List (MutMsg s) (Value (MutMsg s)) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value (MutMsg s) -> List (MutMsg s) (Value (MutMsg s)) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (List (MutMsg s) (Value (MutMsg s)))) => Value (MutMsg s) -> List (MutMsg s) (Value (MutMsg s)) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'array Cerial (MutMsg s) Value Value (MutMsg s) raw_)) (Value'object Vector Value'Field arg_) -> ((MutMsg s -> Vector Value'Field -> m (Cerial (MutMsg s) (Vector Value'Field)) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value (MutMsg s) -> InMessage (Value (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value Value (MutMsg s) raw_) Vector Value'Field arg_) m (List (MutMsg s) (Value'Field (MutMsg s))) -> (List (MutMsg s) (Value'Field (MutMsg s)) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value (MutMsg s) -> List (MutMsg s) (Value'Field (MutMsg s)) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (List (MutMsg s) (Value'Field (MutMsg s)))) => Value (MutMsg s) -> List (MutMsg s) (Value'Field (MutMsg s)) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'object Cerial (MutMsg s) Value Value (MutMsg s) raw_)) (Value'call Value'Call arg_) -> ((MutMsg s -> Value'Call -> m (Cerial (MutMsg s) Value'Call) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value (MutMsg s) -> InMessage (Value (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value Value (MutMsg s) raw_) Value'Call arg_) m (Value'Call (MutMsg s)) -> (Value'Call (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value (MutMsg s) -> Value'Call (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Value'Call (MutMsg s))) => Value (MutMsg s) -> Value'Call (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'call Cerial (MutMsg s) Value Value (MutMsg s) raw_)) (Value'unknown' Word16 tag) -> (Value (MutMsg s) -> Word16 -> m () forall (m :: * -> *) s. RWCtx m s => Value (MutMsg s) -> Word16 -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'unknown' Cerial (MutMsg s) Value Value (MutMsg s) raw_ Word16 tag) instance (Classes.Cerialize s (Value)) instance (Classes.Cerialize s (V.Vector (Value))) where cerialize :: MutMsg s -> Vector Value -> m (Cerial (MutMsg s) (Vector Value)) cerialize = MutMsg s -> Vector Value -> m (Cerial (MutMsg s) (Vector Value)) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Marshal s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeCompositeVec instance (Classes.Cerialize s (V.Vector (V.Vector (Value)))) where cerialize :: MutMsg s -> Vector (Vector Value) -> m (Cerial (MutMsg s) (Vector (Vector Value))) cerialize = MutMsg s -> Vector (Vector Value) -> m (Cerial (MutMsg s) (Vector (Vector Value))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (Value))))) where cerialize :: MutMsg s -> Vector (Vector (Vector Value)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value)))) cerialize = MutMsg s -> Vector (Vector (Vector Value)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value)))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (Value)))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector Value))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector Value))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector Value)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value)))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector Value)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value)))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value)))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value))))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value)))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value)))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec data Value'Field = Value'Field {Value'Field -> Text name :: T.Text ,Value'Field -> Value value :: Value} deriving(Int -> Value'Field -> ShowS [Value'Field] -> ShowS Value'Field -> String (Int -> Value'Field -> ShowS) -> (Value'Field -> String) -> ([Value'Field] -> ShowS) -> Show Value'Field forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [Value'Field] -> ShowS $cshowList :: [Value'Field] -> ShowS show :: Value'Field -> String $cshow :: Value'Field -> String showsPrec :: Int -> Value'Field -> ShowS $cshowsPrec :: Int -> Value'Field -> ShowS Std_.Show ,Value'Field -> Value'Field -> Bool (Value'Field -> Value'Field -> Bool) -> (Value'Field -> Value'Field -> Bool) -> Eq Value'Field forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: Value'Field -> Value'Field -> Bool $c/= :: Value'Field -> Value'Field -> Bool == :: Value'Field -> Value'Field -> Bool $c== :: Value'Field -> Value'Field -> Bool Std_.Eq ,(forall x. Value'Field -> Rep Value'Field x) -> (forall x. Rep Value'Field x -> Value'Field) -> Generic Value'Field forall x. Rep Value'Field x -> Value'Field forall x. Value'Field -> Rep Value'Field x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep Value'Field x -> Value'Field $cfrom :: forall x. Value'Field -> Rep Value'Field x Generics.Generic) instance (Default.Default (Value'Field)) where def :: Value'Field def = Value'Field forall a. (Decerialize a, FromStruct ConstMsg (Cerial ConstMsg a)) => a GenHelpersPure.defaultStruct instance (Classes.FromStruct Message.ConstMsg (Value'Field)) where fromStruct :: Struct ConstMsg -> m Value'Field fromStruct Struct ConstMsg struct = ((Struct ConstMsg -> m (Value'Field ConstMsg) forall msg a (m :: * -> *). (FromStruct msg a, ReadCtx m msg) => Struct msg -> m a Classes.fromStruct Struct ConstMsg struct) m (Value'Field ConstMsg) -> (Value'Field ConstMsg -> m Value'Field) -> m Value'Field forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Value'Field ConstMsg -> m Value'Field forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) instance (Classes.Decerialize (Value'Field)) where type Cerial msg (Value'Field) = (Capnp.Gen.ById.X8ef99297a43a5e34.Value'Field msg) decerialize :: Cerial ConstMsg Value'Field -> m Value'Field decerialize Cerial ConstMsg Value'Field raw = (Text -> Value -> Value'Field Value'Field (Text -> Value -> Value'Field) -> m Text -> m (Value -> Value'Field) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> ((Value'Field ConstMsg -> m (Text ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Text msg)) => Value'Field msg -> m (Text msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_Value'Field'name Cerial ConstMsg Value'Field Value'Field ConstMsg raw) m (Text ConstMsg) -> (Text ConstMsg -> m Text) -> m Text forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Text ConstMsg -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) m (Value -> Value'Field) -> m Value -> m Value'Field forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b <*> ((Value'Field ConstMsg -> m (Value ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Value msg)) => Value'Field msg -> m (Value msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_Value'Field'value Cerial ConstMsg Value'Field Value'Field ConstMsg raw) m (Value ConstMsg) -> (Value ConstMsg -> m Value) -> m Value forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Value ConstMsg -> m Value forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize)) instance (Classes.Marshal s (Value'Field)) where marshalInto :: Cerial (MutMsg s) Value'Field -> Value'Field -> m () marshalInto Cerial (MutMsg s) Value'Field raw_ Value'Field value_ = case Value'Field value_ of Value'Field{Text Value value :: Value name :: Text $sel:value:Value'Field :: Value'Field -> Value $sel:name:Value'Field :: Value'Field -> Text ..} -> (do ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value'Field (MutMsg s) -> InMessage (Value'Field (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value'Field Value'Field (MutMsg s) raw_) Text name) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value'Field (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => Value'Field (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'Field'name Cerial (MutMsg s) Value'Field Value'Field (MutMsg s) raw_)) ((MutMsg s -> Value -> m (Cerial (MutMsg s) Value) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value'Field (MutMsg s) -> InMessage (Value'Field (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value'Field Value'Field (MutMsg s) raw_) Value value) m (Value (MutMsg s)) -> (Value (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value'Field (MutMsg s) -> Value (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Value (MutMsg s))) => Value'Field (MutMsg s) -> Value (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'Field'value Cerial (MutMsg s) Value'Field Value'Field (MutMsg s) raw_)) (() -> m () forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure ()) ) instance (Classes.Cerialize s (Value'Field)) instance (Classes.Cerialize s (V.Vector (Value'Field))) where cerialize :: MutMsg s -> Vector Value'Field -> m (Cerial (MutMsg s) (Vector Value'Field)) cerialize = MutMsg s -> Vector Value'Field -> m (Cerial (MutMsg s) (Vector Value'Field)) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Marshal s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeCompositeVec instance (Classes.Cerialize s (V.Vector (V.Vector (Value'Field)))) where cerialize :: MutMsg s -> Vector (Vector Value'Field) -> m (Cerial (MutMsg s) (Vector (Vector Value'Field))) cerialize = MutMsg s -> Vector (Vector Value'Field) -> m (Cerial (MutMsg s) (Vector (Vector Value'Field))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (Value'Field))))) where cerialize :: MutMsg s -> Vector (Vector (Vector Value'Field)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value'Field)))) cerialize = MutMsg s -> Vector (Vector (Vector Value'Field)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value'Field)))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (Value'Field)))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector Value'Field))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value'Field))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector Value'Field))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value'Field))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Field))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector Value'Field)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value'Field)))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector Value'Field)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value'Field)))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Field)))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value'Field))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value'Field))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value'Field))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value'Field))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Field))))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Field)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Field)))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Field)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Field)))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec data Value'Call = Value'Call {Value'Call -> Text function :: T.Text ,Value'Call -> Vector Value params :: (V.Vector Value)} deriving(Int -> Value'Call -> ShowS [Value'Call] -> ShowS Value'Call -> String (Int -> Value'Call -> ShowS) -> (Value'Call -> String) -> ([Value'Call] -> ShowS) -> Show Value'Call forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [Value'Call] -> ShowS $cshowList :: [Value'Call] -> ShowS show :: Value'Call -> String $cshow :: Value'Call -> String showsPrec :: Int -> Value'Call -> ShowS $cshowsPrec :: Int -> Value'Call -> ShowS Std_.Show ,Value'Call -> Value'Call -> Bool (Value'Call -> Value'Call -> Bool) -> (Value'Call -> Value'Call -> Bool) -> Eq Value'Call forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: Value'Call -> Value'Call -> Bool $c/= :: Value'Call -> Value'Call -> Bool == :: Value'Call -> Value'Call -> Bool $c== :: Value'Call -> Value'Call -> Bool Std_.Eq ,(forall x. Value'Call -> Rep Value'Call x) -> (forall x. Rep Value'Call x -> Value'Call) -> Generic Value'Call forall x. Rep Value'Call x -> Value'Call forall x. Value'Call -> Rep Value'Call x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep Value'Call x -> Value'Call $cfrom :: forall x. Value'Call -> Rep Value'Call x Generics.Generic) instance (Default.Default (Value'Call)) where def :: Value'Call def = Value'Call forall a. (Decerialize a, FromStruct ConstMsg (Cerial ConstMsg a)) => a GenHelpersPure.defaultStruct instance (Classes.FromStruct Message.ConstMsg (Value'Call)) where fromStruct :: Struct ConstMsg -> m Value'Call fromStruct Struct ConstMsg struct = ((Struct ConstMsg -> m (Value'Call ConstMsg) forall msg a (m :: * -> *). (FromStruct msg a, ReadCtx m msg) => Struct msg -> m a Classes.fromStruct Struct ConstMsg struct) m (Value'Call ConstMsg) -> (Value'Call ConstMsg -> m Value'Call) -> m Value'Call forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Value'Call ConstMsg -> m Value'Call forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) instance (Classes.Decerialize (Value'Call)) where type Cerial msg (Value'Call) = (Capnp.Gen.ById.X8ef99297a43a5e34.Value'Call msg) decerialize :: Cerial ConstMsg Value'Call -> m Value'Call decerialize Cerial ConstMsg Value'Call raw = (Text -> Vector Value -> Value'Call Value'Call (Text -> Vector Value -> Value'Call) -> m Text -> m (Vector Value -> Value'Call) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> ((Value'Call ConstMsg -> m (Text ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Text msg)) => Value'Call msg -> m (Text msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_Value'Call'function Cerial ConstMsg Value'Call Value'Call ConstMsg raw) m (Text ConstMsg) -> (Text ConstMsg -> m Text) -> m Text forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Text ConstMsg -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) m (Vector Value -> Value'Call) -> m (Vector Value) -> m Value'Call forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b <*> ((Value'Call ConstMsg -> m (List ConstMsg (Value ConstMsg)) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (List msg (Value msg))) => Value'Call msg -> m (List msg (Value msg)) Capnp.Gen.ById.X8ef99297a43a5e34.get_Value'Call'params Cerial ConstMsg Value'Call Value'Call ConstMsg raw) m (List ConstMsg (Value ConstMsg)) -> (List ConstMsg (Value ConstMsg) -> m (Vector Value)) -> m (Vector Value) forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= List ConstMsg (Value ConstMsg) -> m (Vector Value) forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize)) instance (Classes.Marshal s (Value'Call)) where marshalInto :: Cerial (MutMsg s) Value'Call -> Value'Call -> m () marshalInto Cerial (MutMsg s) Value'Call raw_ Value'Call value_ = case Value'Call value_ of Value'Call{Text Vector Value params :: Vector Value function :: Text $sel:params:Value'Call :: Value'Call -> Vector Value $sel:function:Value'Call :: Value'Call -> Text ..} -> (do ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value'Call (MutMsg s) -> InMessage (Value'Call (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value'Call Value'Call (MutMsg s) raw_) Text function) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value'Call (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => Value'Call (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'Call'function Cerial (MutMsg s) Value'Call Value'Call (MutMsg s) raw_)) ((MutMsg s -> Vector Value -> m (Cerial (MutMsg s) (Vector Value)) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (Value'Call (MutMsg s) -> InMessage (Value'Call (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) Value'Call Value'Call (MutMsg s) raw_) Vector Value params) m (List (MutMsg s) (Value (MutMsg s))) -> (List (MutMsg s) (Value (MutMsg s)) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (Value'Call (MutMsg s) -> List (MutMsg s) (Value (MutMsg s)) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (List (MutMsg s) (Value (MutMsg s)))) => Value'Call (MutMsg s) -> List (MutMsg s) (Value (MutMsg s)) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_Value'Call'params Cerial (MutMsg s) Value'Call Value'Call (MutMsg s) raw_)) (() -> m () forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure ()) ) instance (Classes.Cerialize s (Value'Call)) instance (Classes.Cerialize s (V.Vector (Value'Call))) where cerialize :: MutMsg s -> Vector Value'Call -> m (Cerial (MutMsg s) (Vector Value'Call)) cerialize = MutMsg s -> Vector Value'Call -> m (Cerial (MutMsg s) (Vector Value'Call)) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Marshal s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeCompositeVec instance (Classes.Cerialize s (V.Vector (V.Vector (Value'Call)))) where cerialize :: MutMsg s -> Vector (Vector Value'Call) -> m (Cerial (MutMsg s) (Vector (Vector Value'Call))) cerialize = MutMsg s -> Vector (Vector Value'Call) -> m (Cerial (MutMsg s) (Vector (Vector Value'Call))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (Value'Call))))) where cerialize :: MutMsg s -> Vector (Vector (Vector Value'Call)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value'Call)))) cerialize = MutMsg s -> Vector (Vector (Vector Value'Call)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector Value'Call)))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (Value'Call)))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector Value'Call))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value'Call))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector Value'Call))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector Value'Call))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Call))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector Value'Call)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value'Call)))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector Value'Call)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector Value'Call)))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Call)))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value'Call))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value'Call))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector Value'Call))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector Value'Call))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (Value'Call))))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Call)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Call)))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Call)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector Value'Call)))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec data FlattenOptions = FlattenOptions {FlattenOptions -> Text prefix :: T.Text} deriving(Int -> FlattenOptions -> ShowS [FlattenOptions] -> ShowS FlattenOptions -> String (Int -> FlattenOptions -> ShowS) -> (FlattenOptions -> String) -> ([FlattenOptions] -> ShowS) -> Show FlattenOptions forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [FlattenOptions] -> ShowS $cshowList :: [FlattenOptions] -> ShowS show :: FlattenOptions -> String $cshow :: FlattenOptions -> String showsPrec :: Int -> FlattenOptions -> ShowS $cshowsPrec :: Int -> FlattenOptions -> ShowS Std_.Show ,FlattenOptions -> FlattenOptions -> Bool (FlattenOptions -> FlattenOptions -> Bool) -> (FlattenOptions -> FlattenOptions -> Bool) -> Eq FlattenOptions forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: FlattenOptions -> FlattenOptions -> Bool $c/= :: FlattenOptions -> FlattenOptions -> Bool == :: FlattenOptions -> FlattenOptions -> Bool $c== :: FlattenOptions -> FlattenOptions -> Bool Std_.Eq ,(forall x. FlattenOptions -> Rep FlattenOptions x) -> (forall x. Rep FlattenOptions x -> FlattenOptions) -> Generic FlattenOptions forall x. Rep FlattenOptions x -> FlattenOptions forall x. FlattenOptions -> Rep FlattenOptions x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep FlattenOptions x -> FlattenOptions $cfrom :: forall x. FlattenOptions -> Rep FlattenOptions x Generics.Generic) instance (Default.Default (FlattenOptions)) where def :: FlattenOptions def = FlattenOptions forall a. (Decerialize a, FromStruct ConstMsg (Cerial ConstMsg a)) => a GenHelpersPure.defaultStruct instance (Classes.FromStruct Message.ConstMsg (FlattenOptions)) where fromStruct :: Struct ConstMsg -> m FlattenOptions fromStruct Struct ConstMsg struct = ((Struct ConstMsg -> m (FlattenOptions ConstMsg) forall msg a (m :: * -> *). (FromStruct msg a, ReadCtx m msg) => Struct msg -> m a Classes.fromStruct Struct ConstMsg struct) m (FlattenOptions ConstMsg) -> (FlattenOptions ConstMsg -> m FlattenOptions) -> m FlattenOptions forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= FlattenOptions ConstMsg -> m FlattenOptions forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) instance (Classes.Decerialize (FlattenOptions)) where type Cerial msg (FlattenOptions) = (Capnp.Gen.ById.X8ef99297a43a5e34.FlattenOptions msg) decerialize :: Cerial ConstMsg FlattenOptions -> m FlattenOptions decerialize Cerial ConstMsg FlattenOptions raw = (Text -> FlattenOptions FlattenOptions (Text -> FlattenOptions) -> m Text -> m FlattenOptions forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> ((FlattenOptions ConstMsg -> m (Text ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Text msg)) => FlattenOptions msg -> m (Text msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_FlattenOptions'prefix Cerial ConstMsg FlattenOptions FlattenOptions ConstMsg raw) m (Text ConstMsg) -> (Text ConstMsg -> m Text) -> m Text forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Text ConstMsg -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize)) instance (Classes.Marshal s (FlattenOptions)) where marshalInto :: Cerial (MutMsg s) FlattenOptions -> FlattenOptions -> m () marshalInto Cerial (MutMsg s) FlattenOptions raw_ FlattenOptions value_ = case FlattenOptions value_ of FlattenOptions{Text prefix :: Text $sel:prefix:FlattenOptions :: FlattenOptions -> Text ..} -> (do ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (FlattenOptions (MutMsg s) -> InMessage (FlattenOptions (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) FlattenOptions FlattenOptions (MutMsg s) raw_) Text prefix) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (FlattenOptions (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => FlattenOptions (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_FlattenOptions'prefix Cerial (MutMsg s) FlattenOptions FlattenOptions (MutMsg s) raw_)) (() -> m () forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure ()) ) instance (Classes.Cerialize s (FlattenOptions)) instance (Classes.Cerialize s (V.Vector (FlattenOptions))) where cerialize :: MutMsg s -> Vector FlattenOptions -> m (Cerial (MutMsg s) (Vector FlattenOptions)) cerialize = MutMsg s -> Vector FlattenOptions -> m (Cerial (MutMsg s) (Vector FlattenOptions)) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Marshal s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeCompositeVec instance (Classes.Cerialize s (V.Vector (V.Vector (FlattenOptions)))) where cerialize :: MutMsg s -> Vector (Vector FlattenOptions) -> m (Cerial (MutMsg s) (Vector (Vector FlattenOptions))) cerialize = MutMsg s -> Vector (Vector FlattenOptions) -> m (Cerial (MutMsg s) (Vector (Vector FlattenOptions))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (FlattenOptions))))) where cerialize :: MutMsg s -> Vector (Vector (Vector FlattenOptions)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector FlattenOptions)))) cerialize = MutMsg s -> Vector (Vector (Vector FlattenOptions)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector FlattenOptions)))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (FlattenOptions)))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector FlattenOptions))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector FlattenOptions))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector FlattenOptions))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector FlattenOptions))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (FlattenOptions))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector FlattenOptions)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector FlattenOptions)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (FlattenOptions)))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (FlattenOptions))))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector FlattenOptions)))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec data DiscriminatorOptions = DiscriminatorOptions {DiscriminatorOptions -> Text name :: T.Text ,DiscriminatorOptions -> Text valueName :: T.Text} deriving(Int -> DiscriminatorOptions -> ShowS [DiscriminatorOptions] -> ShowS DiscriminatorOptions -> String (Int -> DiscriminatorOptions -> ShowS) -> (DiscriminatorOptions -> String) -> ([DiscriminatorOptions] -> ShowS) -> Show DiscriminatorOptions forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [DiscriminatorOptions] -> ShowS $cshowList :: [DiscriminatorOptions] -> ShowS show :: DiscriminatorOptions -> String $cshow :: DiscriminatorOptions -> String showsPrec :: Int -> DiscriminatorOptions -> ShowS $cshowsPrec :: Int -> DiscriminatorOptions -> ShowS Std_.Show ,DiscriminatorOptions -> DiscriminatorOptions -> Bool (DiscriminatorOptions -> DiscriminatorOptions -> Bool) -> (DiscriminatorOptions -> DiscriminatorOptions -> Bool) -> Eq DiscriminatorOptions forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: DiscriminatorOptions -> DiscriminatorOptions -> Bool $c/= :: DiscriminatorOptions -> DiscriminatorOptions -> Bool == :: DiscriminatorOptions -> DiscriminatorOptions -> Bool $c== :: DiscriminatorOptions -> DiscriminatorOptions -> Bool Std_.Eq ,(forall x. DiscriminatorOptions -> Rep DiscriminatorOptions x) -> (forall x. Rep DiscriminatorOptions x -> DiscriminatorOptions) -> Generic DiscriminatorOptions forall x. Rep DiscriminatorOptions x -> DiscriminatorOptions forall x. DiscriminatorOptions -> Rep DiscriminatorOptions x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep DiscriminatorOptions x -> DiscriminatorOptions $cfrom :: forall x. DiscriminatorOptions -> Rep DiscriminatorOptions x Generics.Generic) instance (Default.Default (DiscriminatorOptions)) where def :: DiscriminatorOptions def = DiscriminatorOptions forall a. (Decerialize a, FromStruct ConstMsg (Cerial ConstMsg a)) => a GenHelpersPure.defaultStruct instance (Classes.FromStruct Message.ConstMsg (DiscriminatorOptions)) where fromStruct :: Struct ConstMsg -> m DiscriminatorOptions fromStruct Struct ConstMsg struct = ((Struct ConstMsg -> m (DiscriminatorOptions ConstMsg) forall msg a (m :: * -> *). (FromStruct msg a, ReadCtx m msg) => Struct msg -> m a Classes.fromStruct Struct ConstMsg struct) m (DiscriminatorOptions ConstMsg) -> (DiscriminatorOptions ConstMsg -> m DiscriminatorOptions) -> m DiscriminatorOptions forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= DiscriminatorOptions ConstMsg -> m DiscriminatorOptions forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) instance (Classes.Decerialize (DiscriminatorOptions)) where type Cerial msg (DiscriminatorOptions) = (Capnp.Gen.ById.X8ef99297a43a5e34.DiscriminatorOptions msg) decerialize :: Cerial ConstMsg DiscriminatorOptions -> m DiscriminatorOptions decerialize Cerial ConstMsg DiscriminatorOptions raw = (Text -> Text -> DiscriminatorOptions DiscriminatorOptions (Text -> Text -> DiscriminatorOptions) -> m Text -> m (Text -> DiscriminatorOptions) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> ((DiscriminatorOptions ConstMsg -> m (Text ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Text msg)) => DiscriminatorOptions msg -> m (Text msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_DiscriminatorOptions'name Cerial ConstMsg DiscriminatorOptions DiscriminatorOptions ConstMsg raw) m (Text ConstMsg) -> (Text ConstMsg -> m Text) -> m Text forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Text ConstMsg -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize) m (Text -> DiscriminatorOptions) -> m Text -> m DiscriminatorOptions forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b <*> ((DiscriminatorOptions ConstMsg -> m (Text ConstMsg) forall (m :: * -> *) msg. (ReadCtx m msg, FromPtr msg (Text msg)) => DiscriminatorOptions msg -> m (Text msg) Capnp.Gen.ById.X8ef99297a43a5e34.get_DiscriminatorOptions'valueName Cerial ConstMsg DiscriminatorOptions DiscriminatorOptions ConstMsg raw) m (Text ConstMsg) -> (Text ConstMsg -> m Text) -> m Text forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= Text ConstMsg -> m Text forall a (m :: * -> *). (Decerialize a, ReadCtx m ConstMsg) => Cerial ConstMsg a -> m a Classes.decerialize)) instance (Classes.Marshal s (DiscriminatorOptions)) where marshalInto :: Cerial (MutMsg s) DiscriminatorOptions -> DiscriminatorOptions -> m () marshalInto Cerial (MutMsg s) DiscriminatorOptions raw_ DiscriminatorOptions value_ = case DiscriminatorOptions value_ of DiscriminatorOptions{Text valueName :: Text name :: Text $sel:valueName:DiscriminatorOptions :: DiscriminatorOptions -> Text $sel:name:DiscriminatorOptions :: DiscriminatorOptions -> Text ..} -> (do ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (DiscriminatorOptions (MutMsg s) -> InMessage (DiscriminatorOptions (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) DiscriminatorOptions DiscriminatorOptions (MutMsg s) raw_) Text name) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (DiscriminatorOptions (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => DiscriminatorOptions (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_DiscriminatorOptions'name Cerial (MutMsg s) DiscriminatorOptions DiscriminatorOptions (MutMsg s) raw_)) ((MutMsg s -> Text -> m (Cerial (MutMsg s) Text) forall s a (m :: * -> *). (Cerialize s a, RWCtx m s) => MutMsg s -> a -> m (Cerial (MutMsg s) a) Classes.cerialize (DiscriminatorOptions (MutMsg s) -> InMessage (DiscriminatorOptions (MutMsg s)) forall a. HasMessage a => a -> InMessage a Untyped.message Cerial (MutMsg s) DiscriminatorOptions DiscriminatorOptions (MutMsg s) raw_) Text valueName) m (Text (MutMsg s)) -> (Text (MutMsg s) -> m ()) -> m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b >>= (DiscriminatorOptions (MutMsg s) -> Text (MutMsg s) -> m () forall (m :: * -> *) s. (RWCtx m s, ToPtr s (Text (MutMsg s))) => DiscriminatorOptions (MutMsg s) -> Text (MutMsg s) -> m () Capnp.Gen.ById.X8ef99297a43a5e34.set_DiscriminatorOptions'valueName Cerial (MutMsg s) DiscriminatorOptions DiscriminatorOptions (MutMsg s) raw_)) (() -> m () forall (f :: * -> *) a. Applicative f => a -> f a Std_.pure ()) ) instance (Classes.Cerialize s (DiscriminatorOptions)) instance (Classes.Cerialize s (V.Vector (DiscriminatorOptions))) where cerialize :: MutMsg s -> Vector DiscriminatorOptions -> m (Cerial (MutMsg s) (Vector DiscriminatorOptions)) cerialize = MutMsg s -> Vector DiscriminatorOptions -> m (Cerial (MutMsg s) (Vector DiscriminatorOptions)) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Marshal s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeCompositeVec instance (Classes.Cerialize s (V.Vector (V.Vector (DiscriminatorOptions)))) where cerialize :: MutMsg s -> Vector (Vector DiscriminatorOptions) -> m (Cerial (MutMsg s) (Vector (Vector DiscriminatorOptions))) cerialize = MutMsg s -> Vector (Vector DiscriminatorOptions) -> m (Cerial (MutMsg s) (Vector (Vector DiscriminatorOptions))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (DiscriminatorOptions))))) where cerialize :: MutMsg s -> Vector (Vector (Vector DiscriminatorOptions)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector DiscriminatorOptions)))) cerialize = MutMsg s -> Vector (Vector (Vector DiscriminatorOptions)) -> m (Cerial (MutMsg s) (Vector (Vector (Vector DiscriminatorOptions)))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (DiscriminatorOptions)))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector DiscriminatorOptions))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector DiscriminatorOptions))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector DiscriminatorOptions))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector DiscriminatorOptions))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (DiscriminatorOptions))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (DiscriminatorOptions)))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec instance (Classes.Cerialize s (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (V.Vector (DiscriminatorOptions))))))))) where cerialize :: MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))))) cerialize = MutMsg s -> Vector (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))) -> m (Cerial (MutMsg s) (Vector (Vector (Vector (Vector (Vector (Vector (Vector DiscriminatorOptions)))))))) forall (m :: * -> *) s a. (RWCtx m s, MutListElem s (Cerial (MutMsg s) a), Cerialize s a) => MutMsg s -> Vector a -> m (List (MutMsg s) (Cerial (MutMsg s) a)) GenHelpersPure.cerializeBasicVec