{-# LANGUAGE DeriveGeneric #-}
module Telegram.Bot.API.Types.ProximityAlertTriggered where
import Data.Aeson (FromJSON (..), ToJSON (..))
import GHC.Generics (Generic)
import Telegram.Bot.API.Types.User
import Telegram.Bot.API.Internal.Utils
data ProximityAlertTriggered = ProximityAlertTriggered
{ ProximityAlertTriggered -> User
proximityAlertTriggeredTraveler :: User
, ProximityAlertTriggered -> User
proximityAlertTriggeredWatcher :: User
, ProximityAlertTriggered -> Int
proximityAlertTriggeredDistance :: Int
}
deriving (forall x. Rep ProximityAlertTriggered x -> ProximityAlertTriggered
forall x. ProximityAlertTriggered -> Rep ProximityAlertTriggered x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ProximityAlertTriggered x -> ProximityAlertTriggered
$cfrom :: forall x. ProximityAlertTriggered -> Rep ProximityAlertTriggered x
Generic, Int -> ProximityAlertTriggered -> ShowS
[ProximityAlertTriggered] -> ShowS
ProximityAlertTriggered -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ProximityAlertTriggered] -> ShowS
$cshowList :: [ProximityAlertTriggered] -> ShowS
show :: ProximityAlertTriggered -> String
$cshow :: ProximityAlertTriggered -> String
showsPrec :: Int -> ProximityAlertTriggered -> ShowS
$cshowsPrec :: Int -> ProximityAlertTriggered -> ShowS
Show)
instance ToJSON ProximityAlertTriggered where toJSON :: ProximityAlertTriggered -> Value
toJSON = forall a (d :: Meta) (f :: * -> *).
(Generic a, GToJSON Zero (Rep a), Rep a ~ D1 d f, Datatype d) =>
a -> Value
gtoJSON
instance FromJSON ProximityAlertTriggered where parseJSON :: Value -> Parser ProximityAlertTriggered
parseJSON = forall a (d :: Meta) (f :: * -> *).
(Generic a, GFromJSON Zero (Rep a), Rep a ~ D1 d f, Datatype d) =>
Value -> Parser a
gparseJSON