/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace Glue { namespace Model { /** *

The structure used to create or update a database.

See Also:

* AWS * API Reference

*/ class DatabaseInput { public: AWS_GLUE_API DatabaseInput(); AWS_GLUE_API DatabaseInput(Aws::Utils::Json::JsonView jsonValue); AWS_GLUE_API DatabaseInput& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_GLUE_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline DatabaseInput& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline DatabaseInput& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

The name of the database. For Hive compatibility, this is folded to lowercase * when it is stored.

*/ inline DatabaseInput& WithName(const char* value) { SetName(value); return *this;} /** *

A description of the database.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

A description of the database.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

A description of the database.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

A description of the database.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

A description of the database.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

A description of the database.

*/ inline DatabaseInput& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

A description of the database.

*/ inline DatabaseInput& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

A description of the database.

*/ inline DatabaseInput& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

The location of the database (for example, an HDFS path).

*/ inline const Aws::String& GetLocationUri() const{ return m_locationUri; } /** *

The location of the database (for example, an HDFS path).

*/ inline bool LocationUriHasBeenSet() const { return m_locationUriHasBeenSet; } /** *

The location of the database (for example, an HDFS path).

*/ inline void SetLocationUri(const Aws::String& value) { m_locationUriHasBeenSet = true; m_locationUri = value; } /** *

The location of the database (for example, an HDFS path).

*/ inline void SetLocationUri(Aws::String&& value) { m_locationUriHasBeenSet = true; m_locationUri = std::move(value); } /** *

The location of the database (for example, an HDFS path).

*/ inline void SetLocationUri(const char* value) { m_locationUriHasBeenSet = true; m_locationUri.assign(value); } /** *

The location of the database (for example, an HDFS path).

*/ inline DatabaseInput& WithLocationUri(const Aws::String& value) { SetLocationUri(value); return *this;} /** *

The location of the database (for example, an HDFS path).

*/ inline DatabaseInput& WithLocationUri(Aws::String&& value) { SetLocationUri(std::move(value)); return *this;} /** *

The location of the database (for example, an HDFS path).

*/ inline DatabaseInput& WithLocationUri(const char* value) { SetLocationUri(value); return *this;} /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline const Aws::Map& GetParameters() const{ return m_parameters; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline bool ParametersHasBeenSet() const { return m_parametersHasBeenSet; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline void SetParameters(const Aws::Map& value) { m_parametersHasBeenSet = true; m_parameters = value; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline void SetParameters(Aws::Map&& value) { m_parametersHasBeenSet = true; m_parameters = std::move(value); } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& WithParameters(const Aws::Map& value) { SetParameters(value); return *this;} /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& WithParameters(Aws::Map&& value) { SetParameters(std::move(value)); return *this;} /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(const Aws::String& key, const Aws::String& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, value); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(Aws::String&& key, const Aws::String& value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), value); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(const Aws::String& key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, std::move(value)); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(Aws::String&& key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), std::move(value)); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(const char* key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, std::move(value)); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(Aws::String&& key, const char* value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), value); return *this; } /** *

These key-value pairs define parameters and properties of the database.

*

These key-value pairs define parameters and properties of the database.

*/ inline DatabaseInput& AddParameters(const char* key, const char* value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, value); return *this; } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline const Aws::Vector& GetCreateTableDefaultPermissions() const{ return m_createTableDefaultPermissions; } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline bool CreateTableDefaultPermissionsHasBeenSet() const { return m_createTableDefaultPermissionsHasBeenSet; } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline void SetCreateTableDefaultPermissions(const Aws::Vector& value) { m_createTableDefaultPermissionsHasBeenSet = true; m_createTableDefaultPermissions = value; } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline void SetCreateTableDefaultPermissions(Aws::Vector&& value) { m_createTableDefaultPermissionsHasBeenSet = true; m_createTableDefaultPermissions = std::move(value); } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline DatabaseInput& WithCreateTableDefaultPermissions(const Aws::Vector& value) { SetCreateTableDefaultPermissions(value); return *this;} /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline DatabaseInput& WithCreateTableDefaultPermissions(Aws::Vector&& value) { SetCreateTableDefaultPermissions(std::move(value)); return *this;} /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline DatabaseInput& AddCreateTableDefaultPermissions(const PrincipalPermissions& value) { m_createTableDefaultPermissionsHasBeenSet = true; m_createTableDefaultPermissions.push_back(value); return *this; } /** *

Creates a set of default permissions on the table for principals. Used by * Lake Formation. Not used in the normal course of Glue operations.

*/ inline DatabaseInput& AddCreateTableDefaultPermissions(PrincipalPermissions&& value) { m_createTableDefaultPermissionsHasBeenSet = true; m_createTableDefaultPermissions.push_back(std::move(value)); return *this; } /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline const DatabaseIdentifier& GetTargetDatabase() const{ return m_targetDatabase; } /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline bool TargetDatabaseHasBeenSet() const { return m_targetDatabaseHasBeenSet; } /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline void SetTargetDatabase(const DatabaseIdentifier& value) { m_targetDatabaseHasBeenSet = true; m_targetDatabase = value; } /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline void SetTargetDatabase(DatabaseIdentifier&& value) { m_targetDatabaseHasBeenSet = true; m_targetDatabase = std::move(value); } /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline DatabaseInput& WithTargetDatabase(const DatabaseIdentifier& value) { SetTargetDatabase(value); return *this;} /** *

A DatabaseIdentifier structure that describes a target database * for resource linking.

*/ inline DatabaseInput& WithTargetDatabase(DatabaseIdentifier&& value) { SetTargetDatabase(std::move(value)); return *this;} /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline const FederatedDatabase& GetFederatedDatabase() const{ return m_federatedDatabase; } /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline bool FederatedDatabaseHasBeenSet() const { return m_federatedDatabaseHasBeenSet; } /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline void SetFederatedDatabase(const FederatedDatabase& value) { m_federatedDatabaseHasBeenSet = true; m_federatedDatabase = value; } /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline void SetFederatedDatabase(FederatedDatabase&& value) { m_federatedDatabaseHasBeenSet = true; m_federatedDatabase = std::move(value); } /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline DatabaseInput& WithFederatedDatabase(const FederatedDatabase& value) { SetFederatedDatabase(value); return *this;} /** *

A FederatedDatabase structure that references an entity outside * the Glue Data Catalog.

*/ inline DatabaseInput& WithFederatedDatabase(FederatedDatabase&& value) { SetFederatedDatabase(std::move(value)); return *this;} private: Aws::String m_name; bool m_nameHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::String m_locationUri; bool m_locationUriHasBeenSet = false; Aws::Map m_parameters; bool m_parametersHasBeenSet = false; Aws::Vector m_createTableDefaultPermissions; bool m_createTableDefaultPermissionsHasBeenSet = false; DatabaseIdentifier m_targetDatabase; bool m_targetDatabaseHasBeenSet = false; FederatedDatabase m_federatedDatabase; bool m_federatedDatabaseHasBeenSet = false; }; } // namespace Model } // namespace Glue } // namespace Aws