module Stratosphere.CloudFront.KeyGroup.KeyGroupConfigProperty ( KeyGroupConfigProperty(..), mkKeyGroupConfigProperty ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import Stratosphere.ResourceProperties import Stratosphere.Value data KeyGroupConfigProperty = -- | See: KeyGroupConfigProperty {haddock_workaround_ :: (), -- | See: comment :: (Prelude.Maybe (Value Prelude.Text)), -- | See: items :: (ValueList Prelude.Text), -- | See: name :: (Value Prelude.Text)} deriving stock (Prelude.Eq, Prelude.Show) mkKeyGroupConfigProperty :: ValueList Prelude.Text -> Value Prelude.Text -> KeyGroupConfigProperty mkKeyGroupConfigProperty items name = KeyGroupConfigProperty {haddock_workaround_ = (), items = items, name = name, comment = Prelude.Nothing} instance ToResourceProperties KeyGroupConfigProperty where toResourceProperties KeyGroupConfigProperty {..} = ResourceProperties {awsType = "AWS::CloudFront::KeyGroup.KeyGroupConfig", supportsTags = Prelude.False, properties = Prelude.fromList ((Prelude.<>) ["Items" JSON..= items, "Name" JSON..= name] (Prelude.catMaybes [(JSON..=) "Comment" Prelude.<$> comment]))} instance JSON.ToJSON KeyGroupConfigProperty where toJSON KeyGroupConfigProperty {..} = JSON.object (Prelude.fromList ((Prelude.<>) ["Items" JSON..= items, "Name" JSON..= name] (Prelude.catMaybes [(JSON..=) "Comment" Prelude.<$> comment]))) instance Property "Comment" KeyGroupConfigProperty where type PropertyType "Comment" KeyGroupConfigProperty = Value Prelude.Text set newValue KeyGroupConfigProperty {..} = KeyGroupConfigProperty {comment = Prelude.pure newValue, ..} instance Property "Items" KeyGroupConfigProperty where type PropertyType "Items" KeyGroupConfigProperty = ValueList Prelude.Text set newValue KeyGroupConfigProperty {..} = KeyGroupConfigProperty {items = newValue, ..} instance Property "Name" KeyGroupConfigProperty where type PropertyType "Name" KeyGroupConfigProperty = Value Prelude.Text set newValue KeyGroupConfigProperty {..} = KeyGroupConfigProperty {name = newValue, ..}