{-# 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 #-}
module Amazonka.IoTSiteWise.Types.BatchGetAssetPropertyValueErrorEntry where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.IoTSiteWise.Types.BatchGetAssetPropertyValueErrorCode
import qualified Amazonka.Prelude as Prelude
data BatchGetAssetPropertyValueErrorEntry = BatchGetAssetPropertyValueErrorEntry'
{
BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorCode
errorCode :: BatchGetAssetPropertyValueErrorCode,
BatchGetAssetPropertyValueErrorEntry -> Text
errorMessage :: Prelude.Text,
BatchGetAssetPropertyValueErrorEntry -> Text
entryId :: Prelude.Text
}
deriving (BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorEntry -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorEntry -> Bool
$c/= :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorEntry -> Bool
== :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorEntry -> Bool
$c== :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorEntry -> Bool
Prelude.Eq, ReadPrec [BatchGetAssetPropertyValueErrorEntry]
ReadPrec BatchGetAssetPropertyValueErrorEntry
Int -> ReadS BatchGetAssetPropertyValueErrorEntry
ReadS [BatchGetAssetPropertyValueErrorEntry]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BatchGetAssetPropertyValueErrorEntry]
$creadListPrec :: ReadPrec [BatchGetAssetPropertyValueErrorEntry]
readPrec :: ReadPrec BatchGetAssetPropertyValueErrorEntry
$creadPrec :: ReadPrec BatchGetAssetPropertyValueErrorEntry
readList :: ReadS [BatchGetAssetPropertyValueErrorEntry]
$creadList :: ReadS [BatchGetAssetPropertyValueErrorEntry]
readsPrec :: Int -> ReadS BatchGetAssetPropertyValueErrorEntry
$creadsPrec :: Int -> ReadS BatchGetAssetPropertyValueErrorEntry
Prelude.Read, Int -> BatchGetAssetPropertyValueErrorEntry -> ShowS
[BatchGetAssetPropertyValueErrorEntry] -> ShowS
BatchGetAssetPropertyValueErrorEntry -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchGetAssetPropertyValueErrorEntry] -> ShowS
$cshowList :: [BatchGetAssetPropertyValueErrorEntry] -> ShowS
show :: BatchGetAssetPropertyValueErrorEntry -> String
$cshow :: BatchGetAssetPropertyValueErrorEntry -> String
showsPrec :: Int -> BatchGetAssetPropertyValueErrorEntry -> ShowS
$cshowsPrec :: Int -> BatchGetAssetPropertyValueErrorEntry -> ShowS
Prelude.Show, forall x.
Rep BatchGetAssetPropertyValueErrorEntry x
-> BatchGetAssetPropertyValueErrorEntry
forall x.
BatchGetAssetPropertyValueErrorEntry
-> Rep BatchGetAssetPropertyValueErrorEntry x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BatchGetAssetPropertyValueErrorEntry x
-> BatchGetAssetPropertyValueErrorEntry
$cfrom :: forall x.
BatchGetAssetPropertyValueErrorEntry
-> Rep BatchGetAssetPropertyValueErrorEntry x
Prelude.Generic)
newBatchGetAssetPropertyValueErrorEntry ::
BatchGetAssetPropertyValueErrorCode ->
Prelude.Text ->
Prelude.Text ->
BatchGetAssetPropertyValueErrorEntry
newBatchGetAssetPropertyValueErrorEntry :: BatchGetAssetPropertyValueErrorCode
-> Text -> Text -> BatchGetAssetPropertyValueErrorEntry
newBatchGetAssetPropertyValueErrorEntry
BatchGetAssetPropertyValueErrorCode
pErrorCode_
Text
pErrorMessage_
Text
pEntryId_ =
BatchGetAssetPropertyValueErrorEntry'
{ $sel:errorCode:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorCode
errorCode =
BatchGetAssetPropertyValueErrorCode
pErrorCode_,
$sel:errorMessage:BatchGetAssetPropertyValueErrorEntry' :: Text
errorMessage = Text
pErrorMessage_,
$sel:entryId:BatchGetAssetPropertyValueErrorEntry' :: Text
entryId = Text
pEntryId_
}
batchGetAssetPropertyValueErrorEntry_errorCode :: Lens.Lens' BatchGetAssetPropertyValueErrorEntry BatchGetAssetPropertyValueErrorCode
batchGetAssetPropertyValueErrorEntry_errorCode :: Lens'
BatchGetAssetPropertyValueErrorEntry
BatchGetAssetPropertyValueErrorCode
batchGetAssetPropertyValueErrorEntry_errorCode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyValueErrorEntry' {BatchGetAssetPropertyValueErrorCode
errorCode :: BatchGetAssetPropertyValueErrorCode
$sel:errorCode:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorCode
errorCode} -> BatchGetAssetPropertyValueErrorCode
errorCode) (\s :: BatchGetAssetPropertyValueErrorEntry
s@BatchGetAssetPropertyValueErrorEntry' {} BatchGetAssetPropertyValueErrorCode
a -> BatchGetAssetPropertyValueErrorEntry
s {$sel:errorCode:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorCode
errorCode = BatchGetAssetPropertyValueErrorCode
a} :: BatchGetAssetPropertyValueErrorEntry)
batchGetAssetPropertyValueErrorEntry_errorMessage :: Lens.Lens' BatchGetAssetPropertyValueErrorEntry Prelude.Text
batchGetAssetPropertyValueErrorEntry_errorMessage :: Lens' BatchGetAssetPropertyValueErrorEntry Text
batchGetAssetPropertyValueErrorEntry_errorMessage = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyValueErrorEntry' {Text
errorMessage :: Text
$sel:errorMessage:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
errorMessage} -> Text
errorMessage) (\s :: BatchGetAssetPropertyValueErrorEntry
s@BatchGetAssetPropertyValueErrorEntry' {} Text
a -> BatchGetAssetPropertyValueErrorEntry
s {$sel:errorMessage:BatchGetAssetPropertyValueErrorEntry' :: Text
errorMessage = Text
a} :: BatchGetAssetPropertyValueErrorEntry)
batchGetAssetPropertyValueErrorEntry_entryId :: Lens.Lens' BatchGetAssetPropertyValueErrorEntry Prelude.Text
batchGetAssetPropertyValueErrorEntry_entryId :: Lens' BatchGetAssetPropertyValueErrorEntry Text
batchGetAssetPropertyValueErrorEntry_entryId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyValueErrorEntry' {Text
entryId :: Text
$sel:entryId:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
entryId} -> Text
entryId) (\s :: BatchGetAssetPropertyValueErrorEntry
s@BatchGetAssetPropertyValueErrorEntry' {} Text
a -> BatchGetAssetPropertyValueErrorEntry
s {$sel:entryId:BatchGetAssetPropertyValueErrorEntry' :: Text
entryId = Text
a} :: BatchGetAssetPropertyValueErrorEntry)
instance
Data.FromJSON
BatchGetAssetPropertyValueErrorEntry
where
parseJSON :: Value -> Parser BatchGetAssetPropertyValueErrorEntry
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"BatchGetAssetPropertyValueErrorEntry"
( \Object
x ->
BatchGetAssetPropertyValueErrorCode
-> Text -> Text -> BatchGetAssetPropertyValueErrorEntry
BatchGetAssetPropertyValueErrorEntry'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"errorCode")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"errorMessage")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"entryId")
)
instance
Prelude.Hashable
BatchGetAssetPropertyValueErrorEntry
where
hashWithSalt :: Int -> BatchGetAssetPropertyValueErrorEntry -> Int
hashWithSalt
Int
_salt
BatchGetAssetPropertyValueErrorEntry' {Text
BatchGetAssetPropertyValueErrorCode
entryId :: Text
errorMessage :: Text
errorCode :: BatchGetAssetPropertyValueErrorCode
$sel:entryId:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
$sel:errorMessage:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
$sel:errorCode:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorCode
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` BatchGetAssetPropertyValueErrorCode
errorCode
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
errorMessage
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
entryId
instance
Prelude.NFData
BatchGetAssetPropertyValueErrorEntry
where
rnf :: BatchGetAssetPropertyValueErrorEntry -> ()
rnf BatchGetAssetPropertyValueErrorEntry' {Text
BatchGetAssetPropertyValueErrorCode
entryId :: Text
errorMessage :: Text
errorCode :: BatchGetAssetPropertyValueErrorCode
$sel:entryId:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
$sel:errorMessage:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry -> Text
$sel:errorCode:BatchGetAssetPropertyValueErrorEntry' :: BatchGetAssetPropertyValueErrorEntry
-> BatchGetAssetPropertyValueErrorCode
..} =
forall a. NFData a => a -> ()
Prelude.rnf BatchGetAssetPropertyValueErrorCode
errorCode
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
errorMessage
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
entryId