module TD.Query.ToggleGroupCallIsMyVideoPaused
(ToggleGroupCallIsMyVideoPaused(..)
, defaultToggleGroupCallIsMyVideoPaused
) where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as AT
import qualified TD.Lib.Internal as I
data ToggleGroupCallIsMyVideoPaused
= ToggleGroupCallIsMyVideoPaused
{ ToggleGroupCallIsMyVideoPaused -> Maybe Int
group_call_id :: Maybe Int
, ToggleGroupCallIsMyVideoPaused -> Maybe Bool
is_my_video_paused :: Maybe Bool
}
deriving (ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool
(ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool)
-> (ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool)
-> Eq ToggleGroupCallIsMyVideoPaused
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool
== :: ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool
$c/= :: ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool
/= :: ToggleGroupCallIsMyVideoPaused
-> ToggleGroupCallIsMyVideoPaused -> Bool
Eq, Int -> ToggleGroupCallIsMyVideoPaused -> ShowS
[ToggleGroupCallIsMyVideoPaused] -> ShowS
ToggleGroupCallIsMyVideoPaused -> String
(Int -> ToggleGroupCallIsMyVideoPaused -> ShowS)
-> (ToggleGroupCallIsMyVideoPaused -> String)
-> ([ToggleGroupCallIsMyVideoPaused] -> ShowS)
-> Show ToggleGroupCallIsMyVideoPaused
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ToggleGroupCallIsMyVideoPaused -> ShowS
showsPrec :: Int -> ToggleGroupCallIsMyVideoPaused -> ShowS
$cshow :: ToggleGroupCallIsMyVideoPaused -> String
show :: ToggleGroupCallIsMyVideoPaused -> String
$cshowList :: [ToggleGroupCallIsMyVideoPaused] -> ShowS
showList :: [ToggleGroupCallIsMyVideoPaused] -> ShowS
Show)
instance I.ShortShow ToggleGroupCallIsMyVideoPaused where
shortShow :: ToggleGroupCallIsMyVideoPaused -> String
shortShow
ToggleGroupCallIsMyVideoPaused
{ group_call_id :: ToggleGroupCallIsMyVideoPaused -> Maybe Int
group_call_id = Maybe Int
group_call_id_
, is_my_video_paused :: ToggleGroupCallIsMyVideoPaused -> Maybe Bool
is_my_video_paused = Maybe Bool
is_my_video_paused_
}
= String
"ToggleGroupCallIsMyVideoPaused"
String -> ShowS
forall a. [a] -> [a] -> [a]
++ [String] -> String
I.cc
[ String
"group_call_id" String -> Maybe Int -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Int
group_call_id_
, String
"is_my_video_paused" String -> Maybe Bool -> String
forall a. ShortShow a => String -> Maybe a -> String
`I.p` Maybe Bool
is_my_video_paused_
]
instance AT.ToJSON ToggleGroupCallIsMyVideoPaused where
toJSON :: ToggleGroupCallIsMyVideoPaused -> Value
toJSON
ToggleGroupCallIsMyVideoPaused
{ group_call_id :: ToggleGroupCallIsMyVideoPaused -> Maybe Int
group_call_id = Maybe Int
group_call_id_
, is_my_video_paused :: ToggleGroupCallIsMyVideoPaused -> Maybe Bool
is_my_video_paused = Maybe Bool
is_my_video_paused_
}
= [Pair] -> Value
A.object
[ Key
"@type" Key -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Text -> Value
AT.String Text
"toggleGroupCallIsMyVideoPaused"
, Key
"group_call_id" Key -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Maybe Int
group_call_id_
, Key
"is_my_video_paused" Key -> Maybe Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
A..= Maybe Bool
is_my_video_paused_
]
defaultToggleGroupCallIsMyVideoPaused :: ToggleGroupCallIsMyVideoPaused
defaultToggleGroupCallIsMyVideoPaused :: ToggleGroupCallIsMyVideoPaused
defaultToggleGroupCallIsMyVideoPaused =
ToggleGroupCallIsMyVideoPaused
{ group_call_id :: Maybe Int
group_call_id = Maybe Int
forall a. Maybe a
Nothing
, is_my_video_paused :: Maybe Bool
is_my_video_paused = Maybe Bool
forall a. Maybe a
Nothing
}