{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.DataBrew.Types.Recipe
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.DataBrew.Types.Recipe where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.DataBrew.Types.RecipeStep
import qualified Amazonka.Prelude as Prelude

-- | Represents one or more actions to be performed on a DataBrew dataset.
--
-- /See:/ 'newRecipe' smart constructor.
data Recipe = Recipe'
  { -- | The date and time that the recipe was created.
    Recipe -> Maybe POSIX
createDate :: Prelude.Maybe Data.POSIX,
    -- | The Amazon Resource Name (ARN) of the user who created the recipe.
    Recipe -> Maybe Text
createdBy :: Prelude.Maybe Prelude.Text,
    -- | The description of the recipe.
    Recipe -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the user who last modified the recipe.
    Recipe -> Maybe Text
lastModifiedBy :: Prelude.Maybe Prelude.Text,
    -- | The last modification date and time of the recipe.
    Recipe -> Maybe POSIX
lastModifiedDate :: Prelude.Maybe Data.POSIX,
    -- | The name of the project that the recipe is associated with.
    Recipe -> Maybe Text
projectName :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the user who published the recipe.
    Recipe -> Maybe Text
publishedBy :: Prelude.Maybe Prelude.Text,
    -- | The date and time when the recipe was published.
    Recipe -> Maybe POSIX
publishedDate :: Prelude.Maybe Data.POSIX,
    -- | The identifier for the version for the recipe. Must be one of the
    -- following:
    --
    -- -   Numeric version (@X.Y@) - @X@ and @Y@ stand for major and minor
    --     version numbers. The maximum length of each is 6 digits, and neither
    --     can be negative values. Both @X@ and @Y@ are required, and \"0.0\"
    --     isn\'t a valid version.
    --
    -- -   @LATEST_WORKING@ - the most recent valid version being developed in
    --     a DataBrew project.
    --
    -- -   @LATEST_PUBLISHED@ - the most recent published version.
    Recipe -> Maybe Text
recipeVersion :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) for the recipe.
    Recipe -> Maybe Text
resourceArn :: Prelude.Maybe Prelude.Text,
    -- | A list of steps that are defined by the recipe.
    Recipe -> Maybe [RecipeStep]
steps :: Prelude.Maybe [RecipeStep],
    -- | Metadata tags that have been applied to the recipe.
    Recipe -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The unique name for the recipe.
    Recipe -> Text
name :: Prelude.Text
  }
  deriving (Recipe -> Recipe -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Recipe -> Recipe -> Bool
$c/= :: Recipe -> Recipe -> Bool
== :: Recipe -> Recipe -> Bool
$c== :: Recipe -> Recipe -> Bool
Prelude.Eq, ReadPrec [Recipe]
ReadPrec Recipe
Int -> ReadS Recipe
ReadS [Recipe]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Recipe]
$creadListPrec :: ReadPrec [Recipe]
readPrec :: ReadPrec Recipe
$creadPrec :: ReadPrec Recipe
readList :: ReadS [Recipe]
$creadList :: ReadS [Recipe]
readsPrec :: Int -> ReadS Recipe
$creadsPrec :: Int -> ReadS Recipe
Prelude.Read, Int -> Recipe -> ShowS
[Recipe] -> ShowS
Recipe -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Recipe] -> ShowS
$cshowList :: [Recipe] -> ShowS
show :: Recipe -> String
$cshow :: Recipe -> String
showsPrec :: Int -> Recipe -> ShowS
$cshowsPrec :: Int -> Recipe -> ShowS
Prelude.Show, forall x. Rep Recipe x -> Recipe
forall x. Recipe -> Rep Recipe x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Recipe x -> Recipe
$cfrom :: forall x. Recipe -> Rep Recipe x
Prelude.Generic)

-- |
-- Create a value of 'Recipe' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'createDate', 'recipe_createDate' - The date and time that the recipe was created.
--
-- 'createdBy', 'recipe_createdBy' - The Amazon Resource Name (ARN) of the user who created the recipe.
--
-- 'description', 'recipe_description' - The description of the recipe.
--
-- 'lastModifiedBy', 'recipe_lastModifiedBy' - The Amazon Resource Name (ARN) of the user who last modified the recipe.
--
-- 'lastModifiedDate', 'recipe_lastModifiedDate' - The last modification date and time of the recipe.
--
-- 'projectName', 'recipe_projectName' - The name of the project that the recipe is associated with.
--
-- 'publishedBy', 'recipe_publishedBy' - The Amazon Resource Name (ARN) of the user who published the recipe.
--
-- 'publishedDate', 'recipe_publishedDate' - The date and time when the recipe was published.
--
-- 'recipeVersion', 'recipe_recipeVersion' - The identifier for the version for the recipe. Must be one of the
-- following:
--
-- -   Numeric version (@X.Y@) - @X@ and @Y@ stand for major and minor
--     version numbers. The maximum length of each is 6 digits, and neither
--     can be negative values. Both @X@ and @Y@ are required, and \"0.0\"
--     isn\'t a valid version.
--
-- -   @LATEST_WORKING@ - the most recent valid version being developed in
--     a DataBrew project.
--
-- -   @LATEST_PUBLISHED@ - the most recent published version.
--
-- 'resourceArn', 'recipe_resourceArn' - The Amazon Resource Name (ARN) for the recipe.
--
-- 'steps', 'recipe_steps' - A list of steps that are defined by the recipe.
--
-- 'tags', 'recipe_tags' - Metadata tags that have been applied to the recipe.
--
-- 'name', 'recipe_name' - The unique name for the recipe.
newRecipe ::
  -- | 'name'
  Prelude.Text ->
  Recipe
newRecipe :: Text -> Recipe
newRecipe Text
pName_ =
  Recipe'
    { $sel:createDate:Recipe' :: Maybe POSIX
createDate = forall a. Maybe a
Prelude.Nothing,
      $sel:createdBy:Recipe' :: Maybe Text
createdBy = forall a. Maybe a
Prelude.Nothing,
      $sel:description:Recipe' :: Maybe Text
description = forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedBy:Recipe' :: Maybe Text
lastModifiedBy = forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedDate:Recipe' :: Maybe POSIX
lastModifiedDate = forall a. Maybe a
Prelude.Nothing,
      $sel:projectName:Recipe' :: Maybe Text
projectName = forall a. Maybe a
Prelude.Nothing,
      $sel:publishedBy:Recipe' :: Maybe Text
publishedBy = forall a. Maybe a
Prelude.Nothing,
      $sel:publishedDate:Recipe' :: Maybe POSIX
publishedDate = forall a. Maybe a
Prelude.Nothing,
      $sel:recipeVersion:Recipe' :: Maybe Text
recipeVersion = forall a. Maybe a
Prelude.Nothing,
      $sel:resourceArn:Recipe' :: Maybe Text
resourceArn = forall a. Maybe a
Prelude.Nothing,
      $sel:steps:Recipe' :: Maybe [RecipeStep]
steps = forall a. Maybe a
Prelude.Nothing,
      $sel:tags:Recipe' :: Maybe (HashMap Text Text)
tags = forall a. Maybe a
Prelude.Nothing,
      $sel:name:Recipe' :: Text
name = Text
pName_
    }

-- | The date and time that the recipe was created.
recipe_createDate :: Lens.Lens' Recipe (Prelude.Maybe Prelude.UTCTime)
recipe_createDate :: Lens' Recipe (Maybe UTCTime)
recipe_createDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe POSIX
createDate :: Maybe POSIX
$sel:createDate:Recipe' :: Recipe -> Maybe POSIX
createDate} -> Maybe POSIX
createDate) (\s :: Recipe
s@Recipe' {} Maybe POSIX
a -> Recipe
s {$sel:createDate:Recipe' :: Maybe POSIX
createDate = Maybe POSIX
a} :: Recipe) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | The Amazon Resource Name (ARN) of the user who created the recipe.
recipe_createdBy :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_createdBy :: Lens' Recipe (Maybe Text)
recipe_createdBy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
createdBy :: Maybe Text
$sel:createdBy:Recipe' :: Recipe -> Maybe Text
createdBy} -> Maybe Text
createdBy) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:createdBy:Recipe' :: Maybe Text
createdBy = Maybe Text
a} :: Recipe)

-- | The description of the recipe.
recipe_description :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_description :: Lens' Recipe (Maybe Text)
recipe_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
description :: Maybe Text
$sel:description:Recipe' :: Recipe -> Maybe Text
description} -> Maybe Text
description) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:description:Recipe' :: Maybe Text
description = Maybe Text
a} :: Recipe)

-- | The Amazon Resource Name (ARN) of the user who last modified the recipe.
recipe_lastModifiedBy :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_lastModifiedBy :: Lens' Recipe (Maybe Text)
recipe_lastModifiedBy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
lastModifiedBy :: Maybe Text
$sel:lastModifiedBy:Recipe' :: Recipe -> Maybe Text
lastModifiedBy} -> Maybe Text
lastModifiedBy) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:lastModifiedBy:Recipe' :: Maybe Text
lastModifiedBy = Maybe Text
a} :: Recipe)

-- | The last modification date and time of the recipe.
recipe_lastModifiedDate :: Lens.Lens' Recipe (Prelude.Maybe Prelude.UTCTime)
recipe_lastModifiedDate :: Lens' Recipe (Maybe UTCTime)
recipe_lastModifiedDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe POSIX
lastModifiedDate :: Maybe POSIX
$sel:lastModifiedDate:Recipe' :: Recipe -> Maybe POSIX
lastModifiedDate} -> Maybe POSIX
lastModifiedDate) (\s :: Recipe
s@Recipe' {} Maybe POSIX
a -> Recipe
s {$sel:lastModifiedDate:Recipe' :: Maybe POSIX
lastModifiedDate = Maybe POSIX
a} :: Recipe) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | The name of the project that the recipe is associated with.
recipe_projectName :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_projectName :: Lens' Recipe (Maybe Text)
recipe_projectName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
projectName :: Maybe Text
$sel:projectName:Recipe' :: Recipe -> Maybe Text
projectName} -> Maybe Text
projectName) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:projectName:Recipe' :: Maybe Text
projectName = Maybe Text
a} :: Recipe)

-- | The Amazon Resource Name (ARN) of the user who published the recipe.
recipe_publishedBy :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_publishedBy :: Lens' Recipe (Maybe Text)
recipe_publishedBy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
publishedBy :: Maybe Text
$sel:publishedBy:Recipe' :: Recipe -> Maybe Text
publishedBy} -> Maybe Text
publishedBy) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:publishedBy:Recipe' :: Maybe Text
publishedBy = Maybe Text
a} :: Recipe)

-- | The date and time when the recipe was published.
recipe_publishedDate :: Lens.Lens' Recipe (Prelude.Maybe Prelude.UTCTime)
recipe_publishedDate :: Lens' Recipe (Maybe UTCTime)
recipe_publishedDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe POSIX
publishedDate :: Maybe POSIX
$sel:publishedDate:Recipe' :: Recipe -> Maybe POSIX
publishedDate} -> Maybe POSIX
publishedDate) (\s :: Recipe
s@Recipe' {} Maybe POSIX
a -> Recipe
s {$sel:publishedDate:Recipe' :: Maybe POSIX
publishedDate = Maybe POSIX
a} :: Recipe) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | The identifier for the version for the recipe. Must be one of the
-- following:
--
-- -   Numeric version (@X.Y@) - @X@ and @Y@ stand for major and minor
--     version numbers. The maximum length of each is 6 digits, and neither
--     can be negative values. Both @X@ and @Y@ are required, and \"0.0\"
--     isn\'t a valid version.
--
-- -   @LATEST_WORKING@ - the most recent valid version being developed in
--     a DataBrew project.
--
-- -   @LATEST_PUBLISHED@ - the most recent published version.
recipe_recipeVersion :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_recipeVersion :: Lens' Recipe (Maybe Text)
recipe_recipeVersion = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
recipeVersion :: Maybe Text
$sel:recipeVersion:Recipe' :: Recipe -> Maybe Text
recipeVersion} -> Maybe Text
recipeVersion) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:recipeVersion:Recipe' :: Maybe Text
recipeVersion = Maybe Text
a} :: Recipe)

-- | The Amazon Resource Name (ARN) for the recipe.
recipe_resourceArn :: Lens.Lens' Recipe (Prelude.Maybe Prelude.Text)
recipe_resourceArn :: Lens' Recipe (Maybe Text)
recipe_resourceArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe Text
resourceArn :: Maybe Text
$sel:resourceArn:Recipe' :: Recipe -> Maybe Text
resourceArn} -> Maybe Text
resourceArn) (\s :: Recipe
s@Recipe' {} Maybe Text
a -> Recipe
s {$sel:resourceArn:Recipe' :: Maybe Text
resourceArn = Maybe Text
a} :: Recipe)

-- | A list of steps that are defined by the recipe.
recipe_steps :: Lens.Lens' Recipe (Prelude.Maybe [RecipeStep])
recipe_steps :: Lens' Recipe (Maybe [RecipeStep])
recipe_steps = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe [RecipeStep]
steps :: Maybe [RecipeStep]
$sel:steps:Recipe' :: Recipe -> Maybe [RecipeStep]
steps} -> Maybe [RecipeStep]
steps) (\s :: Recipe
s@Recipe' {} Maybe [RecipeStep]
a -> Recipe
s {$sel:steps:Recipe' :: Maybe [RecipeStep]
steps = Maybe [RecipeStep]
a} :: Recipe) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Metadata tags that have been applied to the recipe.
recipe_tags :: Lens.Lens' Recipe (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
recipe_tags :: Lens' Recipe (Maybe (HashMap Text Text))
recipe_tags = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:Recipe' :: Recipe -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: Recipe
s@Recipe' {} Maybe (HashMap Text Text)
a -> Recipe
s {$sel:tags:Recipe' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: Recipe) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The unique name for the recipe.
recipe_name :: Lens.Lens' Recipe Prelude.Text
recipe_name :: Lens' Recipe Text
recipe_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Recipe' {Text
name :: Text
$sel:name:Recipe' :: Recipe -> Text
name} -> Text
name) (\s :: Recipe
s@Recipe' {} Text
a -> Recipe
s {$sel:name:Recipe' :: Text
name = Text
a} :: Recipe)

instance Data.FromJSON Recipe where
  parseJSON :: Value -> Parser Recipe
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"Recipe"
      ( \Object
x ->
          Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe [RecipeStep]
-> Maybe (HashMap Text Text)
-> Text
-> Recipe
Recipe'
            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
"CreateDate")
            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
"CreatedBy")
            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
"Description")
            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
"LastModifiedBy")
            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
"LastModifiedDate")
            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
"ProjectName")
            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
"PublishedBy")
            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
"PublishedDate")
            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
"RecipeVersion")
            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
"ResourceArn")
            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
"Steps" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
            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
"Tags" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
            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
"Name")
      )

instance Prelude.Hashable Recipe where
  hashWithSalt :: Int -> Recipe -> Int
hashWithSalt Int
_salt Recipe' {Maybe [RecipeStep]
Maybe Text
Maybe (HashMap Text Text)
Maybe POSIX
Text
name :: Text
tags :: Maybe (HashMap Text Text)
steps :: Maybe [RecipeStep]
resourceArn :: Maybe Text
recipeVersion :: Maybe Text
publishedDate :: Maybe POSIX
publishedBy :: Maybe Text
projectName :: Maybe Text
lastModifiedDate :: Maybe POSIX
lastModifiedBy :: Maybe Text
description :: Maybe Text
createdBy :: Maybe Text
createDate :: Maybe POSIX
$sel:name:Recipe' :: Recipe -> Text
$sel:tags:Recipe' :: Recipe -> Maybe (HashMap Text Text)
$sel:steps:Recipe' :: Recipe -> Maybe [RecipeStep]
$sel:resourceArn:Recipe' :: Recipe -> Maybe Text
$sel:recipeVersion:Recipe' :: Recipe -> Maybe Text
$sel:publishedDate:Recipe' :: Recipe -> Maybe POSIX
$sel:publishedBy:Recipe' :: Recipe -> Maybe Text
$sel:projectName:Recipe' :: Recipe -> Maybe Text
$sel:lastModifiedDate:Recipe' :: Recipe -> Maybe POSIX
$sel:lastModifiedBy:Recipe' :: Recipe -> Maybe Text
$sel:description:Recipe' :: Recipe -> Maybe Text
$sel:createdBy:Recipe' :: Recipe -> Maybe Text
$sel:createDate:Recipe' :: Recipe -> Maybe POSIX
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
createDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
createdBy
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
description
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lastModifiedBy
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
lastModifiedDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
projectName
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
publishedBy
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
publishedDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
recipeVersion
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
resourceArn
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [RecipeStep]
steps
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
tags
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name

instance Prelude.NFData Recipe where
  rnf :: Recipe -> ()
rnf Recipe' {Maybe [RecipeStep]
Maybe Text
Maybe (HashMap Text Text)
Maybe POSIX
Text
name :: Text
tags :: Maybe (HashMap Text Text)
steps :: Maybe [RecipeStep]
resourceArn :: Maybe Text
recipeVersion :: Maybe Text
publishedDate :: Maybe POSIX
publishedBy :: Maybe Text
projectName :: Maybe Text
lastModifiedDate :: Maybe POSIX
lastModifiedBy :: Maybe Text
description :: Maybe Text
createdBy :: Maybe Text
createDate :: Maybe POSIX
$sel:name:Recipe' :: Recipe -> Text
$sel:tags:Recipe' :: Recipe -> Maybe (HashMap Text Text)
$sel:steps:Recipe' :: Recipe -> Maybe [RecipeStep]
$sel:resourceArn:Recipe' :: Recipe -> Maybe Text
$sel:recipeVersion:Recipe' :: Recipe -> Maybe Text
$sel:publishedDate:Recipe' :: Recipe -> Maybe POSIX
$sel:publishedBy:Recipe' :: Recipe -> Maybe Text
$sel:projectName:Recipe' :: Recipe -> Maybe Text
$sel:lastModifiedDate:Recipe' :: Recipe -> Maybe POSIX
$sel:lastModifiedBy:Recipe' :: Recipe -> Maybe Text
$sel:description:Recipe' :: Recipe -> Maybe Text
$sel:createdBy:Recipe' :: Recipe -> Maybe Text
$sel:createDate:Recipe' :: Recipe -> Maybe POSIX
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
createDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
createdBy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lastModifiedBy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
lastModifiedDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
projectName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
publishedBy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
publishedDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
recipeVersion
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
resourceArn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [RecipeStep]
steps
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
tags
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name