module Stratosphere.IoTTwinMaker.Workspace (
        Workspace(..), mkWorkspace
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data Workspace
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html>
    Workspace {Workspace -> ()
haddock_workaround_ :: (),
               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html#cfn-iottwinmaker-workspace-description>
               Workspace -> Maybe (Value Text)
description :: (Prelude.Maybe (Value Prelude.Text)),
               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html#cfn-iottwinmaker-workspace-role>
               Workspace -> Value Text
role :: (Value Prelude.Text),
               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html#cfn-iottwinmaker-workspace-s3location>
               Workspace -> Value Text
s3Location :: (Value Prelude.Text),
               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html#cfn-iottwinmaker-workspace-tags>
               Workspace -> Maybe (Map Text (Value Text))
tags :: (Prelude.Maybe (Prelude.Map Prelude.Text (Value Prelude.Text))),
               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iottwinmaker-workspace.html#cfn-iottwinmaker-workspace-workspaceid>
               Workspace -> Value Text
workspaceId :: (Value Prelude.Text)}
  deriving stock (Workspace -> Workspace -> Bool
(Workspace -> Workspace -> Bool)
-> (Workspace -> Workspace -> Bool) -> Eq Workspace
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Workspace -> Workspace -> Bool
== :: Workspace -> Workspace -> Bool
$c/= :: Workspace -> Workspace -> Bool
/= :: Workspace -> Workspace -> Bool
Prelude.Eq, Int -> Workspace -> ShowS
[Workspace] -> ShowS
Workspace -> String
(Int -> Workspace -> ShowS)
-> (Workspace -> String)
-> ([Workspace] -> ShowS)
-> Show Workspace
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Workspace -> ShowS
showsPrec :: Int -> Workspace -> ShowS
$cshow :: Workspace -> String
show :: Workspace -> String
$cshowList :: [Workspace] -> ShowS
showList :: [Workspace] -> ShowS
Prelude.Show)
mkWorkspace ::
  Value Prelude.Text
  -> Value Prelude.Text -> Value Prelude.Text -> Workspace
mkWorkspace :: Value Text -> Value Text -> Value Text -> Workspace
mkWorkspace Value Text
role Value Text
s3Location Value Text
workspaceId
  = Workspace
      {haddock_workaround_ :: ()
haddock_workaround_ = (), role :: Value Text
role = Value Text
role, s3Location :: Value Text
s3Location = Value Text
s3Location,
       workspaceId :: Value Text
workspaceId = Value Text
workspaceId, description :: Maybe (Value Text)
description = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       tags :: Maybe (Map Text (Value Text))
tags = Maybe (Map Text (Value Text))
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties Workspace where
  toResourceProperties :: Workspace -> ResourceProperties
toResourceProperties Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::IoTTwinMaker::Workspace",
         supportsTags :: Bool
supportsTags = Bool
Prelude.True,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
                           [Key
"Role" 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..= Value Text
role, Key
"S3Location" 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..= Value Text
s3Location,
                            Key
"WorkspaceId" 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..= Value Text
workspaceId]
                           ([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
"Description" (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)
description,
                               Key -> Map Text (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
"Tags" (Map Text (Value Text) -> (Key, Value))
-> Maybe (Map Text (Value Text)) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Map Text (Value Text))
tags]))}
instance JSON.ToJSON Workspace where
  toJSON :: Workspace -> Value
toJSON Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
              [Key
"Role" 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..= Value Text
role, Key
"S3Location" 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..= Value Text
s3Location,
               Key
"WorkspaceId" 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..= Value Text
workspaceId]
              ([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
"Description" (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)
description,
                  Key -> Map Text (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
"Tags" (Map Text (Value Text) -> (Key, Value))
-> Maybe (Map Text (Value Text)) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Map Text (Value Text))
tags])))
instance Property "Description" Workspace where
  type PropertyType "Description" Workspace = Value Prelude.Text
  set :: PropertyType "Description" Workspace -> Workspace -> Workspace
set PropertyType "Description" Workspace
newValue Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
    = Workspace {description :: Maybe (Value Text)
description = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Description" Workspace
Value Text
newValue, Maybe (Map Text (Value Text))
()
Value Text
haddock_workaround_ :: ()
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
haddock_workaround_ :: ()
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
instance Property "Role" Workspace where
  type PropertyType "Role" Workspace = Value Prelude.Text
  set :: PropertyType "Role" Workspace -> Workspace -> Workspace
set PropertyType "Role" Workspace
newValue Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..} = Workspace {role :: Value Text
role = PropertyType "Role" Workspace
Value Text
newValue, Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
instance Property "S3Location" Workspace where
  type PropertyType "S3Location" Workspace = Value Prelude.Text
  set :: PropertyType "S3Location" Workspace -> Workspace -> Workspace
set PropertyType "S3Location" Workspace
newValue Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..} = Workspace {s3Location :: Value Text
s3Location = PropertyType "S3Location" Workspace
Value Text
newValue, Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
instance Property "Tags" Workspace where
  type PropertyType "Tags" Workspace = Prelude.Map Prelude.Text (Value Prelude.Text)
  set :: PropertyType "Tags" Workspace -> Workspace -> Workspace
set PropertyType "Tags" Workspace
newValue Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
    = Workspace {tags :: Maybe (Map Text (Value Text))
tags = Map Text (Value Text) -> Maybe (Map Text (Value Text))
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure Map Text (Value Text)
PropertyType "Tags" Workspace
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
workspaceId :: Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
workspaceId :: Value Text
..}
instance Property "WorkspaceId" Workspace where
  type PropertyType "WorkspaceId" Workspace = Value Prelude.Text
  set :: PropertyType "WorkspaceId" Workspace -> Workspace -> Workspace
set PropertyType "WorkspaceId" Workspace
newValue Workspace {Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Workspace -> ()
description :: Workspace -> Maybe (Value Text)
role :: Workspace -> Value Text
s3Location :: Workspace -> Value Text
tags :: Workspace -> Maybe (Map Text (Value Text))
workspaceId :: Workspace -> Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
workspaceId :: Value Text
..}
    = Workspace {workspaceId :: Value Text
workspaceId = PropertyType "WorkspaceId" Workspace
Value Text
newValue, Maybe (Map Text (Value Text))
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
description :: Maybe (Value Text)
role :: Value Text
s3Location :: Value Text
tags :: Maybe (Map Text (Value Text))
..}