amazonka-databrew-2.0: gen/Amazonka/DataBrew/Types/S3TableOutputOptions.hs
{-# 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.S3TableOutputOptions
-- 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.S3TableOutputOptions 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.S3Location
import qualified Amazonka.Prelude as Prelude
-- | Represents options that specify how and where DataBrew writes the Amazon
-- S3 output generated by recipe jobs.
--
-- /See:/ 'newS3TableOutputOptions' smart constructor.
data S3TableOutputOptions = S3TableOutputOptions'
{ -- | Represents an Amazon S3 location (bucket name and object key) where
-- DataBrew can write output from a job.
location :: S3Location
}
deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)
-- |
-- Create a value of 'S3TableOutputOptions' 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:
--
-- 'location', 's3TableOutputOptions_location' - Represents an Amazon S3 location (bucket name and object key) where
-- DataBrew can write output from a job.
newS3TableOutputOptions ::
-- | 'location'
S3Location ->
S3TableOutputOptions
newS3TableOutputOptions pLocation_ =
S3TableOutputOptions' {location = pLocation_}
-- | Represents an Amazon S3 location (bucket name and object key) where
-- DataBrew can write output from a job.
s3TableOutputOptions_location :: Lens.Lens' S3TableOutputOptions S3Location
s3TableOutputOptions_location = Lens.lens (\S3TableOutputOptions' {location} -> location) (\s@S3TableOutputOptions' {} a -> s {location = a} :: S3TableOutputOptions)
instance Data.FromJSON S3TableOutputOptions where
parseJSON =
Data.withObject
"S3TableOutputOptions"
( \x ->
S3TableOutputOptions'
Prelude.<$> (x Data..: "Location")
)
instance Prelude.Hashable S3TableOutputOptions where
hashWithSalt _salt S3TableOutputOptions' {..} =
_salt `Prelude.hashWithSalt` location
instance Prelude.NFData S3TableOutputOptions where
rnf S3TableOutputOptions' {..} = Prelude.rnf location
instance Data.ToJSON S3TableOutputOptions where
toJSON S3TableOutputOptions' {..} =
Data.object
( Prelude.catMaybes
[Prelude.Just ("Location" Data..= location)]
)