Skip to content

Commit a42f27e

Browse files
committed
Document all object properties as nullable
The generated objects are performing delayed validation for the required properties, so they still accept null.
1 parent f9ff2e7 commit a42f27e

File tree

264 files changed

+537
-536
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

264 files changed

+537
-536
lines changed

src/CodeGenerator/src/Generator/ObjectGenerator.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,8 @@ private function addProperties(StructureShape $shape, ClassBuilder $classBuilder
308308
}
309309
$method->setReturnNullable($nullable);
310310
if ($parameterType) {
311-
$property->addComment('@var ' . $parameterType . ($nullable ? '|null' : ''));
311+
// Properties are always documented as nullable due to the delayed validation.
312+
$property->addComment('@var ' . $parameterType . '|null');
312313
}
313314
}
314315

src/Core/src/Sts/ValueObject/AssumedRoleUser.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ final class AssumedRoleUser
1111
* A unique identifier that contains the role ID and the role session name of the role that is being assumed. The role
1212
* ID is generated by Amazon Web Services when the role is created.
1313
*
14-
* @var string
14+
* @var string|null
1515
*/
1616
private $assumedRoleId;
1717

@@ -21,7 +21,7 @@ final class AssumedRoleUser
2121
*
2222
* [^1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html
2323
*
24-
* @var string
24+
* @var string|null
2525
*/
2626
private $arn;
2727

src/Core/src/Sts/ValueObject/Credentials.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,28 +10,28 @@ final class Credentials
1010
/**
1111
* The access key ID that identifies the temporary security credentials.
1212
*
13-
* @var string
13+
* @var string|null
1414
*/
1515
private $accessKeyId;
1616

1717
/**
1818
* The secret access key that can be used to sign requests.
1919
*
20-
* @var string
20+
* @var string|null
2121
*/
2222
private $secretAccessKey;
2323

2424
/**
2525
* The token that users must pass to the service API to use the temporary credentials.
2626
*
27-
* @var string
27+
* @var string|null
2828
*/
2929
private $sessionToken;
3030

3131
/**
3232
* The date on which the current credentials expire.
3333
*
34-
* @var \DateTimeImmutable
34+
* @var \DateTimeImmutable|null
3535
*/
3636
private $expiration;
3737

src/Core/src/Sts/ValueObject/Tag.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ final class Tag
2121
*
2222
* [^1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length
2323
*
24-
* @var string
24+
* @var string|null
2525
*/
2626
private $key;
2727

@@ -33,7 +33,7 @@ final class Tag
3333
*
3434
* [^1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length
3535
*
36-
* @var string
36+
* @var string|null
3737
*/
3838
private $value;
3939

src/Service/AppSync/src/ValueObject/AppSyncRuntime.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ final class AppSyncRuntime
1515
/**
1616
* The `name` of the runtime to use. Currently, the only allowed value is `APPSYNC_JS`.
1717
*
18-
* @var RuntimeName::*
18+
* @var RuntimeName::*|null
1919
*/
2020
private $name;
2121

2222
/**
2323
* The `version` of the runtime to use. Currently, the only allowed version is `1.0.0`.
2424
*
25-
* @var string
25+
* @var string|null
2626
*/
2727
private $runtimeVersion;
2828

src/Service/AppSync/src/ValueObject/AuthorizationConfig.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ final class AuthorizationConfig
1515
*
1616
* - **AWS_IAM**: The authorization type is Signature Version 4 (SigV4).
1717
*
18-
* @var AuthorizationType::*
18+
* @var AuthorizationType::*|null
1919
*/
2020
private $authorizationType;
2121

src/Service/AppSync/src/ValueObject/BadRequestDetail.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ final class BadRequestDetail
1111
/**
1212
* Contains the list of errors in the request.
1313
*
14-
* @var CodeError[]
14+
* @var CodeError[]|null
1515
*/
1616
private $codeErrors;
1717

src/Service/AppSync/src/ValueObject/CachingConfig.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ final class CachingConfig
1414
*
1515
* Valid values are 1–3,600 seconds.
1616
*
17-
* @var int
17+
* @var int|null
1818
*/
1919
private $ttl;
2020

@@ -23,7 +23,7 @@ final class CachingConfig
2323
*
2424
* Valid values are entries from the `$context.arguments`, `$context.source`, and `$context.identity` maps.
2525
*
26-
* @var string[]
26+
* @var string[]|null
2727
*/
2828
private $cachingKeys;
2929

src/Service/AppSync/src/ValueObject/DynamodbDataSourceConfig.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ final class DynamodbDataSourceConfig
1212
/**
1313
* The table name.
1414
*
15-
* @var string
15+
* @var string|null
1616
*/
1717
private $tableName;
1818

1919
/**
2020
* The Amazon Web Services Region.
2121
*
22-
* @var string
22+
* @var string|null
2323
*/
2424
private $awsRegion;
2525

src/Service/AppSync/src/ValueObject/ElasticsearchDataSourceConfig.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ final class ElasticsearchDataSourceConfig
1515
/**
1616
* The endpoint.
1717
*
18-
* @var string
18+
* @var string|null
1919
*/
2020
private $endpoint;
2121

2222
/**
2323
* The Amazon Web Services Region.
2424
*
25-
* @var string
25+
* @var string|null
2626
*/
2727
private $awsRegion;
2828

src/Service/AppSync/src/ValueObject/EventBridgeDataSourceConfig.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ final class EventBridgeDataSourceConfig
1414
*
1515
* [^1]: https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-event-bus.html
1616
*
17-
* @var string
17+
* @var string|null
1818
*/
1919
private $eventBusArn;
2020

src/Service/AppSync/src/ValueObject/LambdaDataSourceConfig.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ final class LambdaDataSourceConfig
1212
/**
1313
* The Amazon Resource Name (ARN) for the Lambda function.
1414
*
15-
* @var string
15+
* @var string|null
1616
*/
1717
private $lambdaFunctionArn;
1818

src/Service/AppSync/src/ValueObject/OpenSearchServiceDataSourceConfig.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ final class OpenSearchServiceDataSourceConfig
1212
/**
1313
* The endpoint.
1414
*
15-
* @var string
15+
* @var string|null
1616
*/
1717
private $endpoint;
1818

1919
/**
2020
* The Amazon Web Services Region.
2121
*
22-
* @var string
22+
* @var string|null
2323
*/
2424
private $awsRegion;
2525

src/Service/AppSync/src/ValueObject/PipelineConfig.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ final class PipelineConfig
1010
/**
1111
* A list of `Function` objects.
1212
*
13-
* @var string[]
13+
* @var string[]|null
1414
*/
1515
private $functions;
1616

src/Service/Athena/src/ValueObject/AclConfiguration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ final class AclConfiguration
2222
*
2323
* [^1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/acl-overview.html#canned-acl
2424
*
25-
* @var S3AclOption::*
25+
* @var S3AclOption::*|null
2626
*/
2727
private $s3AclOption;
2828

src/Service/Athena/src/ValueObject/Column.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ final class Column
1010
/**
1111
* The name of the column.
1212
*
13-
* @var string
13+
* @var string|null
1414
*/
1515
private $name;
1616

src/Service/Athena/src/ValueObject/ColumnInfo.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ final class ColumnInfo
3333
/**
3434
* The name of the column.
3535
*
36-
* @var string
36+
* @var string|null
3737
*/
3838
private $name;
3939

@@ -47,7 +47,7 @@ final class ColumnInfo
4747
/**
4848
* The data type of the column.
4949
*
50-
* @var string
50+
* @var string|null
5151
*/
5252
private $type;
5353

src/Service/Athena/src/ValueObject/CustomerContentEncryptionConfiguration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ final class CustomerContentEncryptionConfiguration
1111
/**
1212
* The KMS key that is used to encrypt the user's data stores in Athena.
1313
*
14-
* @var string
14+
* @var string|null
1515
*/
1616
private $kmsKey;
1717

src/Service/Athena/src/ValueObject/DataCatalog.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ final class DataCatalog
1717
* maximum of 127 alphanumeric, underscore, at sign, or hyphen characters. The remainder of the length constraint of 256
1818
* is reserved for use by Athena.
1919
*
20-
* @var string
20+
* @var string|null
2121
*/
2222
private $name;
2323

@@ -32,7 +32,7 @@ final class DataCatalog
3232
* The type of data catalog to create: `LAMBDA` for a federated catalog, `HIVE` for an external hive metastore, or
3333
* `GLUE` for an Glue Data Catalog.
3434
*
35-
* @var DataCatalogType::*
35+
* @var DataCatalogType::*|null
3636
*/
3737
private $type;
3838

@@ -65,7 +65,7 @@ final class DataCatalog
6565
* - Queries that specify a Glue Data Catalog other than the default `AwsDataCatalog` must be run on Athena engine
6666
* version 2.
6767
*
68-
* @var array<string, string>
68+
* @var array<string, string>|null
6969
*/
7070
private $parameters;
7171

src/Service/Athena/src/ValueObject/Database.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ final class Database
1010
/**
1111
* The name of the database.
1212
*
13-
* @var string
13+
* @var string|null
1414
*/
1515
private $name;
1616

@@ -24,7 +24,7 @@ final class Database
2424
/**
2525
* A set of custom key/value pairs.
2626
*
27-
* @var array<string, string>
27+
* @var array<string, string>|null
2828
*/
2929
private $parameters;
3030

src/Service/Athena/src/ValueObject/EncryptionConfiguration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ final class EncryptionConfiguration
1818
* If a query runs in a workgroup and the workgroup overrides client-side settings, then the workgroup's setting for
1919
* encryption is used. It specifies whether query results must be encrypted, for all queries that run in this workgroup.
2020
*
21-
* @var EncryptionOption::*
21+
* @var EncryptionOption::*|null
2222
*/
2323
private $encryptionOption;
2424

src/Service/Athena/src/ValueObject/EngineConfiguration.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ final class EngineConfiguration
2020
/**
2121
* The maximum number of DPUs that can run concurrently.
2222
*
23-
* @var int
23+
* @var int|null
2424
*/
2525
private $maxConcurrentDpus;
2626

@@ -38,15 +38,15 @@ final class EngineConfiguration
3838
* StartSessionRequest$NotebookVersion field, and then add a key named `NotebookId` to `AdditionalConfigs` that has the
3939
* value of the Athena notebook ID.
4040
*
41-
* @var array<string, string>
41+
* @var array<string, string>|null
4242
*/
4343
private $additionalConfigs;
4444

4545
/**
4646
* Specifies custom jar files and Spark properties for use cases like cluster encryption, table formats, and general
4747
* Spark tuning.
4848
*
49-
* @var array<string, string>
49+
* @var array<string, string>|null
5050
*/
5151
private $sparkProperties;
5252

src/Service/Athena/src/ValueObject/NamedQuery.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ final class NamedQuery
1010
/**
1111
* The query name.
1212
*
13-
* @var string
13+
* @var string|null
1414
*/
1515
private $name;
1616

@@ -24,14 +24,14 @@ final class NamedQuery
2424
/**
2525
* The database to which the query belongs.
2626
*
27-
* @var string
27+
* @var string|null
2828
*/
2929
private $database;
3030

3131
/**
3232
* The SQL statements that make up the query.
3333
*
34-
* @var string
34+
* @var string|null
3535
*/
3636
private $queryString;
3737

src/Service/Athena/src/ValueObject/QueryExecution.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ final class QueryExecution
8989
* A list of values for the parameters in a query. The values are applied sequentially to the parameters in the query in
9090
* the order in which the parameters occur. The list of parameters is not returned in the response.
9191
*
92-
* @var string[]
92+
* @var string[]|null
9393
*/
9494
private $executionParameters;
9595

src/Service/Athena/src/ValueObject/ResultReuseByAgeConfiguration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ final class ResultReuseByAgeConfiguration
1212
/**
1313
* True if previous query results can be reused when the query is run; otherwise, false. The default is false.
1414
*
15-
* @var bool
15+
* @var bool|null
1616
*/
1717
private $enabled;
1818

src/Service/Athena/src/ValueObject/ResultReuseInformation.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ final class ResultReuseInformation
1010
/**
1111
* True if a previous query result was reused; false if the result was generated from a new run of the query.
1212
*
13-
* @var bool
13+
* @var bool|null
1414
*/
1515
private $reusedPreviousResult;
1616

src/Service/Athena/src/ValueObject/ResultSet.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ final class ResultSet
1111
/**
1212
* The rows in the table.
1313
*
14-
* @var Row[]
14+
* @var Row[]|null
1515
*/
1616
private $rows;
1717

0 commit comments

Comments
 (0)