{-# 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.IoTEvents.Types.AnalysisResultLocation where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data AnalysisResultLocation = AnalysisResultLocation'
{
AnalysisResultLocation -> Maybe Text
path :: Prelude.Maybe Prelude.Text
}
deriving (AnalysisResultLocation -> AnalysisResultLocation -> Bool
(AnalysisResultLocation -> AnalysisResultLocation -> Bool)
-> (AnalysisResultLocation -> AnalysisResultLocation -> Bool)
-> Eq AnalysisResultLocation
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AnalysisResultLocation -> AnalysisResultLocation -> Bool
$c/= :: AnalysisResultLocation -> AnalysisResultLocation -> Bool
== :: AnalysisResultLocation -> AnalysisResultLocation -> Bool
$c== :: AnalysisResultLocation -> AnalysisResultLocation -> Bool
Prelude.Eq, ReadPrec [AnalysisResultLocation]
ReadPrec AnalysisResultLocation
Int -> ReadS AnalysisResultLocation
ReadS [AnalysisResultLocation]
(Int -> ReadS AnalysisResultLocation)
-> ReadS [AnalysisResultLocation]
-> ReadPrec AnalysisResultLocation
-> ReadPrec [AnalysisResultLocation]
-> Read AnalysisResultLocation
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AnalysisResultLocation]
$creadListPrec :: ReadPrec [AnalysisResultLocation]
readPrec :: ReadPrec AnalysisResultLocation
$creadPrec :: ReadPrec AnalysisResultLocation
readList :: ReadS [AnalysisResultLocation]
$creadList :: ReadS [AnalysisResultLocation]
readsPrec :: Int -> ReadS AnalysisResultLocation
$creadsPrec :: Int -> ReadS AnalysisResultLocation
Prelude.Read, Int -> AnalysisResultLocation -> ShowS
[AnalysisResultLocation] -> ShowS
AnalysisResultLocation -> String
(Int -> AnalysisResultLocation -> ShowS)
-> (AnalysisResultLocation -> String)
-> ([AnalysisResultLocation] -> ShowS)
-> Show AnalysisResultLocation
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AnalysisResultLocation] -> ShowS
$cshowList :: [AnalysisResultLocation] -> ShowS
show :: AnalysisResultLocation -> String
$cshow :: AnalysisResultLocation -> String
showsPrec :: Int -> AnalysisResultLocation -> ShowS
$cshowsPrec :: Int -> AnalysisResultLocation -> ShowS
Prelude.Show, (forall x. AnalysisResultLocation -> Rep AnalysisResultLocation x)
-> (forall x.
Rep AnalysisResultLocation x -> AnalysisResultLocation)
-> Generic AnalysisResultLocation
forall x. Rep AnalysisResultLocation x -> AnalysisResultLocation
forall x. AnalysisResultLocation -> Rep AnalysisResultLocation x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AnalysisResultLocation x -> AnalysisResultLocation
$cfrom :: forall x. AnalysisResultLocation -> Rep AnalysisResultLocation x
Prelude.Generic)
newAnalysisResultLocation ::
AnalysisResultLocation
newAnalysisResultLocation :: AnalysisResultLocation
newAnalysisResultLocation =
AnalysisResultLocation' :: Maybe Text -> AnalysisResultLocation
AnalysisResultLocation' {$sel:path:AnalysisResultLocation' :: Maybe Text
path = Maybe Text
forall a. Maybe a
Prelude.Nothing}
analysisResultLocation_path :: Lens.Lens' AnalysisResultLocation (Prelude.Maybe Prelude.Text)
analysisResultLocation_path :: (Maybe Text -> f (Maybe Text))
-> AnalysisResultLocation -> f AnalysisResultLocation
analysisResultLocation_path = (AnalysisResultLocation -> Maybe Text)
-> (AnalysisResultLocation -> Maybe Text -> AnalysisResultLocation)
-> Lens
AnalysisResultLocation
AnalysisResultLocation
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AnalysisResultLocation' {Maybe Text
path :: Maybe Text
$sel:path:AnalysisResultLocation' :: AnalysisResultLocation -> Maybe Text
path} -> Maybe Text
path) (\s :: AnalysisResultLocation
s@AnalysisResultLocation' {} Maybe Text
a -> AnalysisResultLocation
s {$sel:path:AnalysisResultLocation' :: Maybe Text
path = Maybe Text
a} :: AnalysisResultLocation)
instance Core.FromJSON AnalysisResultLocation where
parseJSON :: Value -> Parser AnalysisResultLocation
parseJSON =
String
-> (Object -> Parser AnalysisResultLocation)
-> Value
-> Parser AnalysisResultLocation
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AnalysisResultLocation"
( \Object
x ->
Maybe Text -> AnalysisResultLocation
AnalysisResultLocation'
(Maybe Text -> AnalysisResultLocation)
-> Parser (Maybe Text) -> Parser AnalysisResultLocation
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
"path")
)
instance Prelude.Hashable AnalysisResultLocation
instance Prelude.NFData AnalysisResultLocation