/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include
#include
#include
#include
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace OpsWorks
{
namespace Model
{
/**
* AWS OpsWorks Stacks supports five lifecycle events: setup,
* configuration, deploy, undeploy, and shutdown. For
* each layer, AWS OpsWorks Stacks runs a set of standard recipes for each event.
* In addition, you can provide custom recipes for any or all layers and events.
* AWS OpsWorks Stacks runs custom event recipes after the standard recipes.
* LayerCustomRecipes
specifies the custom recipes for a particular
* layer to be run in response to each of the five events.
To specify a
* recipe, use the cookbook's directory name in the repository followed by two
* colons and the recipe name, which is the recipe's file name without the .rb
* extension. For example: phpapp2::dbsetup specifies the dbsetup.rb recipe in the
* repository's phpapp2 folder.
See Also:
AWS
* API Reference
*/
class Recipes
{
public:
AWS_OPSWORKS_API Recipes();
AWS_OPSWORKS_API Recipes(Aws::Utils::Json::JsonView jsonValue);
AWS_OPSWORKS_API Recipes& operator=(Aws::Utils::Json::JsonView jsonValue);
AWS_OPSWORKS_API Aws::Utils::Json::JsonValue Jsonize() const;
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline const Aws::Vector& GetSetup() const{ return m_setup; }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline bool SetupHasBeenSet() const { return m_setupHasBeenSet; }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline void SetSetup(const Aws::Vector& value) { m_setupHasBeenSet = true; m_setup = value; }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline void SetSetup(Aws::Vector&& value) { m_setupHasBeenSet = true; m_setup = std::move(value); }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline Recipes& WithSetup(const Aws::Vector& value) { SetSetup(value); return *this;}
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline Recipes& WithSetup(Aws::Vector&& value) { SetSetup(std::move(value)); return *this;}
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline Recipes& AddSetup(const Aws::String& value) { m_setupHasBeenSet = true; m_setup.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline Recipes& AddSetup(Aws::String&& value) { m_setupHasBeenSet = true; m_setup.push_back(std::move(value)); return *this; }
/**
* An array of custom recipe names to be run following a setup
* event.
*/
inline Recipes& AddSetup(const char* value) { m_setupHasBeenSet = true; m_setup.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline const Aws::Vector& GetConfigure() const{ return m_configure; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline bool ConfigureHasBeenSet() const { return m_configureHasBeenSet; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline void SetConfigure(const Aws::Vector& value) { m_configureHasBeenSet = true; m_configure = value; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline void SetConfigure(Aws::Vector&& value) { m_configureHasBeenSet = true; m_configure = std::move(value); }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline Recipes& WithConfigure(const Aws::Vector& value) { SetConfigure(value); return *this;}
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline Recipes& WithConfigure(Aws::Vector&& value) { SetConfigure(std::move(value)); return *this;}
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline Recipes& AddConfigure(const Aws::String& value) { m_configureHasBeenSet = true; m_configure.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline Recipes& AddConfigure(Aws::String&& value) { m_configureHasBeenSet = true; m_configure.push_back(std::move(value)); return *this; }
/**
* An array of custom recipe names to be run following a configure
* event.
*/
inline Recipes& AddConfigure(const char* value) { m_configureHasBeenSet = true; m_configure.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline const Aws::Vector& GetDeploy() const{ return m_deploy; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline bool DeployHasBeenSet() const { return m_deployHasBeenSet; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline void SetDeploy(const Aws::Vector& value) { m_deployHasBeenSet = true; m_deploy = value; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline void SetDeploy(Aws::Vector&& value) { m_deployHasBeenSet = true; m_deploy = std::move(value); }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline Recipes& WithDeploy(const Aws::Vector& value) { SetDeploy(value); return *this;}
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline Recipes& WithDeploy(Aws::Vector&& value) { SetDeploy(std::move(value)); return *this;}
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline Recipes& AddDeploy(const Aws::String& value) { m_deployHasBeenSet = true; m_deploy.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline Recipes& AddDeploy(Aws::String&& value) { m_deployHasBeenSet = true; m_deploy.push_back(std::move(value)); return *this; }
/**
* An array of custom recipe names to be run following a deploy
* event.
*/
inline Recipes& AddDeploy(const char* value) { m_deployHasBeenSet = true; m_deploy.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline const Aws::Vector& GetUndeploy() const{ return m_undeploy; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline bool UndeployHasBeenSet() const { return m_undeployHasBeenSet; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline void SetUndeploy(const Aws::Vector& value) { m_undeployHasBeenSet = true; m_undeploy = value; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline void SetUndeploy(Aws::Vector&& value) { m_undeployHasBeenSet = true; m_undeploy = std::move(value); }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline Recipes& WithUndeploy(const Aws::Vector& value) { SetUndeploy(value); return *this;}
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline Recipes& WithUndeploy(Aws::Vector&& value) { SetUndeploy(std::move(value)); return *this;}
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline Recipes& AddUndeploy(const Aws::String& value) { m_undeployHasBeenSet = true; m_undeploy.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline Recipes& AddUndeploy(Aws::String&& value) { m_undeployHasBeenSet = true; m_undeploy.push_back(std::move(value)); return *this; }
/**
* An array of custom recipe names to be run following a undeploy
* event.
*/
inline Recipes& AddUndeploy(const char* value) { m_undeployHasBeenSet = true; m_undeploy.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline const Aws::Vector& GetShutdown() const{ return m_shutdown; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline bool ShutdownHasBeenSet() const { return m_shutdownHasBeenSet; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline void SetShutdown(const Aws::Vector& value) { m_shutdownHasBeenSet = true; m_shutdown = value; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline void SetShutdown(Aws::Vector&& value) { m_shutdownHasBeenSet = true; m_shutdown = std::move(value); }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline Recipes& WithShutdown(const Aws::Vector& value) { SetShutdown(value); return *this;}
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline Recipes& WithShutdown(Aws::Vector&& value) { SetShutdown(std::move(value)); return *this;}
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline Recipes& AddShutdown(const Aws::String& value) { m_shutdownHasBeenSet = true; m_shutdown.push_back(value); return *this; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline Recipes& AddShutdown(Aws::String&& value) { m_shutdownHasBeenSet = true; m_shutdown.push_back(std::move(value)); return *this; }
/**
* An array of custom recipe names to be run following a shutdown
* event.
*/
inline Recipes& AddShutdown(const char* value) { m_shutdownHasBeenSet = true; m_shutdown.push_back(value); return *this; }
private:
Aws::Vector m_setup;
bool m_setupHasBeenSet = false;
Aws::Vector m_configure;
bool m_configureHasBeenSet = false;
Aws::Vector m_deploy;
bool m_deployHasBeenSet = false;
Aws::Vector m_undeploy;
bool m_undeployHasBeenSet = false;
Aws::Vector m_shutdown;
bool m_shutdownHasBeenSet = false;
};
} // namespace Model
} // namespace OpsWorks
} // namespace Aws