{-# 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.MediaLive.Types.InputDeviceSummary
-- 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.MediaLive.Types.InputDeviceSummary where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MediaLive.Types.DeviceSettingsSyncState
import Amazonka.MediaLive.Types.DeviceUpdateStatus
import Amazonka.MediaLive.Types.InputDeviceConnectionState
import Amazonka.MediaLive.Types.InputDeviceHdSettings
import Amazonka.MediaLive.Types.InputDeviceNetworkSettings
import Amazonka.MediaLive.Types.InputDeviceType
import Amazonka.MediaLive.Types.InputDeviceUhdSettings
import qualified Amazonka.Prelude as Prelude

-- | Details of the input device.
--
-- /See:/ 'newInputDeviceSummary' smart constructor.
data InputDeviceSummary = InputDeviceSummary'
  { -- | The unique ARN of the input device.
    InputDeviceSummary -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
    -- | The network MAC address of the input device.
    InputDeviceSummary -> Maybe Text
macAddress :: Prelude.Maybe Prelude.Text,
    -- | Settings that describe an input device that is type HD.
    InputDeviceSummary -> Maybe InputDeviceHdSettings
hdDeviceSettings :: Prelude.Maybe InputDeviceHdSettings,
    -- | Settings that describe an input device that is type UHD.
    InputDeviceSummary -> Maybe InputDeviceUhdSettings
uhdDeviceSettings :: Prelude.Maybe InputDeviceUhdSettings,
    -- | A name that you specify for the input device.
    InputDeviceSummary -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The unique ID of the input device.
    InputDeviceSummary -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
    -- | The status of software on the input device.
    InputDeviceSummary -> Maybe DeviceUpdateStatus
deviceUpdateStatus :: Prelude.Maybe DeviceUpdateStatus,
    -- | The status of the action to synchronize the device configuration. If you
    -- change the configuration of the input device (for example, the maximum
    -- bitrate), MediaLive sends the new data to the device. The device might
    -- not update itself immediately. SYNCED means the device has updated its
    -- configuration. SYNCING means that it has not updated its configuration.
    InputDeviceSummary -> Maybe DeviceSettingsSyncState
deviceSettingsSyncState :: Prelude.Maybe DeviceSettingsSyncState,
    -- | The type of the input device.
    InputDeviceSummary -> Maybe InputDeviceType
type' :: Prelude.Maybe InputDeviceType,
    -- | The unique serial number of the input device.
    InputDeviceSummary -> Maybe Text
serialNumber :: Prelude.Maybe Prelude.Text,
    -- | Network settings for the input device.
    InputDeviceSummary -> Maybe InputDeviceNetworkSettings
networkSettings :: Prelude.Maybe InputDeviceNetworkSettings,
    -- | The state of the connection between the input device and AWS.
    InputDeviceSummary -> Maybe InputDeviceConnectionState
connectionState :: Prelude.Maybe InputDeviceConnectionState
  }
  deriving (InputDeviceSummary -> InputDeviceSummary -> Bool
(InputDeviceSummary -> InputDeviceSummary -> Bool)
-> (InputDeviceSummary -> InputDeviceSummary -> Bool)
-> Eq InputDeviceSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InputDeviceSummary -> InputDeviceSummary -> Bool
$c/= :: InputDeviceSummary -> InputDeviceSummary -> Bool
== :: InputDeviceSummary -> InputDeviceSummary -> Bool
$c== :: InputDeviceSummary -> InputDeviceSummary -> Bool
Prelude.Eq, ReadPrec [InputDeviceSummary]
ReadPrec InputDeviceSummary
Int -> ReadS InputDeviceSummary
ReadS [InputDeviceSummary]
(Int -> ReadS InputDeviceSummary)
-> ReadS [InputDeviceSummary]
-> ReadPrec InputDeviceSummary
-> ReadPrec [InputDeviceSummary]
-> Read InputDeviceSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [InputDeviceSummary]
$creadListPrec :: ReadPrec [InputDeviceSummary]
readPrec :: ReadPrec InputDeviceSummary
$creadPrec :: ReadPrec InputDeviceSummary
readList :: ReadS [InputDeviceSummary]
$creadList :: ReadS [InputDeviceSummary]
readsPrec :: Int -> ReadS InputDeviceSummary
$creadsPrec :: Int -> ReadS InputDeviceSummary
Prelude.Read, Int -> InputDeviceSummary -> ShowS
[InputDeviceSummary] -> ShowS
InputDeviceSummary -> String
(Int -> InputDeviceSummary -> ShowS)
-> (InputDeviceSummary -> String)
-> ([InputDeviceSummary] -> ShowS)
-> Show InputDeviceSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InputDeviceSummary] -> ShowS
$cshowList :: [InputDeviceSummary] -> ShowS
show :: InputDeviceSummary -> String
$cshow :: InputDeviceSummary -> String
showsPrec :: Int -> InputDeviceSummary -> ShowS
$cshowsPrec :: Int -> InputDeviceSummary -> ShowS
Prelude.Show, (forall x. InputDeviceSummary -> Rep InputDeviceSummary x)
-> (forall x. Rep InputDeviceSummary x -> InputDeviceSummary)
-> Generic InputDeviceSummary
forall x. Rep InputDeviceSummary x -> InputDeviceSummary
forall x. InputDeviceSummary -> Rep InputDeviceSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep InputDeviceSummary x -> InputDeviceSummary
$cfrom :: forall x. InputDeviceSummary -> Rep InputDeviceSummary x
Prelude.Generic)

-- |
-- Create a value of 'InputDeviceSummary' 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:
--
-- 'arn', 'inputDeviceSummary_arn' - The unique ARN of the input device.
--
-- 'macAddress', 'inputDeviceSummary_macAddress' - The network MAC address of the input device.
--
-- 'hdDeviceSettings', 'inputDeviceSummary_hdDeviceSettings' - Settings that describe an input device that is type HD.
--
-- 'uhdDeviceSettings', 'inputDeviceSummary_uhdDeviceSettings' - Settings that describe an input device that is type UHD.
--
-- 'name', 'inputDeviceSummary_name' - A name that you specify for the input device.
--
-- 'id', 'inputDeviceSummary_id' - The unique ID of the input device.
--
-- 'deviceUpdateStatus', 'inputDeviceSummary_deviceUpdateStatus' - The status of software on the input device.
--
-- 'deviceSettingsSyncState', 'inputDeviceSummary_deviceSettingsSyncState' - The status of the action to synchronize the device configuration. If you
-- change the configuration of the input device (for example, the maximum
-- bitrate), MediaLive sends the new data to the device. The device might
-- not update itself immediately. SYNCED means the device has updated its
-- configuration. SYNCING means that it has not updated its configuration.
--
-- 'type'', 'inputDeviceSummary_type' - The type of the input device.
--
-- 'serialNumber', 'inputDeviceSummary_serialNumber' - The unique serial number of the input device.
--
-- 'networkSettings', 'inputDeviceSummary_networkSettings' - Network settings for the input device.
--
-- 'connectionState', 'inputDeviceSummary_connectionState' - The state of the connection between the input device and AWS.
newInputDeviceSummary ::
  InputDeviceSummary
newInputDeviceSummary :: InputDeviceSummary
newInputDeviceSummary =
  InputDeviceSummary' :: Maybe Text
-> Maybe Text
-> Maybe InputDeviceHdSettings
-> Maybe InputDeviceUhdSettings
-> Maybe Text
-> Maybe Text
-> Maybe DeviceUpdateStatus
-> Maybe DeviceSettingsSyncState
-> Maybe InputDeviceType
-> Maybe Text
-> Maybe InputDeviceNetworkSettings
-> Maybe InputDeviceConnectionState
-> InputDeviceSummary
InputDeviceSummary'
    { $sel:arn:InputDeviceSummary' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:macAddress:InputDeviceSummary' :: Maybe Text
macAddress = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:hdDeviceSettings:InputDeviceSummary' :: Maybe InputDeviceHdSettings
hdDeviceSettings = Maybe InputDeviceHdSettings
forall a. Maybe a
Prelude.Nothing,
      $sel:uhdDeviceSettings:InputDeviceSummary' :: Maybe InputDeviceUhdSettings
uhdDeviceSettings = Maybe InputDeviceUhdSettings
forall a. Maybe a
Prelude.Nothing,
      $sel:name:InputDeviceSummary' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:id:InputDeviceSummary' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:deviceUpdateStatus:InputDeviceSummary' :: Maybe DeviceUpdateStatus
deviceUpdateStatus = Maybe DeviceUpdateStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:deviceSettingsSyncState:InputDeviceSummary' :: Maybe DeviceSettingsSyncState
deviceSettingsSyncState = Maybe DeviceSettingsSyncState
forall a. Maybe a
Prelude.Nothing,
      $sel:type':InputDeviceSummary' :: Maybe InputDeviceType
type' = Maybe InputDeviceType
forall a. Maybe a
Prelude.Nothing,
      $sel:serialNumber:InputDeviceSummary' :: Maybe Text
serialNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:networkSettings:InputDeviceSummary' :: Maybe InputDeviceNetworkSettings
networkSettings = Maybe InputDeviceNetworkSettings
forall a. Maybe a
Prelude.Nothing,
      $sel:connectionState:InputDeviceSummary' :: Maybe InputDeviceConnectionState
connectionState = Maybe InputDeviceConnectionState
forall a. Maybe a
Prelude.Nothing
    }

-- | The unique ARN of the input device.
inputDeviceSummary_arn :: Lens.Lens' InputDeviceSummary (Prelude.Maybe Prelude.Text)
inputDeviceSummary_arn :: (Maybe Text -> f (Maybe Text))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_arn = (InputDeviceSummary -> Maybe Text)
-> (InputDeviceSummary -> Maybe Text -> InputDeviceSummary)
-> Lens
     InputDeviceSummary InputDeviceSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe Text
arn :: Maybe Text
$sel:arn:InputDeviceSummary' :: InputDeviceSummary -> Maybe Text
arn} -> Maybe Text
arn) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe Text
a -> InputDeviceSummary
s {$sel:arn:InputDeviceSummary' :: Maybe Text
arn = Maybe Text
a} :: InputDeviceSummary)

-- | The network MAC address of the input device.
inputDeviceSummary_macAddress :: Lens.Lens' InputDeviceSummary (Prelude.Maybe Prelude.Text)
inputDeviceSummary_macAddress :: (Maybe Text -> f (Maybe Text))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_macAddress = (InputDeviceSummary -> Maybe Text)
-> (InputDeviceSummary -> Maybe Text -> InputDeviceSummary)
-> Lens
     InputDeviceSummary InputDeviceSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe Text
macAddress :: Maybe Text
$sel:macAddress:InputDeviceSummary' :: InputDeviceSummary -> Maybe Text
macAddress} -> Maybe Text
macAddress) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe Text
a -> InputDeviceSummary
s {$sel:macAddress:InputDeviceSummary' :: Maybe Text
macAddress = Maybe Text
a} :: InputDeviceSummary)

-- | Settings that describe an input device that is type HD.
inputDeviceSummary_hdDeviceSettings :: Lens.Lens' InputDeviceSummary (Prelude.Maybe InputDeviceHdSettings)
inputDeviceSummary_hdDeviceSettings :: (Maybe InputDeviceHdSettings -> f (Maybe InputDeviceHdSettings))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_hdDeviceSettings = (InputDeviceSummary -> Maybe InputDeviceHdSettings)
-> (InputDeviceSummary
    -> Maybe InputDeviceHdSettings -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe InputDeviceHdSettings)
     (Maybe InputDeviceHdSettings)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe InputDeviceHdSettings
hdDeviceSettings :: Maybe InputDeviceHdSettings
$sel:hdDeviceSettings:InputDeviceSummary' :: InputDeviceSummary -> Maybe InputDeviceHdSettings
hdDeviceSettings} -> Maybe InputDeviceHdSettings
hdDeviceSettings) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe InputDeviceHdSettings
a -> InputDeviceSummary
s {$sel:hdDeviceSettings:InputDeviceSummary' :: Maybe InputDeviceHdSettings
hdDeviceSettings = Maybe InputDeviceHdSettings
a} :: InputDeviceSummary)

-- | Settings that describe an input device that is type UHD.
inputDeviceSummary_uhdDeviceSettings :: Lens.Lens' InputDeviceSummary (Prelude.Maybe InputDeviceUhdSettings)
inputDeviceSummary_uhdDeviceSettings :: (Maybe InputDeviceUhdSettings -> f (Maybe InputDeviceUhdSettings))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_uhdDeviceSettings = (InputDeviceSummary -> Maybe InputDeviceUhdSettings)
-> (InputDeviceSummary
    -> Maybe InputDeviceUhdSettings -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe InputDeviceUhdSettings)
     (Maybe InputDeviceUhdSettings)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe InputDeviceUhdSettings
uhdDeviceSettings :: Maybe InputDeviceUhdSettings
$sel:uhdDeviceSettings:InputDeviceSummary' :: InputDeviceSummary -> Maybe InputDeviceUhdSettings
uhdDeviceSettings} -> Maybe InputDeviceUhdSettings
uhdDeviceSettings) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe InputDeviceUhdSettings
a -> InputDeviceSummary
s {$sel:uhdDeviceSettings:InputDeviceSummary' :: Maybe InputDeviceUhdSettings
uhdDeviceSettings = Maybe InputDeviceUhdSettings
a} :: InputDeviceSummary)

-- | A name that you specify for the input device.
inputDeviceSummary_name :: Lens.Lens' InputDeviceSummary (Prelude.Maybe Prelude.Text)
inputDeviceSummary_name :: (Maybe Text -> f (Maybe Text))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_name = (InputDeviceSummary -> Maybe Text)
-> (InputDeviceSummary -> Maybe Text -> InputDeviceSummary)
-> Lens
     InputDeviceSummary InputDeviceSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe Text
name :: Maybe Text
$sel:name:InputDeviceSummary' :: InputDeviceSummary -> Maybe Text
name} -> Maybe Text
name) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe Text
a -> InputDeviceSummary
s {$sel:name:InputDeviceSummary' :: Maybe Text
name = Maybe Text
a} :: InputDeviceSummary)

-- | The unique ID of the input device.
inputDeviceSummary_id :: Lens.Lens' InputDeviceSummary (Prelude.Maybe Prelude.Text)
inputDeviceSummary_id :: (Maybe Text -> f (Maybe Text))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_id = (InputDeviceSummary -> Maybe Text)
-> (InputDeviceSummary -> Maybe Text -> InputDeviceSummary)
-> Lens
     InputDeviceSummary InputDeviceSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe Text
id :: Maybe Text
$sel:id:InputDeviceSummary' :: InputDeviceSummary -> Maybe Text
id} -> Maybe Text
id) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe Text
a -> InputDeviceSummary
s {$sel:id:InputDeviceSummary' :: Maybe Text
id = Maybe Text
a} :: InputDeviceSummary)

-- | The status of software on the input device.
inputDeviceSummary_deviceUpdateStatus :: Lens.Lens' InputDeviceSummary (Prelude.Maybe DeviceUpdateStatus)
inputDeviceSummary_deviceUpdateStatus :: (Maybe DeviceUpdateStatus -> f (Maybe DeviceUpdateStatus))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_deviceUpdateStatus = (InputDeviceSummary -> Maybe DeviceUpdateStatus)
-> (InputDeviceSummary
    -> Maybe DeviceUpdateStatus -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe DeviceUpdateStatus)
     (Maybe DeviceUpdateStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe DeviceUpdateStatus
deviceUpdateStatus :: Maybe DeviceUpdateStatus
$sel:deviceUpdateStatus:InputDeviceSummary' :: InputDeviceSummary -> Maybe DeviceUpdateStatus
deviceUpdateStatus} -> Maybe DeviceUpdateStatus
deviceUpdateStatus) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe DeviceUpdateStatus
a -> InputDeviceSummary
s {$sel:deviceUpdateStatus:InputDeviceSummary' :: Maybe DeviceUpdateStatus
deviceUpdateStatus = Maybe DeviceUpdateStatus
a} :: InputDeviceSummary)

-- | The status of the action to synchronize the device configuration. If you
-- change the configuration of the input device (for example, the maximum
-- bitrate), MediaLive sends the new data to the device. The device might
-- not update itself immediately. SYNCED means the device has updated its
-- configuration. SYNCING means that it has not updated its configuration.
inputDeviceSummary_deviceSettingsSyncState :: Lens.Lens' InputDeviceSummary (Prelude.Maybe DeviceSettingsSyncState)
inputDeviceSummary_deviceSettingsSyncState :: (Maybe DeviceSettingsSyncState
 -> f (Maybe DeviceSettingsSyncState))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_deviceSettingsSyncState = (InputDeviceSummary -> Maybe DeviceSettingsSyncState)
-> (InputDeviceSummary
    -> Maybe DeviceSettingsSyncState -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe DeviceSettingsSyncState)
     (Maybe DeviceSettingsSyncState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe DeviceSettingsSyncState
deviceSettingsSyncState :: Maybe DeviceSettingsSyncState
$sel:deviceSettingsSyncState:InputDeviceSummary' :: InputDeviceSummary -> Maybe DeviceSettingsSyncState
deviceSettingsSyncState} -> Maybe DeviceSettingsSyncState
deviceSettingsSyncState) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe DeviceSettingsSyncState
a -> InputDeviceSummary
s {$sel:deviceSettingsSyncState:InputDeviceSummary' :: Maybe DeviceSettingsSyncState
deviceSettingsSyncState = Maybe DeviceSettingsSyncState
a} :: InputDeviceSummary)

-- | The type of the input device.
inputDeviceSummary_type :: Lens.Lens' InputDeviceSummary (Prelude.Maybe InputDeviceType)
inputDeviceSummary_type :: (Maybe InputDeviceType -> f (Maybe InputDeviceType))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_type = (InputDeviceSummary -> Maybe InputDeviceType)
-> (InputDeviceSummary
    -> Maybe InputDeviceType -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe InputDeviceType)
     (Maybe InputDeviceType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe InputDeviceType
type' :: Maybe InputDeviceType
$sel:type':InputDeviceSummary' :: InputDeviceSummary -> Maybe InputDeviceType
type'} -> Maybe InputDeviceType
type') (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe InputDeviceType
a -> InputDeviceSummary
s {$sel:type':InputDeviceSummary' :: Maybe InputDeviceType
type' = Maybe InputDeviceType
a} :: InputDeviceSummary)

-- | The unique serial number of the input device.
inputDeviceSummary_serialNumber :: Lens.Lens' InputDeviceSummary (Prelude.Maybe Prelude.Text)
inputDeviceSummary_serialNumber :: (Maybe Text -> f (Maybe Text))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_serialNumber = (InputDeviceSummary -> Maybe Text)
-> (InputDeviceSummary -> Maybe Text -> InputDeviceSummary)
-> Lens
     InputDeviceSummary InputDeviceSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe Text
serialNumber :: Maybe Text
$sel:serialNumber:InputDeviceSummary' :: InputDeviceSummary -> Maybe Text
serialNumber} -> Maybe Text
serialNumber) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe Text
a -> InputDeviceSummary
s {$sel:serialNumber:InputDeviceSummary' :: Maybe Text
serialNumber = Maybe Text
a} :: InputDeviceSummary)

-- | Network settings for the input device.
inputDeviceSummary_networkSettings :: Lens.Lens' InputDeviceSummary (Prelude.Maybe InputDeviceNetworkSettings)
inputDeviceSummary_networkSettings :: (Maybe InputDeviceNetworkSettings
 -> f (Maybe InputDeviceNetworkSettings))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_networkSettings = (InputDeviceSummary -> Maybe InputDeviceNetworkSettings)
-> (InputDeviceSummary
    -> Maybe InputDeviceNetworkSettings -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe InputDeviceNetworkSettings)
     (Maybe InputDeviceNetworkSettings)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe InputDeviceNetworkSettings
networkSettings :: Maybe InputDeviceNetworkSettings
$sel:networkSettings:InputDeviceSummary' :: InputDeviceSummary -> Maybe InputDeviceNetworkSettings
networkSettings} -> Maybe InputDeviceNetworkSettings
networkSettings) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe InputDeviceNetworkSettings
a -> InputDeviceSummary
s {$sel:networkSettings:InputDeviceSummary' :: Maybe InputDeviceNetworkSettings
networkSettings = Maybe InputDeviceNetworkSettings
a} :: InputDeviceSummary)

-- | The state of the connection between the input device and AWS.
inputDeviceSummary_connectionState :: Lens.Lens' InputDeviceSummary (Prelude.Maybe InputDeviceConnectionState)
inputDeviceSummary_connectionState :: (Maybe InputDeviceConnectionState
 -> f (Maybe InputDeviceConnectionState))
-> InputDeviceSummary -> f InputDeviceSummary
inputDeviceSummary_connectionState = (InputDeviceSummary -> Maybe InputDeviceConnectionState)
-> (InputDeviceSummary
    -> Maybe InputDeviceConnectionState -> InputDeviceSummary)
-> Lens
     InputDeviceSummary
     InputDeviceSummary
     (Maybe InputDeviceConnectionState)
     (Maybe InputDeviceConnectionState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDeviceSummary' {Maybe InputDeviceConnectionState
connectionState :: Maybe InputDeviceConnectionState
$sel:connectionState:InputDeviceSummary' :: InputDeviceSummary -> Maybe InputDeviceConnectionState
connectionState} -> Maybe InputDeviceConnectionState
connectionState) (\s :: InputDeviceSummary
s@InputDeviceSummary' {} Maybe InputDeviceConnectionState
a -> InputDeviceSummary
s {$sel:connectionState:InputDeviceSummary' :: Maybe InputDeviceConnectionState
connectionState = Maybe InputDeviceConnectionState
a} :: InputDeviceSummary)

instance Core.FromJSON InputDeviceSummary where
  parseJSON :: Value -> Parser InputDeviceSummary
parseJSON =
    String
-> (Object -> Parser InputDeviceSummary)
-> Value
-> Parser InputDeviceSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"InputDeviceSummary"
      ( \Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe InputDeviceHdSettings
-> Maybe InputDeviceUhdSettings
-> Maybe Text
-> Maybe Text
-> Maybe DeviceUpdateStatus
-> Maybe DeviceSettingsSyncState
-> Maybe InputDeviceType
-> Maybe Text
-> Maybe InputDeviceNetworkSettings
-> Maybe InputDeviceConnectionState
-> InputDeviceSummary
InputDeviceSummary'
            (Maybe Text
 -> Maybe Text
 -> Maybe InputDeviceHdSettings
 -> Maybe InputDeviceUhdSettings
 -> Maybe Text
 -> Maybe Text
 -> Maybe DeviceUpdateStatus
 -> Maybe DeviceSettingsSyncState
 -> Maybe InputDeviceType
 -> Maybe Text
 -> Maybe InputDeviceNetworkSettings
 -> Maybe InputDeviceConnectionState
 -> InputDeviceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe InputDeviceHdSettings
      -> Maybe InputDeviceUhdSettings
      -> Maybe Text
      -> Maybe Text
      -> Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Functor 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 Text
   -> Maybe InputDeviceHdSettings
   -> Maybe InputDeviceUhdSettings
   -> Maybe Text
   -> Maybe Text
   -> Maybe DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe InputDeviceHdSettings
      -> Maybe InputDeviceUhdSettings
      -> Maybe Text
      -> Maybe Text
      -> Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
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
"macAddress")
            Parser
  (Maybe InputDeviceHdSettings
   -> Maybe InputDeviceUhdSettings
   -> Maybe Text
   -> Maybe Text
   -> Maybe DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe InputDeviceHdSettings)
-> Parser
     (Maybe InputDeviceUhdSettings
      -> Maybe Text
      -> Maybe Text
      -> Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InputDeviceHdSettings)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"hdDeviceSettings")
            Parser
  (Maybe InputDeviceUhdSettings
   -> Maybe Text
   -> Maybe Text
   -> Maybe DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe InputDeviceUhdSettings)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InputDeviceUhdSettings)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"uhdDeviceSettings")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
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 DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe DeviceUpdateStatus
      -> Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
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 DeviceUpdateStatus
   -> Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe DeviceUpdateStatus)
-> Parser
     (Maybe DeviceSettingsSyncState
      -> Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe DeviceUpdateStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"deviceUpdateStatus")
            Parser
  (Maybe DeviceSettingsSyncState
   -> Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe DeviceSettingsSyncState)
-> Parser
     (Maybe InputDeviceType
      -> Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe DeviceSettingsSyncState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"deviceSettingsSyncState")
            Parser
  (Maybe InputDeviceType
   -> Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe InputDeviceType)
-> Parser
     (Maybe Text
      -> Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState
      -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InputDeviceType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"type")
            Parser
  (Maybe Text
   -> Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState
   -> InputDeviceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe InputDeviceNetworkSettings
      -> Maybe InputDeviceConnectionState -> InputDeviceSummary)
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
"serialNumber")
            Parser
  (Maybe InputDeviceNetworkSettings
   -> Maybe InputDeviceConnectionState -> InputDeviceSummary)
-> Parser (Maybe InputDeviceNetworkSettings)
-> Parser (Maybe InputDeviceConnectionState -> InputDeviceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InputDeviceNetworkSettings)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"networkSettings")
            Parser (Maybe InputDeviceConnectionState -> InputDeviceSummary)
-> Parser (Maybe InputDeviceConnectionState)
-> Parser InputDeviceSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InputDeviceConnectionState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"connectionState")
      )

instance Prelude.Hashable InputDeviceSummary

instance Prelude.NFData InputDeviceSummary