{-# 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.Forecast.Types.DatasetGroupSummary where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data DatasetGroupSummary = DatasetGroupSummary'
{
DatasetGroupSummary -> Maybe POSIX
creationTime :: Prelude.Maybe Core.POSIX,
DatasetGroupSummary -> Maybe Text
datasetGroupName :: Prelude.Maybe Prelude.Text,
DatasetGroupSummary -> Maybe Text
datasetGroupArn :: Prelude.Maybe Prelude.Text,
DatasetGroupSummary -> Maybe POSIX
lastModificationTime :: Prelude.Maybe Core.POSIX
}
deriving (DatasetGroupSummary -> DatasetGroupSummary -> Bool
(DatasetGroupSummary -> DatasetGroupSummary -> Bool)
-> (DatasetGroupSummary -> DatasetGroupSummary -> Bool)
-> Eq DatasetGroupSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DatasetGroupSummary -> DatasetGroupSummary -> Bool
$c/= :: DatasetGroupSummary -> DatasetGroupSummary -> Bool
== :: DatasetGroupSummary -> DatasetGroupSummary -> Bool
$c== :: DatasetGroupSummary -> DatasetGroupSummary -> Bool
Prelude.Eq, ReadPrec [DatasetGroupSummary]
ReadPrec DatasetGroupSummary
Int -> ReadS DatasetGroupSummary
ReadS [DatasetGroupSummary]
(Int -> ReadS DatasetGroupSummary)
-> ReadS [DatasetGroupSummary]
-> ReadPrec DatasetGroupSummary
-> ReadPrec [DatasetGroupSummary]
-> Read DatasetGroupSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DatasetGroupSummary]
$creadListPrec :: ReadPrec [DatasetGroupSummary]
readPrec :: ReadPrec DatasetGroupSummary
$creadPrec :: ReadPrec DatasetGroupSummary
readList :: ReadS [DatasetGroupSummary]
$creadList :: ReadS [DatasetGroupSummary]
readsPrec :: Int -> ReadS DatasetGroupSummary
$creadsPrec :: Int -> ReadS DatasetGroupSummary
Prelude.Read, Int -> DatasetGroupSummary -> ShowS
[DatasetGroupSummary] -> ShowS
DatasetGroupSummary -> String
(Int -> DatasetGroupSummary -> ShowS)
-> (DatasetGroupSummary -> String)
-> ([DatasetGroupSummary] -> ShowS)
-> Show DatasetGroupSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DatasetGroupSummary] -> ShowS
$cshowList :: [DatasetGroupSummary] -> ShowS
show :: DatasetGroupSummary -> String
$cshow :: DatasetGroupSummary -> String
showsPrec :: Int -> DatasetGroupSummary -> ShowS
$cshowsPrec :: Int -> DatasetGroupSummary -> ShowS
Prelude.Show, (forall x. DatasetGroupSummary -> Rep DatasetGroupSummary x)
-> (forall x. Rep DatasetGroupSummary x -> DatasetGroupSummary)
-> Generic DatasetGroupSummary
forall x. Rep DatasetGroupSummary x -> DatasetGroupSummary
forall x. DatasetGroupSummary -> Rep DatasetGroupSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DatasetGroupSummary x -> DatasetGroupSummary
$cfrom :: forall x. DatasetGroupSummary -> Rep DatasetGroupSummary x
Prelude.Generic)
newDatasetGroupSummary ::
DatasetGroupSummary
newDatasetGroupSummary :: DatasetGroupSummary
newDatasetGroupSummary =
DatasetGroupSummary' :: Maybe POSIX
-> Maybe Text -> Maybe Text -> Maybe POSIX -> DatasetGroupSummary
DatasetGroupSummary'
{ $sel:creationTime:DatasetGroupSummary' :: Maybe POSIX
creationTime =
Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:datasetGroupName:DatasetGroupSummary' :: Maybe Text
datasetGroupName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:datasetGroupArn:DatasetGroupSummary' :: Maybe Text
datasetGroupArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lastModificationTime:DatasetGroupSummary' :: Maybe POSIX
lastModificationTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing
}
datasetGroupSummary_creationTime :: Lens.Lens' DatasetGroupSummary (Prelude.Maybe Prelude.UTCTime)
datasetGroupSummary_creationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DatasetGroupSummary -> f DatasetGroupSummary
datasetGroupSummary_creationTime = (DatasetGroupSummary -> Maybe POSIX)
-> (DatasetGroupSummary -> Maybe POSIX -> DatasetGroupSummary)
-> Lens
DatasetGroupSummary DatasetGroupSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DatasetGroupSummary' {Maybe POSIX
creationTime :: Maybe POSIX
$sel:creationTime:DatasetGroupSummary' :: DatasetGroupSummary -> Maybe POSIX
creationTime} -> Maybe POSIX
creationTime) (\s :: DatasetGroupSummary
s@DatasetGroupSummary' {} Maybe POSIX
a -> DatasetGroupSummary
s {$sel:creationTime:DatasetGroupSummary' :: Maybe POSIX
creationTime = Maybe POSIX
a} :: DatasetGroupSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> DatasetGroupSummary -> f DatasetGroupSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DatasetGroupSummary
-> f DatasetGroupSummary
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
datasetGroupSummary_datasetGroupName :: Lens.Lens' DatasetGroupSummary (Prelude.Maybe Prelude.Text)
datasetGroupSummary_datasetGroupName :: (Maybe Text -> f (Maybe Text))
-> DatasetGroupSummary -> f DatasetGroupSummary
datasetGroupSummary_datasetGroupName = (DatasetGroupSummary -> Maybe Text)
-> (DatasetGroupSummary -> Maybe Text -> DatasetGroupSummary)
-> Lens
DatasetGroupSummary DatasetGroupSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DatasetGroupSummary' {Maybe Text
datasetGroupName :: Maybe Text
$sel:datasetGroupName:DatasetGroupSummary' :: DatasetGroupSummary -> Maybe Text
datasetGroupName} -> Maybe Text
datasetGroupName) (\s :: DatasetGroupSummary
s@DatasetGroupSummary' {} Maybe Text
a -> DatasetGroupSummary
s {$sel:datasetGroupName:DatasetGroupSummary' :: Maybe Text
datasetGroupName = Maybe Text
a} :: DatasetGroupSummary)
datasetGroupSummary_datasetGroupArn :: Lens.Lens' DatasetGroupSummary (Prelude.Maybe Prelude.Text)
datasetGroupSummary_datasetGroupArn :: (Maybe Text -> f (Maybe Text))
-> DatasetGroupSummary -> f DatasetGroupSummary
datasetGroupSummary_datasetGroupArn = (DatasetGroupSummary -> Maybe Text)
-> (DatasetGroupSummary -> Maybe Text -> DatasetGroupSummary)
-> Lens
DatasetGroupSummary DatasetGroupSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DatasetGroupSummary' {Maybe Text
datasetGroupArn :: Maybe Text
$sel:datasetGroupArn:DatasetGroupSummary' :: DatasetGroupSummary -> Maybe Text
datasetGroupArn} -> Maybe Text
datasetGroupArn) (\s :: DatasetGroupSummary
s@DatasetGroupSummary' {} Maybe Text
a -> DatasetGroupSummary
s {$sel:datasetGroupArn:DatasetGroupSummary' :: Maybe Text
datasetGroupArn = Maybe Text
a} :: DatasetGroupSummary)
datasetGroupSummary_lastModificationTime :: Lens.Lens' DatasetGroupSummary (Prelude.Maybe Prelude.UTCTime)
datasetGroupSummary_lastModificationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DatasetGroupSummary -> f DatasetGroupSummary
datasetGroupSummary_lastModificationTime = (DatasetGroupSummary -> Maybe POSIX)
-> (DatasetGroupSummary -> Maybe POSIX -> DatasetGroupSummary)
-> Lens
DatasetGroupSummary DatasetGroupSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DatasetGroupSummary' {Maybe POSIX
lastModificationTime :: Maybe POSIX
$sel:lastModificationTime:DatasetGroupSummary' :: DatasetGroupSummary -> Maybe POSIX
lastModificationTime} -> Maybe POSIX
lastModificationTime) (\s :: DatasetGroupSummary
s@DatasetGroupSummary' {} Maybe POSIX
a -> DatasetGroupSummary
s {$sel:lastModificationTime:DatasetGroupSummary' :: Maybe POSIX
lastModificationTime = Maybe POSIX
a} :: DatasetGroupSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> DatasetGroupSummary -> f DatasetGroupSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DatasetGroupSummary
-> f DatasetGroupSummary
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
instance Core.FromJSON DatasetGroupSummary where
parseJSON :: Value -> Parser DatasetGroupSummary
parseJSON =
String
-> (Object -> Parser DatasetGroupSummary)
-> Value
-> Parser DatasetGroupSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"DatasetGroupSummary"
( \Object
x ->
Maybe POSIX
-> Maybe Text -> Maybe Text -> Maybe POSIX -> DatasetGroupSummary
DatasetGroupSummary'
(Maybe POSIX
-> Maybe Text -> Maybe Text -> Maybe POSIX -> DatasetGroupSummary)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text -> Maybe Text -> Maybe POSIX -> DatasetGroupSummary)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CreationTime")
Parser
(Maybe Text -> Maybe Text -> Maybe POSIX -> DatasetGroupSummary)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe POSIX -> DatasetGroupSummary)
forall (f :: * -> *) a b. Applicative f => 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
"DatasetGroupName")
Parser (Maybe Text -> Maybe POSIX -> DatasetGroupSummary)
-> Parser (Maybe Text)
-> Parser (Maybe POSIX -> DatasetGroupSummary)
forall (f :: * -> *) a b. Applicative f => 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
"DatasetGroupArn")
Parser (Maybe POSIX -> DatasetGroupSummary)
-> Parser (Maybe POSIX) -> Parser DatasetGroupSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LastModificationTime")
)
instance Prelude.Hashable DatasetGroupSummary
instance Prelude.NFData DatasetGroupSummary