module TD.Query.ResetNetworkStatistics
  (ResetNetworkStatistics(..)
  ) where

import qualified Data.Aeson as A
import qualified Data.Aeson.Types as AT
import qualified TD.Lib.Internal as I

-- | Resets all network data usage statistics to zero. Can be called before authorization. Returns 'TD.Data.Ok.Ok'
data ResetNetworkStatistics
  = ResetNetworkStatistics
  deriving (ResetNetworkStatistics -> ResetNetworkStatistics -> Bool
(ResetNetworkStatistics -> ResetNetworkStatistics -> Bool)
-> (ResetNetworkStatistics -> ResetNetworkStatistics -> Bool)
-> Eq ResetNetworkStatistics
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ResetNetworkStatistics -> ResetNetworkStatistics -> Bool
== :: ResetNetworkStatistics -> ResetNetworkStatistics -> Bool
$c/= :: ResetNetworkStatistics -> ResetNetworkStatistics -> Bool
/= :: ResetNetworkStatistics -> ResetNetworkStatistics -> Bool
Eq, Int -> ResetNetworkStatistics -> ShowS
[ResetNetworkStatistics] -> ShowS
ResetNetworkStatistics -> String
(Int -> ResetNetworkStatistics -> ShowS)
-> (ResetNetworkStatistics -> String)
-> ([ResetNetworkStatistics] -> ShowS)
-> Show ResetNetworkStatistics
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ResetNetworkStatistics -> ShowS
showsPrec :: Int -> ResetNetworkStatistics -> ShowS
$cshow :: ResetNetworkStatistics -> String
show :: ResetNetworkStatistics -> String
$cshowList :: [ResetNetworkStatistics] -> ShowS
showList :: [ResetNetworkStatistics] -> ShowS
Show)

instance I.ShortShow ResetNetworkStatistics where
  shortShow :: ResetNetworkStatistics -> String
shortShow
    ResetNetworkStatistics
ResetNetworkStatistics
        = String
"ResetNetworkStatistics"

instance AT.ToJSON ResetNetworkStatistics where
  toJSON :: ResetNetworkStatistics -> Value
toJSON
    ResetNetworkStatistics
ResetNetworkStatistics
        = [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
"resetNetworkStatistics"
          ]