{-# 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.SageMakerGeoSpatial.Types.ExportErrorDetailsOutput where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import Amazonka.SageMakerGeoSpatial.Types.ExportErrorType
data ExportErrorDetailsOutput = ExportErrorDetailsOutput'
{ ExportErrorDetailsOutput -> Maybe Text
message :: Prelude.Maybe Prelude.Text,
ExportErrorDetailsOutput -> Maybe ExportErrorType
type' :: Prelude.Maybe ExportErrorType
}
deriving (ExportErrorDetailsOutput -> ExportErrorDetailsOutput -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ExportErrorDetailsOutput -> ExportErrorDetailsOutput -> Bool
$c/= :: ExportErrorDetailsOutput -> ExportErrorDetailsOutput -> Bool
== :: ExportErrorDetailsOutput -> ExportErrorDetailsOutput -> Bool
$c== :: ExportErrorDetailsOutput -> ExportErrorDetailsOutput -> Bool
Prelude.Eq, ReadPrec [ExportErrorDetailsOutput]
ReadPrec ExportErrorDetailsOutput
Int -> ReadS ExportErrorDetailsOutput
ReadS [ExportErrorDetailsOutput]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ExportErrorDetailsOutput]
$creadListPrec :: ReadPrec [ExportErrorDetailsOutput]
readPrec :: ReadPrec ExportErrorDetailsOutput
$creadPrec :: ReadPrec ExportErrorDetailsOutput
readList :: ReadS [ExportErrorDetailsOutput]
$creadList :: ReadS [ExportErrorDetailsOutput]
readsPrec :: Int -> ReadS ExportErrorDetailsOutput
$creadsPrec :: Int -> ReadS ExportErrorDetailsOutput
Prelude.Read, Int -> ExportErrorDetailsOutput -> ShowS
[ExportErrorDetailsOutput] -> ShowS
ExportErrorDetailsOutput -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ExportErrorDetailsOutput] -> ShowS
$cshowList :: [ExportErrorDetailsOutput] -> ShowS
show :: ExportErrorDetailsOutput -> String
$cshow :: ExportErrorDetailsOutput -> String
showsPrec :: Int -> ExportErrorDetailsOutput -> ShowS
$cshowsPrec :: Int -> ExportErrorDetailsOutput -> ShowS
Prelude.Show, forall x.
Rep ExportErrorDetailsOutput x -> ExportErrorDetailsOutput
forall x.
ExportErrorDetailsOutput -> Rep ExportErrorDetailsOutput x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ExportErrorDetailsOutput x -> ExportErrorDetailsOutput
$cfrom :: forall x.
ExportErrorDetailsOutput -> Rep ExportErrorDetailsOutput x
Prelude.Generic)
newExportErrorDetailsOutput ::
ExportErrorDetailsOutput
newExportErrorDetailsOutput :: ExportErrorDetailsOutput
newExportErrorDetailsOutput =
ExportErrorDetailsOutput'
{ $sel:message:ExportErrorDetailsOutput' :: Maybe Text
message =
forall a. Maybe a
Prelude.Nothing,
$sel:type':ExportErrorDetailsOutput' :: Maybe ExportErrorType
type' = forall a. Maybe a
Prelude.Nothing
}
exportErrorDetailsOutput_message :: Lens.Lens' ExportErrorDetailsOutput (Prelude.Maybe Prelude.Text)
exportErrorDetailsOutput_message :: Lens' ExportErrorDetailsOutput (Maybe Text)
exportErrorDetailsOutput_message = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ExportErrorDetailsOutput' {Maybe Text
message :: Maybe Text
$sel:message:ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe Text
message} -> Maybe Text
message) (\s :: ExportErrorDetailsOutput
s@ExportErrorDetailsOutput' {} Maybe Text
a -> ExportErrorDetailsOutput
s {$sel:message:ExportErrorDetailsOutput' :: Maybe Text
message = Maybe Text
a} :: ExportErrorDetailsOutput)
exportErrorDetailsOutput_type :: Lens.Lens' ExportErrorDetailsOutput (Prelude.Maybe ExportErrorType)
exportErrorDetailsOutput_type :: Lens' ExportErrorDetailsOutput (Maybe ExportErrorType)
exportErrorDetailsOutput_type = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ExportErrorDetailsOutput' {Maybe ExportErrorType
type' :: Maybe ExportErrorType
$sel:type':ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe ExportErrorType
type'} -> Maybe ExportErrorType
type') (\s :: ExportErrorDetailsOutput
s@ExportErrorDetailsOutput' {} Maybe ExportErrorType
a -> ExportErrorDetailsOutput
s {$sel:type':ExportErrorDetailsOutput' :: Maybe ExportErrorType
type' = Maybe ExportErrorType
a} :: ExportErrorDetailsOutput)
instance Data.FromJSON ExportErrorDetailsOutput where
parseJSON :: Value -> Parser ExportErrorDetailsOutput
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ExportErrorDetailsOutput"
( \Object
x ->
Maybe Text -> Maybe ExportErrorType -> ExportErrorDetailsOutput
ExportErrorDetailsOutput'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Message")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Type")
)
instance Prelude.Hashable ExportErrorDetailsOutput where
hashWithSalt :: Int -> ExportErrorDetailsOutput -> Int
hashWithSalt Int
_salt ExportErrorDetailsOutput' {Maybe Text
Maybe ExportErrorType
type' :: Maybe ExportErrorType
message :: Maybe Text
$sel:type':ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe ExportErrorType
$sel:message:ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
message
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ExportErrorType
type'
instance Prelude.NFData ExportErrorDetailsOutput where
rnf :: ExportErrorDetailsOutput -> ()
rnf ExportErrorDetailsOutput' {Maybe Text
Maybe ExportErrorType
type' :: Maybe ExportErrorType
message :: Maybe Text
$sel:type':ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe ExportErrorType
$sel:message:ExportErrorDetailsOutput' :: ExportErrorDetailsOutput -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
message seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ExportErrorType
type'