module Stratosphere.BedrockAgentCore.GatewayTarget.S3ConfigurationProperty (
        S3ConfigurationProperty(..), mkS3ConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data S3ConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrockagentcore-gatewaytarget-s3configuration.html>
    S3ConfigurationProperty {S3ConfigurationProperty -> ()
haddock_workaround_ :: (),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrockagentcore-gatewaytarget-s3configuration.html#cfn-bedrockagentcore-gatewaytarget-s3configuration-bucketowneraccountid>
                             S3ConfigurationProperty -> Maybe (Value Text)
bucketOwnerAccountId :: (Prelude.Maybe (Value Prelude.Text)),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrockagentcore-gatewaytarget-s3configuration.html#cfn-bedrockagentcore-gatewaytarget-s3configuration-uri>
                             S3ConfigurationProperty -> Maybe (Value Text)
uri :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (S3ConfigurationProperty -> S3ConfigurationProperty -> Bool
(S3ConfigurationProperty -> S3ConfigurationProperty -> Bool)
-> (S3ConfigurationProperty -> S3ConfigurationProperty -> Bool)
-> Eq S3ConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: S3ConfigurationProperty -> S3ConfigurationProperty -> Bool
== :: S3ConfigurationProperty -> S3ConfigurationProperty -> Bool
$c/= :: S3ConfigurationProperty -> S3ConfigurationProperty -> Bool
/= :: S3ConfigurationProperty -> S3ConfigurationProperty -> Bool
Prelude.Eq, Int -> S3ConfigurationProperty -> ShowS
[S3ConfigurationProperty] -> ShowS
S3ConfigurationProperty -> String
(Int -> S3ConfigurationProperty -> ShowS)
-> (S3ConfigurationProperty -> String)
-> ([S3ConfigurationProperty] -> ShowS)
-> Show S3ConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> S3ConfigurationProperty -> ShowS
showsPrec :: Int -> S3ConfigurationProperty -> ShowS
$cshow :: S3ConfigurationProperty -> String
show :: S3ConfigurationProperty -> String
$cshowList :: [S3ConfigurationProperty] -> ShowS
showList :: [S3ConfigurationProperty] -> ShowS
Prelude.Show)
mkS3ConfigurationProperty :: S3ConfigurationProperty
mkS3ConfigurationProperty :: S3ConfigurationProperty
mkS3ConfigurationProperty
  = S3ConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), bucketOwnerAccountId :: Maybe (Value Text)
bucketOwnerAccountId = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       uri :: Maybe (Value Text)
uri = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties S3ConfigurationProperty where
  toResourceProperties :: S3ConfigurationProperty -> ResourceProperties
toResourceProperties S3ConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: S3ConfigurationProperty -> ()
bucketOwnerAccountId :: S3ConfigurationProperty -> Maybe (Value Text)
uri :: S3ConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
uri :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::BedrockAgentCore::GatewayTarget.S3Configuration",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                           [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BucketOwnerAccountId" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
bucketOwnerAccountId,
                            Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Uri" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
uri])}
instance JSON.ToJSON S3ConfigurationProperty where
  toJSON :: S3ConfigurationProperty -> Value
toJSON S3ConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: S3ConfigurationProperty -> ()
bucketOwnerAccountId :: S3ConfigurationProperty -> Maybe (Value Text)
uri :: S3ConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
uri :: Maybe (Value Text)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
              [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BucketOwnerAccountId" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
bucketOwnerAccountId,
               Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Uri" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
uri]))
instance Property "BucketOwnerAccountId" S3ConfigurationProperty where
  type PropertyType "BucketOwnerAccountId" S3ConfigurationProperty = Value Prelude.Text
  set :: PropertyType "BucketOwnerAccountId" S3ConfigurationProperty
-> S3ConfigurationProperty -> S3ConfigurationProperty
set PropertyType "BucketOwnerAccountId" S3ConfigurationProperty
newValue S3ConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: S3ConfigurationProperty -> ()
bucketOwnerAccountId :: S3ConfigurationProperty -> Maybe (Value Text)
uri :: S3ConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
uri :: Maybe (Value Text)
..}
    = S3ConfigurationProperty
        {bucketOwnerAccountId :: Maybe (Value Text)
bucketOwnerAccountId = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "BucketOwnerAccountId" S3ConfigurationProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
uri :: Maybe (Value Text)
haddock_workaround_ :: ()
uri :: Maybe (Value Text)
..}
instance Property "Uri" S3ConfigurationProperty where
  type PropertyType "Uri" S3ConfigurationProperty = Value Prelude.Text
  set :: PropertyType "Uri" S3ConfigurationProperty
-> S3ConfigurationProperty -> S3ConfigurationProperty
set PropertyType "Uri" S3ConfigurationProperty
newValue S3ConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: S3ConfigurationProperty -> ()
bucketOwnerAccountId :: S3ConfigurationProperty -> Maybe (Value Text)
uri :: S3ConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
uri :: Maybe (Value Text)
..}
    = S3ConfigurationProperty {uri :: Maybe (Value Text)
uri = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Uri" S3ConfigurationProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
haddock_workaround_ :: ()
bucketOwnerAccountId :: Maybe (Value Text)
..}