(
self, argument_model, include_enum_values=True
)
| 528 | ) |
| 529 | |
| 530 | def _json_example_value_name( |
| 531 | self, argument_model, include_enum_values=True |
| 532 | ): |
| 533 | # If include_enum_values is True, then the valid enum values |
| 534 | # are included as the sample JSON value. |
| 535 | if isinstance(argument_model, StringShape): |
| 536 | if argument_model.enum and include_enum_values: |
| 537 | choices = argument_model.enum |
| 538 | return '|'.join([f'"{c}"' for c in choices]) |
| 539 | else: |
| 540 | return '"string"' |
| 541 | elif argument_model.type_name == 'boolean': |
| 542 | return 'true|false' |
| 543 | else: |
| 544 | return f'{argument_model.type_name}' |
| 545 | |
| 546 | def _json_example(self, doc, argument_model, stack): |
| 547 | if argument_model.name in stack: |
no outgoing calls
no test coverage detected