content: module Stratosphere.Deadline.Queue (
          module Exports, Queue(..), mkQueue
      ) where
  import qualified Data.Aeson as JSON
  import qualified Stratosphere.Prelude as Prelude
  import Stratosphere.Property
  import {-# SOURCE #-} Stratosphere.Deadline.Queue.JobAttachmentSettingsProperty as Exports
  import {-# SOURCE #-} Stratosphere.Deadline.Queue.JobRunAsUserProperty as Exports
  import Stratosphere.ResourceProperties
  import Stratosphere.Tag
  import Stratosphere.Value
  data Queue
    = Queue {allowedStorageProfileIds :: (Prelude.Maybe (ValueList Prelude.Text)),
             defaultBudgetAction :: (Prelude.Maybe (Value Prelude.Text)),
             description :: (Prelude.Maybe (Value Prelude.Text)),
             displayName :: (Value Prelude.Text),
             farmId :: (Value Prelude.Text),
             jobAttachmentSettings :: (Prelude.Maybe JobAttachmentSettingsProperty),
             jobRunAsUser :: (Prelude.Maybe JobRunAsUserProperty),
             requiredFileSystemLocationNames :: (Prelude.Maybe (ValueList Prelude.Text)),
             roleArn :: (Prelude.Maybe (Value Prelude.Text)),
             tags :: (Prelude.Maybe [Tag])}
    deriving stock (Prelude.Eq, Prelude.Show)
  mkQueue :: Value Prelude.Text -> Value Prelude.Text -> Queue
  mkQueue displayName farmId
    = Queue
        {displayName = displayName, farmId = farmId,
         allowedStorageProfileIds = Prelude.Nothing,
         defaultBudgetAction = Prelude.Nothing,
         description = Prelude.Nothing,
         jobAttachmentSettings = Prelude.Nothing,
         jobRunAsUser = Prelude.Nothing,
         requiredFileSystemLocationNames = Prelude.Nothing,
         roleArn = Prelude.Nothing, tags = Prelude.Nothing}
  instance ToResourceProperties Queue where
    toResourceProperties Queue {..}
      = ResourceProperties
          {awsType = "AWS::Deadline::Queue", supportsTags = Prelude.True,
           properties = Prelude.fromList
                          ((Prelude.<>)
                             ["DisplayName" JSON..= displayName, "FarmId" JSON..= farmId]
                             (Prelude.catMaybes
                                [(JSON..=) "AllowedStorageProfileIds"
                                   Prelude.<$> allowedStorageProfileIds,
                                 (JSON..=) "DefaultBudgetAction" Prelude.<$> defaultBudgetAction,
                                 (JSON..=) "Description" Prelude.<$> description,
                                 (JSON..=) "JobAttachmentSettings"
                                   Prelude.<$> jobAttachmentSettings,
                                 (JSON..=) "JobRunAsUser" Prelude.<$> jobRunAsUser,
                                 (JSON..=) "RequiredFileSystemLocationNames"
                                   Prelude.<$> requiredFileSystemLocationNames,
                                 (JSON..=) "RoleArn" Prelude.<$> roleArn,
                                 (JSON..=) "Tags" Prelude.<$> tags]))}
  instance JSON.ToJSON Queue where
    toJSON Queue {..}
      = JSON.object
          (Prelude.fromList
             ((Prelude.<>)
                ["DisplayName" JSON..= displayName, "FarmId" JSON..= farmId]
                (Prelude.catMaybes
                   [(JSON..=) "AllowedStorageProfileIds"
                      Prelude.<$> allowedStorageProfileIds,
                    (JSON..=) "DefaultBudgetAction" Prelude.<$> defaultBudgetAction,
                    (JSON..=) "Description" Prelude.<$> description,
                    (JSON..=) "JobAttachmentSettings"
                      Prelude.<$> jobAttachmentSettings,
                    (JSON..=) "JobRunAsUser" Prelude.<$> jobRunAsUser,
                    (JSON..=) "RequiredFileSystemLocationNames"
                      Prelude.<$> requiredFileSystemLocationNames,
                    (JSON..=) "RoleArn" Prelude.<$> roleArn,
                    (JSON..=) "Tags" Prelude.<$> tags])))
  instance Property "AllowedStorageProfileIds" Queue where
    type PropertyType "AllowedStorageProfileIds" Queue = ValueList Prelude.Text
    set newValue Queue {..}
      = Queue {allowedStorageProfileIds = Prelude.pure newValue, ..}
  instance Property "DefaultBudgetAction" Queue where
    type PropertyType "DefaultBudgetAction" Queue = Value Prelude.Text
    set newValue Queue {..}
      = Queue {defaultBudgetAction = Prelude.pure newValue, ..}
  instance Property "Description" Queue where
    type PropertyType "Description" Queue = Value Prelude.Text
    set newValue Queue {..}
      = Queue {description = Prelude.pure newValue, ..}
  instance Property "DisplayName" Queue where
    type PropertyType "DisplayName" Queue = Value Prelude.Text
    set newValue Queue {..} = Queue {displayName = newValue, ..}
  instance Property "FarmId" Queue where
    type PropertyType "FarmId" Queue = Value Prelude.Text
    set newValue Queue {..} = Queue {farmId = newValue, ..}
  instance Property "JobAttachmentSettings" Queue where
    type PropertyType "JobAttachmentSettings" Queue = JobAttachmentSettingsProperty
    set newValue Queue {..}
      = Queue {jobAttachmentSettings = Prelude.pure newValue, ..}
  instance Property "JobRunAsUser" Queue where
    type PropertyType "JobRunAsUser" Queue = JobRunAsUserProperty
    set newValue Queue {..}
      = Queue {jobRunAsUser = Prelude.pure newValue, ..}
  instance Property "RequiredFileSystemLocationNames" Queue where
    type PropertyType "RequiredFileSystemLocationNames" Queue = ValueList Prelude.Text
    set newValue Queue {..}
      = Queue
          {requiredFileSystemLocationNames = Prelude.pure newValue, ..}
  instance Property "RoleArn" Queue where
    type PropertyType "RoleArn" Queue = Value Prelude.Text
    set newValue Queue {..}
      = Queue {roleArn = Prelude.pure newValue, ..}
  instance Property "Tags" Queue where
    type PropertyType "Tags" Queue = [Tag]
    set newValue Queue {..} = Queue {tags = Prelude.pure newValue, ..}