{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.IoTWireless.Types.WirelessDeviceStatistics
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.IoTWireless.Types.WirelessDeviceStatistics where

import qualified Amazonka.Core as Core
import Amazonka.IoTWireless.Types.LoRaWANListDevice
import Amazonka.IoTWireless.Types.SidewalkListDevice
import Amazonka.IoTWireless.Types.WirelessDeviceType
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Information about a wireless device\'s operation.
--
-- /See:/ 'newWirelessDeviceStatistics' smart constructor.
data WirelessDeviceStatistics = WirelessDeviceStatistics'
  { -- | The Sidewalk account credentials.
    WirelessDeviceStatistics -> Maybe SidewalkListDevice
sidewalk :: Prelude.Maybe SidewalkListDevice,
    -- | The Amazon Resource Name of the resource.
    WirelessDeviceStatistics -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
    -- | LoRaWAN device info.
    WirelessDeviceStatistics -> Maybe LoRaWANListDevice
loRaWAN :: Prelude.Maybe LoRaWANListDevice,
    -- | The name of the resource.
    WirelessDeviceStatistics -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The ID of the wireless device reporting the data.
    WirelessDeviceStatistics -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
    -- | The date and time when the most recent uplink was received.
    WirelessDeviceStatistics -> Maybe Text
lastUplinkReceivedAt :: Prelude.Maybe Prelude.Text,
    -- | The wireless device type.
    WirelessDeviceStatistics -> Maybe WirelessDeviceType
type' :: Prelude.Maybe WirelessDeviceType,
    -- | The name of the destination to which the device is assigned.
    WirelessDeviceStatistics -> Maybe Text
destinationName :: Prelude.Maybe Prelude.Text
  }
  deriving (WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool
(WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool)
-> (WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool)
-> Eq WirelessDeviceStatistics
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool
$c/= :: WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool
== :: WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool
$c== :: WirelessDeviceStatistics -> WirelessDeviceStatistics -> Bool
Prelude.Eq, ReadPrec [WirelessDeviceStatistics]
ReadPrec WirelessDeviceStatistics
Int -> ReadS WirelessDeviceStatistics
ReadS [WirelessDeviceStatistics]
(Int -> ReadS WirelessDeviceStatistics)
-> ReadS [WirelessDeviceStatistics]
-> ReadPrec WirelessDeviceStatistics
-> ReadPrec [WirelessDeviceStatistics]
-> Read WirelessDeviceStatistics
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [WirelessDeviceStatistics]
$creadListPrec :: ReadPrec [WirelessDeviceStatistics]
readPrec :: ReadPrec WirelessDeviceStatistics
$creadPrec :: ReadPrec WirelessDeviceStatistics
readList :: ReadS [WirelessDeviceStatistics]
$creadList :: ReadS [WirelessDeviceStatistics]
readsPrec :: Int -> ReadS WirelessDeviceStatistics
$creadsPrec :: Int -> ReadS WirelessDeviceStatistics
Prelude.Read, Int -> WirelessDeviceStatistics -> ShowS
[WirelessDeviceStatistics] -> ShowS
WirelessDeviceStatistics -> String
(Int -> WirelessDeviceStatistics -> ShowS)
-> (WirelessDeviceStatistics -> String)
-> ([WirelessDeviceStatistics] -> ShowS)
-> Show WirelessDeviceStatistics
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [WirelessDeviceStatistics] -> ShowS
$cshowList :: [WirelessDeviceStatistics] -> ShowS
show :: WirelessDeviceStatistics -> String
$cshow :: WirelessDeviceStatistics -> String
showsPrec :: Int -> WirelessDeviceStatistics -> ShowS
$cshowsPrec :: Int -> WirelessDeviceStatistics -> ShowS
Prelude.Show, (forall x.
 WirelessDeviceStatistics -> Rep WirelessDeviceStatistics x)
-> (forall x.
    Rep WirelessDeviceStatistics x -> WirelessDeviceStatistics)
-> Generic WirelessDeviceStatistics
forall x.
Rep WirelessDeviceStatistics x -> WirelessDeviceStatistics
forall x.
WirelessDeviceStatistics -> Rep WirelessDeviceStatistics x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep WirelessDeviceStatistics x -> WirelessDeviceStatistics
$cfrom :: forall x.
WirelessDeviceStatistics -> Rep WirelessDeviceStatistics x
Prelude.Generic)

-- |
-- Create a value of 'WirelessDeviceStatistics' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'sidewalk', 'wirelessDeviceStatistics_sidewalk' - The Sidewalk account credentials.
--
-- 'arn', 'wirelessDeviceStatistics_arn' - The Amazon Resource Name of the resource.
--
-- 'loRaWAN', 'wirelessDeviceStatistics_loRaWAN' - LoRaWAN device info.
--
-- 'name', 'wirelessDeviceStatistics_name' - The name of the resource.
--
-- 'id', 'wirelessDeviceStatistics_id' - The ID of the wireless device reporting the data.
--
-- 'lastUplinkReceivedAt', 'wirelessDeviceStatistics_lastUplinkReceivedAt' - The date and time when the most recent uplink was received.
--
-- 'type'', 'wirelessDeviceStatistics_type' - The wireless device type.
--
-- 'destinationName', 'wirelessDeviceStatistics_destinationName' - The name of the destination to which the device is assigned.
newWirelessDeviceStatistics ::
  WirelessDeviceStatistics
newWirelessDeviceStatistics :: WirelessDeviceStatistics
newWirelessDeviceStatistics =
  WirelessDeviceStatistics' :: Maybe SidewalkListDevice
-> Maybe Text
-> Maybe LoRaWANListDevice
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe WirelessDeviceType
-> Maybe Text
-> WirelessDeviceStatistics
WirelessDeviceStatistics'
    { $sel:sidewalk:WirelessDeviceStatistics' :: Maybe SidewalkListDevice
sidewalk =
        Maybe SidewalkListDevice
forall a. Maybe a
Prelude.Nothing,
      $sel:arn:WirelessDeviceStatistics' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:loRaWAN:WirelessDeviceStatistics' :: Maybe LoRaWANListDevice
loRaWAN = Maybe LoRaWANListDevice
forall a. Maybe a
Prelude.Nothing,
      $sel:name:WirelessDeviceStatistics' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:id:WirelessDeviceStatistics' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:lastUplinkReceivedAt:WirelessDeviceStatistics' :: Maybe Text
lastUplinkReceivedAt = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:type':WirelessDeviceStatistics' :: Maybe WirelessDeviceType
type' = Maybe WirelessDeviceType
forall a. Maybe a
Prelude.Nothing,
      $sel:destinationName:WirelessDeviceStatistics' :: Maybe Text
destinationName = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | The Sidewalk account credentials.
wirelessDeviceStatistics_sidewalk :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe SidewalkListDevice)
wirelessDeviceStatistics_sidewalk :: (Maybe SidewalkListDevice -> f (Maybe SidewalkListDevice))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_sidewalk = (WirelessDeviceStatistics -> Maybe SidewalkListDevice)
-> (WirelessDeviceStatistics
    -> Maybe SidewalkListDevice -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe SidewalkListDevice)
     (Maybe SidewalkListDevice)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe SidewalkListDevice
sidewalk :: Maybe SidewalkListDevice
$sel:sidewalk:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe SidewalkListDevice
sidewalk} -> Maybe SidewalkListDevice
sidewalk) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe SidewalkListDevice
a -> WirelessDeviceStatistics
s {$sel:sidewalk:WirelessDeviceStatistics' :: Maybe SidewalkListDevice
sidewalk = Maybe SidewalkListDevice
a} :: WirelessDeviceStatistics)

-- | The Amazon Resource Name of the resource.
wirelessDeviceStatistics_arn :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe Prelude.Text)
wirelessDeviceStatistics_arn :: (Maybe Text -> f (Maybe Text))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_arn = (WirelessDeviceStatistics -> Maybe Text)
-> (WirelessDeviceStatistics
    -> Maybe Text -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe Text
arn :: Maybe Text
$sel:arn:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe Text
arn} -> Maybe Text
arn) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe Text
a -> WirelessDeviceStatistics
s {$sel:arn:WirelessDeviceStatistics' :: Maybe Text
arn = Maybe Text
a} :: WirelessDeviceStatistics)

-- | LoRaWAN device info.
wirelessDeviceStatistics_loRaWAN :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe LoRaWANListDevice)
wirelessDeviceStatistics_loRaWAN :: (Maybe LoRaWANListDevice -> f (Maybe LoRaWANListDevice))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_loRaWAN = (WirelessDeviceStatistics -> Maybe LoRaWANListDevice)
-> (WirelessDeviceStatistics
    -> Maybe LoRaWANListDevice -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe LoRaWANListDevice)
     (Maybe LoRaWANListDevice)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe LoRaWANListDevice
loRaWAN :: Maybe LoRaWANListDevice
$sel:loRaWAN:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe LoRaWANListDevice
loRaWAN} -> Maybe LoRaWANListDevice
loRaWAN) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe LoRaWANListDevice
a -> WirelessDeviceStatistics
s {$sel:loRaWAN:WirelessDeviceStatistics' :: Maybe LoRaWANListDevice
loRaWAN = Maybe LoRaWANListDevice
a} :: WirelessDeviceStatistics)

-- | The name of the resource.
wirelessDeviceStatistics_name :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe Prelude.Text)
wirelessDeviceStatistics_name :: (Maybe Text -> f (Maybe Text))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_name = (WirelessDeviceStatistics -> Maybe Text)
-> (WirelessDeviceStatistics
    -> Maybe Text -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe Text
name :: Maybe Text
$sel:name:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe Text
name} -> Maybe Text
name) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe Text
a -> WirelessDeviceStatistics
s {$sel:name:WirelessDeviceStatistics' :: Maybe Text
name = Maybe Text
a} :: WirelessDeviceStatistics)

-- | The ID of the wireless device reporting the data.
wirelessDeviceStatistics_id :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe Prelude.Text)
wirelessDeviceStatistics_id :: (Maybe Text -> f (Maybe Text))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_id = (WirelessDeviceStatistics -> Maybe Text)
-> (WirelessDeviceStatistics
    -> Maybe Text -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe Text
id :: Maybe Text
$sel:id:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe Text
id} -> Maybe Text
id) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe Text
a -> WirelessDeviceStatistics
s {$sel:id:WirelessDeviceStatistics' :: Maybe Text
id = Maybe Text
a} :: WirelessDeviceStatistics)

-- | The date and time when the most recent uplink was received.
wirelessDeviceStatistics_lastUplinkReceivedAt :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe Prelude.Text)
wirelessDeviceStatistics_lastUplinkReceivedAt :: (Maybe Text -> f (Maybe Text))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_lastUplinkReceivedAt = (WirelessDeviceStatistics -> Maybe Text)
-> (WirelessDeviceStatistics
    -> Maybe Text -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe Text
lastUplinkReceivedAt :: Maybe Text
$sel:lastUplinkReceivedAt:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe Text
lastUplinkReceivedAt} -> Maybe Text
lastUplinkReceivedAt) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe Text
a -> WirelessDeviceStatistics
s {$sel:lastUplinkReceivedAt:WirelessDeviceStatistics' :: Maybe Text
lastUplinkReceivedAt = Maybe Text
a} :: WirelessDeviceStatistics)

-- | The wireless device type.
wirelessDeviceStatistics_type :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe WirelessDeviceType)
wirelessDeviceStatistics_type :: (Maybe WirelessDeviceType -> f (Maybe WirelessDeviceType))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_type = (WirelessDeviceStatistics -> Maybe WirelessDeviceType)
-> (WirelessDeviceStatistics
    -> Maybe WirelessDeviceType -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe WirelessDeviceType)
     (Maybe WirelessDeviceType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe WirelessDeviceType
type' :: Maybe WirelessDeviceType
$sel:type':WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe WirelessDeviceType
type'} -> Maybe WirelessDeviceType
type') (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe WirelessDeviceType
a -> WirelessDeviceStatistics
s {$sel:type':WirelessDeviceStatistics' :: Maybe WirelessDeviceType
type' = Maybe WirelessDeviceType
a} :: WirelessDeviceStatistics)

-- | The name of the destination to which the device is assigned.
wirelessDeviceStatistics_destinationName :: Lens.Lens' WirelessDeviceStatistics (Prelude.Maybe Prelude.Text)
wirelessDeviceStatistics_destinationName :: (Maybe Text -> f (Maybe Text))
-> WirelessDeviceStatistics -> f WirelessDeviceStatistics
wirelessDeviceStatistics_destinationName = (WirelessDeviceStatistics -> Maybe Text)
-> (WirelessDeviceStatistics
    -> Maybe Text -> WirelessDeviceStatistics)
-> Lens
     WirelessDeviceStatistics
     WirelessDeviceStatistics
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WirelessDeviceStatistics' {Maybe Text
destinationName :: Maybe Text
$sel:destinationName:WirelessDeviceStatistics' :: WirelessDeviceStatistics -> Maybe Text
destinationName} -> Maybe Text
destinationName) (\s :: WirelessDeviceStatistics
s@WirelessDeviceStatistics' {} Maybe Text
a -> WirelessDeviceStatistics
s {$sel:destinationName:WirelessDeviceStatistics' :: Maybe Text
destinationName = Maybe Text
a} :: WirelessDeviceStatistics)

instance Core.FromJSON WirelessDeviceStatistics where
  parseJSON :: Value -> Parser WirelessDeviceStatistics
parseJSON =
    String
-> (Object -> Parser WirelessDeviceStatistics)
-> Value
-> Parser WirelessDeviceStatistics
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"WirelessDeviceStatistics"
      ( \Object
x ->
          Maybe SidewalkListDevice
-> Maybe Text
-> Maybe LoRaWANListDevice
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe WirelessDeviceType
-> Maybe Text
-> WirelessDeviceStatistics
WirelessDeviceStatistics'
            (Maybe SidewalkListDevice
 -> Maybe Text
 -> Maybe LoRaWANListDevice
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe WirelessDeviceType
 -> Maybe Text
 -> WirelessDeviceStatistics)
-> Parser (Maybe SidewalkListDevice)
-> Parser
     (Maybe Text
      -> Maybe LoRaWANListDevice
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe WirelessDeviceType
      -> Maybe Text
      -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe SidewalkListDevice)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Sidewalk")
            Parser
  (Maybe Text
   -> Maybe LoRaWANListDevice
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe WirelessDeviceType
   -> Maybe Text
   -> WirelessDeviceStatistics)
-> Parser (Maybe Text)
-> Parser
     (Maybe LoRaWANListDevice
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe WirelessDeviceType
      -> Maybe Text
      -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Arn")
            Parser
  (Maybe LoRaWANListDevice
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe WirelessDeviceType
   -> Maybe Text
   -> WirelessDeviceStatistics)
-> Parser (Maybe LoRaWANListDevice)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe WirelessDeviceType
      -> Maybe Text
      -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe LoRaWANListDevice)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LoRaWAN")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe WirelessDeviceType
   -> Maybe Text
   -> WirelessDeviceStatistics)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe WirelessDeviceType
      -> Maybe Text
      -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Name")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe WirelessDeviceType
   -> Maybe Text
   -> WirelessDeviceStatistics)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe WirelessDeviceType
      -> Maybe Text
      -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Id")
            Parser
  (Maybe Text
   -> Maybe WirelessDeviceType
   -> Maybe Text
   -> WirelessDeviceStatistics)
-> Parser (Maybe Text)
-> Parser
     (Maybe WirelessDeviceType
      -> Maybe Text -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LastUplinkReceivedAt")
            Parser
  (Maybe WirelessDeviceType
   -> Maybe Text -> WirelessDeviceStatistics)
-> Parser (Maybe WirelessDeviceType)
-> Parser (Maybe Text -> WirelessDeviceStatistics)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe WirelessDeviceType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Type")
            Parser (Maybe Text -> WirelessDeviceStatistics)
-> Parser (Maybe Text) -> Parser WirelessDeviceStatistics
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DestinationName")
      )

instance Prelude.Hashable WirelessDeviceStatistics

instance Prelude.NFData WirelessDeviceStatistics