module Stratosphere.Forecast.DatasetGroup ( DatasetGroup(..), mkDatasetGroup ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import Stratosphere.ResourceProperties import Stratosphere.Tag import Stratosphere.Value data DatasetGroup = -- | See: DatasetGroup {haddock_workaround_ :: (), -- | See: datasetArns :: (Prelude.Maybe (ValueList Prelude.Text)), -- | See: datasetGroupName :: (Value Prelude.Text), -- | See: domain :: (Value Prelude.Text), -- | See: tags :: (Prelude.Maybe [Tag])} deriving stock (Prelude.Eq, Prelude.Show) mkDatasetGroup :: Value Prelude.Text -> Value Prelude.Text -> DatasetGroup mkDatasetGroup datasetGroupName domain = DatasetGroup {haddock_workaround_ = (), datasetGroupName = datasetGroupName, domain = domain, datasetArns = Prelude.Nothing, tags = Prelude.Nothing} instance ToResourceProperties DatasetGroup where toResourceProperties DatasetGroup {..} = ResourceProperties {awsType = "AWS::Forecast::DatasetGroup", supportsTags = Prelude.True, properties = Prelude.fromList ((Prelude.<>) ["DatasetGroupName" JSON..= datasetGroupName, "Domain" JSON..= domain] (Prelude.catMaybes [(JSON..=) "DatasetArns" Prelude.<$> datasetArns, (JSON..=) "Tags" Prelude.<$> tags]))} instance JSON.ToJSON DatasetGroup where toJSON DatasetGroup {..} = JSON.object (Prelude.fromList ((Prelude.<>) ["DatasetGroupName" JSON..= datasetGroupName, "Domain" JSON..= domain] (Prelude.catMaybes [(JSON..=) "DatasetArns" Prelude.<$> datasetArns, (JSON..=) "Tags" Prelude.<$> tags]))) instance Property "DatasetArns" DatasetGroup where type PropertyType "DatasetArns" DatasetGroup = ValueList Prelude.Text set newValue DatasetGroup {..} = DatasetGroup {datasetArns = Prelude.pure newValue, ..} instance Property "DatasetGroupName" DatasetGroup where type PropertyType "DatasetGroupName" DatasetGroup = Value Prelude.Text set newValue DatasetGroup {..} = DatasetGroup {datasetGroupName = newValue, ..} instance Property "Domain" DatasetGroup where type PropertyType "Domain" DatasetGroup = Value Prelude.Text set newValue DatasetGroup {..} = DatasetGroup {domain = newValue, ..} instance Property "Tags" DatasetGroup where type PropertyType "Tags" DatasetGroup = [Tag] set newValue DatasetGroup {..} = DatasetGroup {tags = Prelude.pure newValue, ..}