{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.GreengrassV2.GetCoreDevice
(
GetCoreDevice (..),
newGetCoreDevice,
getCoreDevice_coreDeviceThingName,
GetCoreDeviceResponse (..),
newGetCoreDeviceResponse,
getCoreDeviceResponse_status,
getCoreDeviceResponse_platform,
getCoreDeviceResponse_architecture,
getCoreDeviceResponse_coreDeviceThingName,
getCoreDeviceResponse_tags,
getCoreDeviceResponse_coreVersion,
getCoreDeviceResponse_lastStatusUpdateTimestamp,
getCoreDeviceResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.GreengrassV2.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data GetCoreDevice = GetCoreDevice'
{
GetCoreDevice -> Text
coreDeviceThingName :: Prelude.Text
}
deriving (GetCoreDevice -> GetCoreDevice -> Bool
(GetCoreDevice -> GetCoreDevice -> Bool)
-> (GetCoreDevice -> GetCoreDevice -> Bool) -> Eq GetCoreDevice
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetCoreDevice -> GetCoreDevice -> Bool
$c/= :: GetCoreDevice -> GetCoreDevice -> Bool
== :: GetCoreDevice -> GetCoreDevice -> Bool
$c== :: GetCoreDevice -> GetCoreDevice -> Bool
Prelude.Eq, ReadPrec [GetCoreDevice]
ReadPrec GetCoreDevice
Int -> ReadS GetCoreDevice
ReadS [GetCoreDevice]
(Int -> ReadS GetCoreDevice)
-> ReadS [GetCoreDevice]
-> ReadPrec GetCoreDevice
-> ReadPrec [GetCoreDevice]
-> Read GetCoreDevice
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetCoreDevice]
$creadListPrec :: ReadPrec [GetCoreDevice]
readPrec :: ReadPrec GetCoreDevice
$creadPrec :: ReadPrec GetCoreDevice
readList :: ReadS [GetCoreDevice]
$creadList :: ReadS [GetCoreDevice]
readsPrec :: Int -> ReadS GetCoreDevice
$creadsPrec :: Int -> ReadS GetCoreDevice
Prelude.Read, Int -> GetCoreDevice -> ShowS
[GetCoreDevice] -> ShowS
GetCoreDevice -> String
(Int -> GetCoreDevice -> ShowS)
-> (GetCoreDevice -> String)
-> ([GetCoreDevice] -> ShowS)
-> Show GetCoreDevice
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetCoreDevice] -> ShowS
$cshowList :: [GetCoreDevice] -> ShowS
show :: GetCoreDevice -> String
$cshow :: GetCoreDevice -> String
showsPrec :: Int -> GetCoreDevice -> ShowS
$cshowsPrec :: Int -> GetCoreDevice -> ShowS
Prelude.Show, (forall x. GetCoreDevice -> Rep GetCoreDevice x)
-> (forall x. Rep GetCoreDevice x -> GetCoreDevice)
-> Generic GetCoreDevice
forall x. Rep GetCoreDevice x -> GetCoreDevice
forall x. GetCoreDevice -> Rep GetCoreDevice x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetCoreDevice x -> GetCoreDevice
$cfrom :: forall x. GetCoreDevice -> Rep GetCoreDevice x
Prelude.Generic)
newGetCoreDevice ::
Prelude.Text ->
GetCoreDevice
newGetCoreDevice :: Text -> GetCoreDevice
newGetCoreDevice Text
pCoreDeviceThingName_ =
GetCoreDevice' :: Text -> GetCoreDevice
GetCoreDevice'
{ $sel:coreDeviceThingName:GetCoreDevice' :: Text
coreDeviceThingName =
Text
pCoreDeviceThingName_
}
getCoreDevice_coreDeviceThingName :: Lens.Lens' GetCoreDevice Prelude.Text
getCoreDevice_coreDeviceThingName :: (Text -> f Text) -> GetCoreDevice -> f GetCoreDevice
getCoreDevice_coreDeviceThingName = (GetCoreDevice -> Text)
-> (GetCoreDevice -> Text -> GetCoreDevice)
-> Lens GetCoreDevice GetCoreDevice Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDevice' {Text
coreDeviceThingName :: Text
$sel:coreDeviceThingName:GetCoreDevice' :: GetCoreDevice -> Text
coreDeviceThingName} -> Text
coreDeviceThingName) (\s :: GetCoreDevice
s@GetCoreDevice' {} Text
a -> GetCoreDevice
s {$sel:coreDeviceThingName:GetCoreDevice' :: Text
coreDeviceThingName = Text
a} :: GetCoreDevice)
instance Core.AWSRequest GetCoreDevice where
type
AWSResponse GetCoreDevice =
GetCoreDeviceResponse
request :: GetCoreDevice -> Request GetCoreDevice
request = Service -> GetCoreDevice -> Request GetCoreDevice
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
response :: Logger
-> Service
-> Proxy GetCoreDevice
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetCoreDevice)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse GetCoreDevice))
-> Logger
-> Service
-> Proxy GetCoreDevice
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetCoreDevice)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe CoreDeviceStatus
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse
GetCoreDeviceResponse'
(Maybe CoreDeviceStatus
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
-> Either String (Maybe CoreDeviceStatus)
-> Either
String
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe CoreDeviceStatus)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"status")
Either
String
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"platform")
Either
String
(Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"architecture")
Either
String
(Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe (HashMap Text Text)
-> Maybe Text -> Maybe POSIX -> Int -> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"coreDeviceThingName")
Either
String
(Maybe (HashMap Text Text)
-> Maybe Text -> Maybe POSIX -> Int -> GetCoreDeviceResponse)
-> Either String (Maybe (HashMap Text Text))
-> Either
String (Maybe Text -> Maybe POSIX -> Int -> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"tags" Either String (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text)
-> Either String (Maybe (HashMap Text Text))
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
Either
String (Maybe Text -> Maybe POSIX -> Int -> GetCoreDeviceResponse)
-> Either String (Maybe Text)
-> Either String (Maybe POSIX -> Int -> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"coreVersion")
Either String (Maybe POSIX -> Int -> GetCoreDeviceResponse)
-> Either String (Maybe POSIX)
-> Either String (Int -> GetCoreDeviceResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"lastStatusUpdateTimestamp")
Either String (Int -> GetCoreDeviceResponse)
-> Either String Int -> Either String GetCoreDeviceResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable GetCoreDevice
instance Prelude.NFData GetCoreDevice
instance Core.ToHeaders GetCoreDevice where
toHeaders :: GetCoreDevice -> ResponseHeaders
toHeaders =
ResponseHeaders -> GetCoreDevice -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToPath GetCoreDevice where
toPath :: GetCoreDevice -> ByteString
toPath GetCoreDevice' {Text
coreDeviceThingName :: Text
$sel:coreDeviceThingName:GetCoreDevice' :: GetCoreDevice -> Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/greengrass/v2/coreDevices/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
coreDeviceThingName
]
instance Core.ToQuery GetCoreDevice where
toQuery :: GetCoreDevice -> QueryString
toQuery = QueryString -> GetCoreDevice -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data GetCoreDeviceResponse = GetCoreDeviceResponse'
{
GetCoreDeviceResponse -> Maybe CoreDeviceStatus
status :: Prelude.Maybe CoreDeviceStatus,
GetCoreDeviceResponse -> Maybe Text
platform :: Prelude.Maybe Prelude.Text,
GetCoreDeviceResponse -> Maybe Text
architecture :: Prelude.Maybe Prelude.Text,
GetCoreDeviceResponse -> Maybe Text
coreDeviceThingName :: Prelude.Maybe Prelude.Text,
GetCoreDeviceResponse -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
GetCoreDeviceResponse -> Maybe Text
coreVersion :: Prelude.Maybe Prelude.Text,
GetCoreDeviceResponse -> Maybe POSIX
lastStatusUpdateTimestamp :: Prelude.Maybe Core.POSIX,
GetCoreDeviceResponse -> Int
httpStatus :: Prelude.Int
}
deriving (GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool
(GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool)
-> (GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool)
-> Eq GetCoreDeviceResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool
$c/= :: GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool
== :: GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool
$c== :: GetCoreDeviceResponse -> GetCoreDeviceResponse -> Bool
Prelude.Eq, ReadPrec [GetCoreDeviceResponse]
ReadPrec GetCoreDeviceResponse
Int -> ReadS GetCoreDeviceResponse
ReadS [GetCoreDeviceResponse]
(Int -> ReadS GetCoreDeviceResponse)
-> ReadS [GetCoreDeviceResponse]
-> ReadPrec GetCoreDeviceResponse
-> ReadPrec [GetCoreDeviceResponse]
-> Read GetCoreDeviceResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetCoreDeviceResponse]
$creadListPrec :: ReadPrec [GetCoreDeviceResponse]
readPrec :: ReadPrec GetCoreDeviceResponse
$creadPrec :: ReadPrec GetCoreDeviceResponse
readList :: ReadS [GetCoreDeviceResponse]
$creadList :: ReadS [GetCoreDeviceResponse]
readsPrec :: Int -> ReadS GetCoreDeviceResponse
$creadsPrec :: Int -> ReadS GetCoreDeviceResponse
Prelude.Read, Int -> GetCoreDeviceResponse -> ShowS
[GetCoreDeviceResponse] -> ShowS
GetCoreDeviceResponse -> String
(Int -> GetCoreDeviceResponse -> ShowS)
-> (GetCoreDeviceResponse -> String)
-> ([GetCoreDeviceResponse] -> ShowS)
-> Show GetCoreDeviceResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetCoreDeviceResponse] -> ShowS
$cshowList :: [GetCoreDeviceResponse] -> ShowS
show :: GetCoreDeviceResponse -> String
$cshow :: GetCoreDeviceResponse -> String
showsPrec :: Int -> GetCoreDeviceResponse -> ShowS
$cshowsPrec :: Int -> GetCoreDeviceResponse -> ShowS
Prelude.Show, (forall x. GetCoreDeviceResponse -> Rep GetCoreDeviceResponse x)
-> (forall x. Rep GetCoreDeviceResponse x -> GetCoreDeviceResponse)
-> Generic GetCoreDeviceResponse
forall x. Rep GetCoreDeviceResponse x -> GetCoreDeviceResponse
forall x. GetCoreDeviceResponse -> Rep GetCoreDeviceResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetCoreDeviceResponse x -> GetCoreDeviceResponse
$cfrom :: forall x. GetCoreDeviceResponse -> Rep GetCoreDeviceResponse x
Prelude.Generic)
newGetCoreDeviceResponse ::
Prelude.Int ->
GetCoreDeviceResponse
newGetCoreDeviceResponse :: Int -> GetCoreDeviceResponse
newGetCoreDeviceResponse Int
pHttpStatus_ =
GetCoreDeviceResponse' :: Maybe CoreDeviceStatus
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe POSIX
-> Int
-> GetCoreDeviceResponse
GetCoreDeviceResponse'
{ $sel:status:GetCoreDeviceResponse' :: Maybe CoreDeviceStatus
status = Maybe CoreDeviceStatus
forall a. Maybe a
Prelude.Nothing,
$sel:platform:GetCoreDeviceResponse' :: Maybe Text
platform = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:architecture:GetCoreDeviceResponse' :: Maybe Text
architecture = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:coreDeviceThingName:GetCoreDeviceResponse' :: Maybe Text
coreDeviceThingName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:GetCoreDeviceResponse' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:coreVersion:GetCoreDeviceResponse' :: Maybe Text
coreVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lastStatusUpdateTimestamp:GetCoreDeviceResponse' :: Maybe POSIX
lastStatusUpdateTimestamp = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:GetCoreDeviceResponse' :: Int
httpStatus = Int
pHttpStatus_
}
getCoreDeviceResponse_status :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe CoreDeviceStatus)
getCoreDeviceResponse_status :: (Maybe CoreDeviceStatus -> f (Maybe CoreDeviceStatus))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_status = (GetCoreDeviceResponse -> Maybe CoreDeviceStatus)
-> (GetCoreDeviceResponse
-> Maybe CoreDeviceStatus -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe CoreDeviceStatus)
(Maybe CoreDeviceStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe CoreDeviceStatus
status :: Maybe CoreDeviceStatus
$sel:status:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe CoreDeviceStatus
status} -> Maybe CoreDeviceStatus
status) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe CoreDeviceStatus
a -> GetCoreDeviceResponse
s {$sel:status:GetCoreDeviceResponse' :: Maybe CoreDeviceStatus
status = Maybe CoreDeviceStatus
a} :: GetCoreDeviceResponse)
getCoreDeviceResponse_platform :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe Prelude.Text)
getCoreDeviceResponse_platform :: (Maybe Text -> f (Maybe Text))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_platform = (GetCoreDeviceResponse -> Maybe Text)
-> (GetCoreDeviceResponse -> Maybe Text -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe Text
platform :: Maybe Text
$sel:platform:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe Text
platform} -> Maybe Text
platform) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe Text
a -> GetCoreDeviceResponse
s {$sel:platform:GetCoreDeviceResponse' :: Maybe Text
platform = Maybe Text
a} :: GetCoreDeviceResponse)
getCoreDeviceResponse_architecture :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe Prelude.Text)
getCoreDeviceResponse_architecture :: (Maybe Text -> f (Maybe Text))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_architecture = (GetCoreDeviceResponse -> Maybe Text)
-> (GetCoreDeviceResponse -> Maybe Text -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe Text
architecture :: Maybe Text
$sel:architecture:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe Text
architecture} -> Maybe Text
architecture) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe Text
a -> GetCoreDeviceResponse
s {$sel:architecture:GetCoreDeviceResponse' :: Maybe Text
architecture = Maybe Text
a} :: GetCoreDeviceResponse)
getCoreDeviceResponse_coreDeviceThingName :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe Prelude.Text)
getCoreDeviceResponse_coreDeviceThingName :: (Maybe Text -> f (Maybe Text))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_coreDeviceThingName = (GetCoreDeviceResponse -> Maybe Text)
-> (GetCoreDeviceResponse -> Maybe Text -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe Text
coreDeviceThingName :: Maybe Text
$sel:coreDeviceThingName:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe Text
coreDeviceThingName} -> Maybe Text
coreDeviceThingName) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe Text
a -> GetCoreDeviceResponse
s {$sel:coreDeviceThingName:GetCoreDeviceResponse' :: Maybe Text
coreDeviceThingName = Maybe Text
a} :: GetCoreDeviceResponse)
getCoreDeviceResponse_tags :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
getCoreDeviceResponse_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_tags = (GetCoreDeviceResponse -> Maybe (HashMap Text Text))
-> (GetCoreDeviceResponse
-> Maybe (HashMap Text Text) -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe (HashMap Text Text)
a -> GetCoreDeviceResponse
s {$sel:tags:GetCoreDeviceResponse' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: GetCoreDeviceResponse) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> GetCoreDeviceResponse
-> f GetCoreDeviceResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
getCoreDeviceResponse_coreVersion :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe Prelude.Text)
getCoreDeviceResponse_coreVersion :: (Maybe Text -> f (Maybe Text))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_coreVersion = (GetCoreDeviceResponse -> Maybe Text)
-> (GetCoreDeviceResponse -> Maybe Text -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe Text
coreVersion :: Maybe Text
$sel:coreVersion:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe Text
coreVersion} -> Maybe Text
coreVersion) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe Text
a -> GetCoreDeviceResponse
s {$sel:coreVersion:GetCoreDeviceResponse' :: Maybe Text
coreVersion = Maybe Text
a} :: GetCoreDeviceResponse)
getCoreDeviceResponse_lastStatusUpdateTimestamp :: Lens.Lens' GetCoreDeviceResponse (Prelude.Maybe Prelude.UTCTime)
getCoreDeviceResponse_lastStatusUpdateTimestamp :: (Maybe UTCTime -> f (Maybe UTCTime))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_lastStatusUpdateTimestamp = (GetCoreDeviceResponse -> Maybe POSIX)
-> (GetCoreDeviceResponse -> Maybe POSIX -> GetCoreDeviceResponse)
-> Lens
GetCoreDeviceResponse
GetCoreDeviceResponse
(Maybe POSIX)
(Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Maybe POSIX
lastStatusUpdateTimestamp :: Maybe POSIX
$sel:lastStatusUpdateTimestamp:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Maybe POSIX
lastStatusUpdateTimestamp} -> Maybe POSIX
lastStatusUpdateTimestamp) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Maybe POSIX
a -> GetCoreDeviceResponse
s {$sel:lastStatusUpdateTimestamp:GetCoreDeviceResponse' :: Maybe POSIX
lastStatusUpdateTimestamp = Maybe POSIX
a} :: GetCoreDeviceResponse) ((Maybe POSIX -> f (Maybe POSIX))
-> GetCoreDeviceResponse -> f GetCoreDeviceResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> GetCoreDeviceResponse
-> f GetCoreDeviceResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
getCoreDeviceResponse_httpStatus :: Lens.Lens' GetCoreDeviceResponse Prelude.Int
getCoreDeviceResponse_httpStatus :: (Int -> f Int) -> GetCoreDeviceResponse -> f GetCoreDeviceResponse
getCoreDeviceResponse_httpStatus = (GetCoreDeviceResponse -> Int)
-> (GetCoreDeviceResponse -> Int -> GetCoreDeviceResponse)
-> Lens GetCoreDeviceResponse GetCoreDeviceResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetCoreDeviceResponse' {Int
httpStatus :: Int
$sel:httpStatus:GetCoreDeviceResponse' :: GetCoreDeviceResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: GetCoreDeviceResponse
s@GetCoreDeviceResponse' {} Int
a -> GetCoreDeviceResponse
s {$sel:httpStatus:GetCoreDeviceResponse' :: Int
httpStatus = Int
a} :: GetCoreDeviceResponse)
instance Prelude.NFData GetCoreDeviceResponse