{-# 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.BatchGetAssetPropertyAggregatesErrorEntry 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.BatchGetAssetPropertyAggregatesErrorCode
import qualified Amazonka.Prelude as Prelude
data BatchGetAssetPropertyAggregatesErrorEntry = BatchGetAssetPropertyAggregatesErrorEntry'
{
BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorCode
errorCode :: BatchGetAssetPropertyAggregatesErrorCode,
BatchGetAssetPropertyAggregatesErrorEntry -> Text
errorMessage :: Prelude.Text,
BatchGetAssetPropertyAggregatesErrorEntry -> Text
entryId :: Prelude.Text
}
deriving (BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorEntry -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorEntry -> Bool
$c/= :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorEntry -> Bool
== :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorEntry -> Bool
$c== :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorEntry -> Bool
Prelude.Eq, ReadPrec [BatchGetAssetPropertyAggregatesErrorEntry]
ReadPrec BatchGetAssetPropertyAggregatesErrorEntry
Int -> ReadS BatchGetAssetPropertyAggregatesErrorEntry
ReadS [BatchGetAssetPropertyAggregatesErrorEntry]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BatchGetAssetPropertyAggregatesErrorEntry]
$creadListPrec :: ReadPrec [BatchGetAssetPropertyAggregatesErrorEntry]
readPrec :: ReadPrec BatchGetAssetPropertyAggregatesErrorEntry
$creadPrec :: ReadPrec BatchGetAssetPropertyAggregatesErrorEntry
readList :: ReadS [BatchGetAssetPropertyAggregatesErrorEntry]
$creadList :: ReadS [BatchGetAssetPropertyAggregatesErrorEntry]
readsPrec :: Int -> ReadS BatchGetAssetPropertyAggregatesErrorEntry
$creadsPrec :: Int -> ReadS BatchGetAssetPropertyAggregatesErrorEntry
Prelude.Read, Int -> BatchGetAssetPropertyAggregatesErrorEntry -> ShowS
[BatchGetAssetPropertyAggregatesErrorEntry] -> ShowS
BatchGetAssetPropertyAggregatesErrorEntry -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchGetAssetPropertyAggregatesErrorEntry] -> ShowS
$cshowList :: [BatchGetAssetPropertyAggregatesErrorEntry] -> ShowS
show :: BatchGetAssetPropertyAggregatesErrorEntry -> String
$cshow :: BatchGetAssetPropertyAggregatesErrorEntry -> String
showsPrec :: Int -> BatchGetAssetPropertyAggregatesErrorEntry -> ShowS
$cshowsPrec :: Int -> BatchGetAssetPropertyAggregatesErrorEntry -> ShowS
Prelude.Show, forall x.
Rep BatchGetAssetPropertyAggregatesErrorEntry x
-> BatchGetAssetPropertyAggregatesErrorEntry
forall x.
BatchGetAssetPropertyAggregatesErrorEntry
-> Rep BatchGetAssetPropertyAggregatesErrorEntry x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BatchGetAssetPropertyAggregatesErrorEntry x
-> BatchGetAssetPropertyAggregatesErrorEntry
$cfrom :: forall x.
BatchGetAssetPropertyAggregatesErrorEntry
-> Rep BatchGetAssetPropertyAggregatesErrorEntry x
Prelude.Generic)
newBatchGetAssetPropertyAggregatesErrorEntry ::
BatchGetAssetPropertyAggregatesErrorCode ->
Prelude.Text ->
Prelude.Text ->
BatchGetAssetPropertyAggregatesErrorEntry
newBatchGetAssetPropertyAggregatesErrorEntry :: BatchGetAssetPropertyAggregatesErrorCode
-> Text -> Text -> BatchGetAssetPropertyAggregatesErrorEntry
newBatchGetAssetPropertyAggregatesErrorEntry
BatchGetAssetPropertyAggregatesErrorCode
pErrorCode_
Text
pErrorMessage_
Text
pEntryId_ =
BatchGetAssetPropertyAggregatesErrorEntry'
{ $sel:errorCode:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorCode
errorCode =
BatchGetAssetPropertyAggregatesErrorCode
pErrorCode_,
$sel:errorMessage:BatchGetAssetPropertyAggregatesErrorEntry' :: Text
errorMessage = Text
pErrorMessage_,
$sel:entryId:BatchGetAssetPropertyAggregatesErrorEntry' :: Text
entryId = Text
pEntryId_
}
batchGetAssetPropertyAggregatesErrorEntry_errorCode :: Lens.Lens' BatchGetAssetPropertyAggregatesErrorEntry BatchGetAssetPropertyAggregatesErrorCode
batchGetAssetPropertyAggregatesErrorEntry_errorCode :: Lens'
BatchGetAssetPropertyAggregatesErrorEntry
BatchGetAssetPropertyAggregatesErrorCode
batchGetAssetPropertyAggregatesErrorEntry_errorCode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyAggregatesErrorEntry' {BatchGetAssetPropertyAggregatesErrorCode
errorCode :: BatchGetAssetPropertyAggregatesErrorCode
$sel:errorCode:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorCode
errorCode} -> BatchGetAssetPropertyAggregatesErrorCode
errorCode) (\s :: BatchGetAssetPropertyAggregatesErrorEntry
s@BatchGetAssetPropertyAggregatesErrorEntry' {} BatchGetAssetPropertyAggregatesErrorCode
a -> BatchGetAssetPropertyAggregatesErrorEntry
s {$sel:errorCode:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorCode
errorCode = BatchGetAssetPropertyAggregatesErrorCode
a} :: BatchGetAssetPropertyAggregatesErrorEntry)
batchGetAssetPropertyAggregatesErrorEntry_errorMessage :: Lens.Lens' BatchGetAssetPropertyAggregatesErrorEntry Prelude.Text
batchGetAssetPropertyAggregatesErrorEntry_errorMessage :: Lens' BatchGetAssetPropertyAggregatesErrorEntry Text
batchGetAssetPropertyAggregatesErrorEntry_errorMessage = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyAggregatesErrorEntry' {Text
errorMessage :: Text
$sel:errorMessage:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
errorMessage} -> Text
errorMessage) (\s :: BatchGetAssetPropertyAggregatesErrorEntry
s@BatchGetAssetPropertyAggregatesErrorEntry' {} Text
a -> BatchGetAssetPropertyAggregatesErrorEntry
s {$sel:errorMessage:BatchGetAssetPropertyAggregatesErrorEntry' :: Text
errorMessage = Text
a} :: BatchGetAssetPropertyAggregatesErrorEntry)
batchGetAssetPropertyAggregatesErrorEntry_entryId :: Lens.Lens' BatchGetAssetPropertyAggregatesErrorEntry Prelude.Text
batchGetAssetPropertyAggregatesErrorEntry_entryId :: Lens' BatchGetAssetPropertyAggregatesErrorEntry Text
batchGetAssetPropertyAggregatesErrorEntry_entryId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetAssetPropertyAggregatesErrorEntry' {Text
entryId :: Text
$sel:entryId:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
entryId} -> Text
entryId) (\s :: BatchGetAssetPropertyAggregatesErrorEntry
s@BatchGetAssetPropertyAggregatesErrorEntry' {} Text
a -> BatchGetAssetPropertyAggregatesErrorEntry
s {$sel:entryId:BatchGetAssetPropertyAggregatesErrorEntry' :: Text
entryId = Text
a} :: BatchGetAssetPropertyAggregatesErrorEntry)
instance
Data.FromJSON
BatchGetAssetPropertyAggregatesErrorEntry
where
parseJSON :: Value -> Parser BatchGetAssetPropertyAggregatesErrorEntry
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"BatchGetAssetPropertyAggregatesErrorEntry"
( \Object
x ->
BatchGetAssetPropertyAggregatesErrorCode
-> Text -> Text -> BatchGetAssetPropertyAggregatesErrorEntry
BatchGetAssetPropertyAggregatesErrorEntry'
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
BatchGetAssetPropertyAggregatesErrorEntry
where
hashWithSalt :: Int -> BatchGetAssetPropertyAggregatesErrorEntry -> Int
hashWithSalt
Int
_salt
BatchGetAssetPropertyAggregatesErrorEntry' {Text
BatchGetAssetPropertyAggregatesErrorCode
entryId :: Text
errorMessage :: Text
errorCode :: BatchGetAssetPropertyAggregatesErrorCode
$sel:entryId:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
$sel:errorMessage:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
$sel:errorCode:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorCode
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` BatchGetAssetPropertyAggregatesErrorCode
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
BatchGetAssetPropertyAggregatesErrorEntry
where
rnf :: BatchGetAssetPropertyAggregatesErrorEntry -> ()
rnf BatchGetAssetPropertyAggregatesErrorEntry' {Text
BatchGetAssetPropertyAggregatesErrorCode
entryId :: Text
errorMessage :: Text
errorCode :: BatchGetAssetPropertyAggregatesErrorCode
$sel:entryId:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
$sel:errorMessage:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry -> Text
$sel:errorCode:BatchGetAssetPropertyAggregatesErrorEntry' :: BatchGetAssetPropertyAggregatesErrorEntry
-> BatchGetAssetPropertyAggregatesErrorCode
..} =
forall a. NFData a => a -> ()
Prelude.rnf BatchGetAssetPropertyAggregatesErrorCode
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