(section, event_name, **kwargs)
| 339 | |
| 340 | |
| 341 | def document_copy_source_form(section, event_name, **kwargs): |
| 342 | if 'request-example' in event_name: |
| 343 | parent = section.get_section('structure-value') |
| 344 | param_line = parent.get_section('CopySource') |
| 345 | value_portion = param_line.get_section('member-value') |
| 346 | value_portion.clear_text() |
| 347 | value_portion.write( |
| 348 | "'string' or {'Bucket': 'string', " |
| 349 | "'Key': 'string', 'VersionId': 'string'}" |
| 350 | ) |
| 351 | elif 'request-params' in event_name: |
| 352 | param_section = section.get_section('CopySource') |
| 353 | type_section = param_section.get_section('param-type') |
| 354 | type_section.clear_text() |
| 355 | type_section.write(':type CopySource: str or dict') |
| 356 | doc_section = param_section.get_section('param-documentation') |
| 357 | doc_section.clear_text() |
| 358 | doc_section.write( |
| 359 | "The name of the source bucket, key name of the source object, " |
| 360 | "and optional version ID of the source object. You can either " |
| 361 | "provide this value as a string or a dictionary. The " |
| 362 | "string form is {bucket}/{key} or " |
| 363 | "{bucket}/{key}?versionId={versionId} if you want to copy a " |
| 364 | "specific version. You can also provide this value as a " |
| 365 | "dictionary. The dictionary format is recommended over " |
| 366 | "the string format because it is more explicit. The dictionary " |
| 367 | "format is: {'Bucket': 'bucket', 'Key': 'key', 'VersionId': 'id'}." |
| 368 | " Note that the VersionId key is optional and may be omitted." |
| 369 | " To specify an S3 access point, provide the access point" |
| 370 | " ARN for the ``Bucket`` key in the copy source dictionary. If you" |
| 371 | " want to provide the copy source for an S3 access point as a" |
| 372 | " string instead of a dictionary, the ARN provided must be the" |
| 373 | " full S3 access point object ARN" |
| 374 | " (i.e. {accesspoint_arn}/object/{key})" |
| 375 | ) |
| 376 | |
| 377 | |
| 378 | def handle_copy_source_param(params, **kwargs): |
nothing calls this directly
no test coverage detected