1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/glue/Glue_EXPORTS.h> 8 #include <aws/glue/GlueRequest.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <aws/glue/model/Segment.h> 11 #include <utility> 12 13 namespace Aws 14 { 15 namespace Glue 16 { 17 namespace Model 18 { 19 20 /** 21 */ 22 class AWS_GLUE_API GetPartitionsRequest : public GlueRequest 23 { 24 public: 25 GetPartitionsRequest(); 26 27 // Service request name is the Operation name which will send this request out, 28 // each operation should has unique request name, so that we can get operation's name from this request. 29 // Note: this is not true for response, multiple operations may have the same response name, 30 // so we can not get operation's name from response. GetServiceRequestName()31 inline virtual const char* GetServiceRequestName() const override { return "GetPartitions"; } 32 33 Aws::String SerializePayload() const override; 34 35 Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; 36 37 38 /** 39 * <p>The ID of the Data Catalog where the partitions in question reside. If none 40 * is provided, the Amazon Web Services account ID is used by default.</p> 41 */ GetCatalogId()42 inline const Aws::String& GetCatalogId() const{ return m_catalogId; } 43 44 /** 45 * <p>The ID of the Data Catalog where the partitions in question reside. If none 46 * is provided, the Amazon Web Services account ID is used by default.</p> 47 */ CatalogIdHasBeenSet()48 inline bool CatalogIdHasBeenSet() const { return m_catalogIdHasBeenSet; } 49 50 /** 51 * <p>The ID of the Data Catalog where the partitions in question reside. If none 52 * is provided, the Amazon Web Services account ID is used by default.</p> 53 */ SetCatalogId(const Aws::String & value)54 inline void SetCatalogId(const Aws::String& value) { m_catalogIdHasBeenSet = true; m_catalogId = value; } 55 56 /** 57 * <p>The ID of the Data Catalog where the partitions in question reside. If none 58 * is provided, the Amazon Web Services account ID is used by default.</p> 59 */ SetCatalogId(Aws::String && value)60 inline void SetCatalogId(Aws::String&& value) { m_catalogIdHasBeenSet = true; m_catalogId = std::move(value); } 61 62 /** 63 * <p>The ID of the Data Catalog where the partitions in question reside. If none 64 * is provided, the Amazon Web Services account ID is used by default.</p> 65 */ SetCatalogId(const char * value)66 inline void SetCatalogId(const char* value) { m_catalogIdHasBeenSet = true; m_catalogId.assign(value); } 67 68 /** 69 * <p>The ID of the Data Catalog where the partitions in question reside. If none 70 * is provided, the Amazon Web Services account ID is used by default.</p> 71 */ WithCatalogId(const Aws::String & value)72 inline GetPartitionsRequest& WithCatalogId(const Aws::String& value) { SetCatalogId(value); return *this;} 73 74 /** 75 * <p>The ID of the Data Catalog where the partitions in question reside. If none 76 * is provided, the Amazon Web Services account ID is used by default.</p> 77 */ WithCatalogId(Aws::String && value)78 inline GetPartitionsRequest& WithCatalogId(Aws::String&& value) { SetCatalogId(std::move(value)); return *this;} 79 80 /** 81 * <p>The ID of the Data Catalog where the partitions in question reside. If none 82 * is provided, the Amazon Web Services account ID is used by default.</p> 83 */ WithCatalogId(const char * value)84 inline GetPartitionsRequest& WithCatalogId(const char* value) { SetCatalogId(value); return *this;} 85 86 87 /** 88 * <p>The name of the catalog database where the partitions reside.</p> 89 */ GetDatabaseName()90 inline const Aws::String& GetDatabaseName() const{ return m_databaseName; } 91 92 /** 93 * <p>The name of the catalog database where the partitions reside.</p> 94 */ DatabaseNameHasBeenSet()95 inline bool DatabaseNameHasBeenSet() const { return m_databaseNameHasBeenSet; } 96 97 /** 98 * <p>The name of the catalog database where the partitions reside.</p> 99 */ SetDatabaseName(const Aws::String & value)100 inline void SetDatabaseName(const Aws::String& value) { m_databaseNameHasBeenSet = true; m_databaseName = value; } 101 102 /** 103 * <p>The name of the catalog database where the partitions reside.</p> 104 */ SetDatabaseName(Aws::String && value)105 inline void SetDatabaseName(Aws::String&& value) { m_databaseNameHasBeenSet = true; m_databaseName = std::move(value); } 106 107 /** 108 * <p>The name of the catalog database where the partitions reside.</p> 109 */ SetDatabaseName(const char * value)110 inline void SetDatabaseName(const char* value) { m_databaseNameHasBeenSet = true; m_databaseName.assign(value); } 111 112 /** 113 * <p>The name of the catalog database where the partitions reside.</p> 114 */ WithDatabaseName(const Aws::String & value)115 inline GetPartitionsRequest& WithDatabaseName(const Aws::String& value) { SetDatabaseName(value); return *this;} 116 117 /** 118 * <p>The name of the catalog database where the partitions reside.</p> 119 */ WithDatabaseName(Aws::String && value)120 inline GetPartitionsRequest& WithDatabaseName(Aws::String&& value) { SetDatabaseName(std::move(value)); return *this;} 121 122 /** 123 * <p>The name of the catalog database where the partitions reside.</p> 124 */ WithDatabaseName(const char * value)125 inline GetPartitionsRequest& WithDatabaseName(const char* value) { SetDatabaseName(value); return *this;} 126 127 128 /** 129 * <p>The name of the partitions' table.</p> 130 */ GetTableName()131 inline const Aws::String& GetTableName() const{ return m_tableName; } 132 133 /** 134 * <p>The name of the partitions' table.</p> 135 */ TableNameHasBeenSet()136 inline bool TableNameHasBeenSet() const { return m_tableNameHasBeenSet; } 137 138 /** 139 * <p>The name of the partitions' table.</p> 140 */ SetTableName(const Aws::String & value)141 inline void SetTableName(const Aws::String& value) { m_tableNameHasBeenSet = true; m_tableName = value; } 142 143 /** 144 * <p>The name of the partitions' table.</p> 145 */ SetTableName(Aws::String && value)146 inline void SetTableName(Aws::String&& value) { m_tableNameHasBeenSet = true; m_tableName = std::move(value); } 147 148 /** 149 * <p>The name of the partitions' table.</p> 150 */ SetTableName(const char * value)151 inline void SetTableName(const char* value) { m_tableNameHasBeenSet = true; m_tableName.assign(value); } 152 153 /** 154 * <p>The name of the partitions' table.</p> 155 */ WithTableName(const Aws::String & value)156 inline GetPartitionsRequest& WithTableName(const Aws::String& value) { SetTableName(value); return *this;} 157 158 /** 159 * <p>The name of the partitions' table.</p> 160 */ WithTableName(Aws::String && value)161 inline GetPartitionsRequest& WithTableName(Aws::String&& value) { SetTableName(std::move(value)); return *this;} 162 163 /** 164 * <p>The name of the partitions' table.</p> 165 */ WithTableName(const char * value)166 inline GetPartitionsRequest& WithTableName(const char* value) { SetTableName(value); return *this;} 167 168 169 /** 170 * <p>An expression that filters the partitions to be returned.</p> <p>The 171 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 172 * The SQL statement parser <a 173 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 174 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 175 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 176 * <p>Checks whether the values of the two operands are equal; if yes, then the 177 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 178 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 179 * <dd> <p>Checks whether the values of two operands are equal; if the values are 180 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 181 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 182 * operand is greater than the value of the right operand; if yes, then the 183 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 184 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 185 * the value of the right operand; if yes, then the condition becomes true.</p> 186 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 187 * the value of the left operand is greater than or equal to the value of the right 188 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 189 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 190 * operand is less than or equal to the value of the right operand; if yes, then 191 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 192 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 193 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 194 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 195 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 196 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 197 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 198 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 199 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 200 * <p>The following list shows the valid operators on each type. When you define a 201 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 202 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 203 * </p> 204 */ GetExpression()205 inline const Aws::String& GetExpression() const{ return m_expression; } 206 207 /** 208 * <p>An expression that filters the partitions to be returned.</p> <p>The 209 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 210 * The SQL statement parser <a 211 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 212 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 213 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 214 * <p>Checks whether the values of the two operands are equal; if yes, then the 215 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 216 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 217 * <dd> <p>Checks whether the values of two operands are equal; if the values are 218 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 219 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 220 * operand is greater than the value of the right operand; if yes, then the 221 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 222 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 223 * the value of the right operand; if yes, then the condition becomes true.</p> 224 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 225 * the value of the left operand is greater than or equal to the value of the right 226 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 227 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 228 * operand is less than or equal to the value of the right operand; if yes, then 229 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 230 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 231 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 232 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 233 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 234 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 235 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 236 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 237 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 238 * <p>The following list shows the valid operators on each type. When you define a 239 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 240 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 241 * </p> 242 */ ExpressionHasBeenSet()243 inline bool ExpressionHasBeenSet() const { return m_expressionHasBeenSet; } 244 245 /** 246 * <p>An expression that filters the partitions to be returned.</p> <p>The 247 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 248 * The SQL statement parser <a 249 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 250 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 251 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 252 * <p>Checks whether the values of the two operands are equal; if yes, then the 253 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 254 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 255 * <dd> <p>Checks whether the values of two operands are equal; if the values are 256 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 257 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 258 * operand is greater than the value of the right operand; if yes, then the 259 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 260 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 261 * the value of the right operand; if yes, then the condition becomes true.</p> 262 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 263 * the value of the left operand is greater than or equal to the value of the right 264 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 265 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 266 * operand is less than or equal to the value of the right operand; if yes, then 267 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 268 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 269 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 270 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 271 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 272 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 273 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 274 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 275 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 276 * <p>The following list shows the valid operators on each type. When you define a 277 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 278 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 279 * </p> 280 */ SetExpression(const Aws::String & value)281 inline void SetExpression(const Aws::String& value) { m_expressionHasBeenSet = true; m_expression = value; } 282 283 /** 284 * <p>An expression that filters the partitions to be returned.</p> <p>The 285 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 286 * The SQL statement parser <a 287 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 288 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 289 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 290 * <p>Checks whether the values of the two operands are equal; if yes, then the 291 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 292 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 293 * <dd> <p>Checks whether the values of two operands are equal; if the values are 294 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 295 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 296 * operand is greater than the value of the right operand; if yes, then the 297 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 298 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 299 * the value of the right operand; if yes, then the condition becomes true.</p> 300 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 301 * the value of the left operand is greater than or equal to the value of the right 302 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 303 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 304 * operand is less than or equal to the value of the right operand; if yes, then 305 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 306 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 307 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 308 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 309 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 310 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 311 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 312 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 313 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 314 * <p>The following list shows the valid operators on each type. When you define a 315 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 316 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 317 * </p> 318 */ SetExpression(Aws::String && value)319 inline void SetExpression(Aws::String&& value) { m_expressionHasBeenSet = true; m_expression = std::move(value); } 320 321 /** 322 * <p>An expression that filters the partitions to be returned.</p> <p>The 323 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 324 * The SQL statement parser <a 325 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 326 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 327 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 328 * <p>Checks whether the values of the two operands are equal; if yes, then the 329 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 330 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 331 * <dd> <p>Checks whether the values of two operands are equal; if the values are 332 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 333 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 334 * operand is greater than the value of the right operand; if yes, then the 335 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 336 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 337 * the value of the right operand; if yes, then the condition becomes true.</p> 338 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 339 * the value of the left operand is greater than or equal to the value of the right 340 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 341 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 342 * operand is less than or equal to the value of the right operand; if yes, then 343 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 344 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 345 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 346 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 347 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 348 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 349 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 350 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 351 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 352 * <p>The following list shows the valid operators on each type. When you define a 353 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 354 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 355 * </p> 356 */ SetExpression(const char * value)357 inline void SetExpression(const char* value) { m_expressionHasBeenSet = true; m_expression.assign(value); } 358 359 /** 360 * <p>An expression that filters the partitions to be returned.</p> <p>The 361 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 362 * The SQL statement parser <a 363 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 364 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 365 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 366 * <p>Checks whether the values of the two operands are equal; if yes, then the 367 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 368 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 369 * <dd> <p>Checks whether the values of two operands are equal; if the values are 370 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 371 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 372 * operand is greater than the value of the right operand; if yes, then the 373 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 374 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 375 * the value of the right operand; if yes, then the condition becomes true.</p> 376 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 377 * the value of the left operand is greater than or equal to the value of the right 378 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 379 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 380 * operand is less than or equal to the value of the right operand; if yes, then 381 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 382 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 383 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 384 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 385 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 386 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 387 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 388 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 389 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 390 * <p>The following list shows the valid operators on each type. When you define a 391 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 392 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 393 * </p> 394 */ WithExpression(const Aws::String & value)395 inline GetPartitionsRequest& WithExpression(const Aws::String& value) { SetExpression(value); return *this;} 396 397 /** 398 * <p>An expression that filters the partitions to be returned.</p> <p>The 399 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 400 * The SQL statement parser <a 401 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 402 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 403 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 404 * <p>Checks whether the values of the two operands are equal; if yes, then the 405 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 406 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 407 * <dd> <p>Checks whether the values of two operands are equal; if the values are 408 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 409 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 410 * operand is greater than the value of the right operand; if yes, then the 411 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 412 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 413 * the value of the right operand; if yes, then the condition becomes true.</p> 414 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 415 * the value of the left operand is greater than or equal to the value of the right 416 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 417 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 418 * operand is less than or equal to the value of the right operand; if yes, then 419 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 420 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 421 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 422 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 423 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 424 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 425 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 426 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 427 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 428 * <p>The following list shows the valid operators on each type. When you define a 429 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 430 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 431 * </p> 432 */ WithExpression(Aws::String && value)433 inline GetPartitionsRequest& WithExpression(Aws::String&& value) { SetExpression(std::move(value)); return *this;} 434 435 /** 436 * <p>An expression that filters the partitions to be returned.</p> <p>The 437 * expression uses SQL syntax similar to the SQL <code>WHERE</code> filter clause. 438 * The SQL statement parser <a 439 * href="http://jsqlparser.sourceforge.net/home.php">JSQLParser</a> parses the 440 * expression. </p> <p> <i>Operators</i>: The following are the operators that you 441 * can use in the <code>Expression</code> API call:</p> <dl> <dt>=</dt> <dd> 442 * <p>Checks whether the values of the two operands are equal; if yes, then the 443 * condition becomes true.</p> <p>Example: Assume 'variable a' holds 10 and 444 * 'variable b' holds 20. </p> <p>(a = b) is not true.</p> </dd> <dt>< ></dt> 445 * <dd> <p>Checks whether the values of two operands are equal; if the values are 446 * not equal, then the condition becomes true.</p> <p>Example: (a < > b) is 447 * true.</p> </dd> <dt>></dt> <dd> <p>Checks whether the value of the left 448 * operand is greater than the value of the right operand; if yes, then the 449 * condition becomes true.</p> <p>Example: (a > b) is not true.</p> </dd> 450 * <dt><</dt> <dd> <p>Checks whether the value of the left operand is less than 451 * the value of the right operand; if yes, then the condition becomes true.</p> 452 * <p>Example: (a < b) is true.</p> </dd> <dt>>=</dt> <dd> <p>Checks whether 453 * the value of the left operand is greater than or equal to the value of the right 454 * operand; if yes, then the condition becomes true.</p> <p>Example: (a >= b) is 455 * not true.</p> </dd> <dt><=</dt> <dd> <p>Checks whether the value of the left 456 * operand is less than or equal to the value of the right operand; if yes, then 457 * the condition becomes true.</p> <p>Example: (a <= b) is true.</p> </dd> 458 * <dt>AND, OR, IN, BETWEEN, LIKE, NOT, IS NULL</dt> <dd> <p>Logical operators.</p> 459 * </dd> </dl> <p> <i>Supported Partition Key Types</i>: The following are the 460 * supported partition keys.</p> <ul> <li> <p> <code>string</code> </p> </li> <li> 461 * <p> <code>date</code> </p> </li> <li> <p> <code>timestamp</code> </p> </li> <li> 462 * <p> <code>int</code> </p> </li> <li> <p> <code>bigint</code> </p> </li> <li> <p> 463 * <code>long</code> </p> </li> <li> <p> <code>tinyint</code> </p> </li> <li> <p> 464 * <code>smallint</code> </p> </li> <li> <p> <code>decimal</code> </p> </li> </ul> 465 * <p>If an type is encountered that is not valid, an exception is thrown. </p> 466 * <p>The following list shows the valid operators on each type. When you define a 467 * crawler, the <code>partitionKey</code> type is created as a <code>STRING</code>, 468 * to be compatible with the catalog partitions. </p> <p> <i>Sample API Call</i>: 469 * </p> 470 */ WithExpression(const char * value)471 inline GetPartitionsRequest& WithExpression(const char* value) { SetExpression(value); return *this;} 472 473 474 /** 475 * <p>A continuation token, if this is not the first call to retrieve these 476 * partitions.</p> 477 */ GetNextToken()478 inline const Aws::String& GetNextToken() const{ return m_nextToken; } 479 480 /** 481 * <p>A continuation token, if this is not the first call to retrieve these 482 * partitions.</p> 483 */ NextTokenHasBeenSet()484 inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; } 485 486 /** 487 * <p>A continuation token, if this is not the first call to retrieve these 488 * partitions.</p> 489 */ SetNextToken(const Aws::String & value)490 inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; } 491 492 /** 493 * <p>A continuation token, if this is not the first call to retrieve these 494 * partitions.</p> 495 */ SetNextToken(Aws::String && value)496 inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); } 497 498 /** 499 * <p>A continuation token, if this is not the first call to retrieve these 500 * partitions.</p> 501 */ SetNextToken(const char * value)502 inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); } 503 504 /** 505 * <p>A continuation token, if this is not the first call to retrieve these 506 * partitions.</p> 507 */ WithNextToken(const Aws::String & value)508 inline GetPartitionsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;} 509 510 /** 511 * <p>A continuation token, if this is not the first call to retrieve these 512 * partitions.</p> 513 */ WithNextToken(Aws::String && value)514 inline GetPartitionsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;} 515 516 /** 517 * <p>A continuation token, if this is not the first call to retrieve these 518 * partitions.</p> 519 */ WithNextToken(const char * value)520 inline GetPartitionsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;} 521 522 523 /** 524 * <p>The segment of the table's partitions to scan in this request.</p> 525 */ GetSegment()526 inline const Segment& GetSegment() const{ return m_segment; } 527 528 /** 529 * <p>The segment of the table's partitions to scan in this request.</p> 530 */ SegmentHasBeenSet()531 inline bool SegmentHasBeenSet() const { return m_segmentHasBeenSet; } 532 533 /** 534 * <p>The segment of the table's partitions to scan in this request.</p> 535 */ SetSegment(const Segment & value)536 inline void SetSegment(const Segment& value) { m_segmentHasBeenSet = true; m_segment = value; } 537 538 /** 539 * <p>The segment of the table's partitions to scan in this request.</p> 540 */ SetSegment(Segment && value)541 inline void SetSegment(Segment&& value) { m_segmentHasBeenSet = true; m_segment = std::move(value); } 542 543 /** 544 * <p>The segment of the table's partitions to scan in this request.</p> 545 */ WithSegment(const Segment & value)546 inline GetPartitionsRequest& WithSegment(const Segment& value) { SetSegment(value); return *this;} 547 548 /** 549 * <p>The segment of the table's partitions to scan in this request.</p> 550 */ WithSegment(Segment && value)551 inline GetPartitionsRequest& WithSegment(Segment&& value) { SetSegment(std::move(value)); return *this;} 552 553 554 /** 555 * <p>The maximum number of partitions to return in a single response.</p> 556 */ GetMaxResults()557 inline int GetMaxResults() const{ return m_maxResults; } 558 559 /** 560 * <p>The maximum number of partitions to return in a single response.</p> 561 */ MaxResultsHasBeenSet()562 inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; } 563 564 /** 565 * <p>The maximum number of partitions to return in a single response.</p> 566 */ SetMaxResults(int value)567 inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; } 568 569 /** 570 * <p>The maximum number of partitions to return in a single response.</p> 571 */ WithMaxResults(int value)572 inline GetPartitionsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;} 573 574 575 /** 576 * <p>When true, specifies not returning the partition column schema. Useful when 577 * you are interested only in other partition attributes such as partition values 578 * or location. This approach avoids the problem of a large response by not 579 * returning duplicate data.</p> 580 */ GetExcludeColumnSchema()581 inline bool GetExcludeColumnSchema() const{ return m_excludeColumnSchema; } 582 583 /** 584 * <p>When true, specifies not returning the partition column schema. Useful when 585 * you are interested only in other partition attributes such as partition values 586 * or location. This approach avoids the problem of a large response by not 587 * returning duplicate data.</p> 588 */ ExcludeColumnSchemaHasBeenSet()589 inline bool ExcludeColumnSchemaHasBeenSet() const { return m_excludeColumnSchemaHasBeenSet; } 590 591 /** 592 * <p>When true, specifies not returning the partition column schema. Useful when 593 * you are interested only in other partition attributes such as partition values 594 * or location. This approach avoids the problem of a large response by not 595 * returning duplicate data.</p> 596 */ SetExcludeColumnSchema(bool value)597 inline void SetExcludeColumnSchema(bool value) { m_excludeColumnSchemaHasBeenSet = true; m_excludeColumnSchema = value; } 598 599 /** 600 * <p>When true, specifies not returning the partition column schema. Useful when 601 * you are interested only in other partition attributes such as partition values 602 * or location. This approach avoids the problem of a large response by not 603 * returning duplicate data.</p> 604 */ WithExcludeColumnSchema(bool value)605 inline GetPartitionsRequest& WithExcludeColumnSchema(bool value) { SetExcludeColumnSchema(value); return *this;} 606 607 private: 608 609 Aws::String m_catalogId; 610 bool m_catalogIdHasBeenSet; 611 612 Aws::String m_databaseName; 613 bool m_databaseNameHasBeenSet; 614 615 Aws::String m_tableName; 616 bool m_tableNameHasBeenSet; 617 618 Aws::String m_expression; 619 bool m_expressionHasBeenSet; 620 621 Aws::String m_nextToken; 622 bool m_nextTokenHasBeenSet; 623 624 Segment m_segment; 625 bool m_segmentHasBeenSet; 626 627 int m_maxResults; 628 bool m_maxResultsHasBeenSet; 629 630 bool m_excludeColumnSchema; 631 bool m_excludeColumnSchemaHasBeenSet; 632 }; 633 634 } // namespace Model 635 } // namespace Glue 636 } // namespace Aws 637