(self, section, example, prefix, shape)
| 40 | self.document_output(section, example, operation_model.output_shape) |
| 41 | |
| 42 | def document_input(self, section, example, prefix, shape): |
| 43 | input_section = section.add_new_section('input') |
| 44 | input_section.style.start_codeblock() |
| 45 | if prefix is not None: |
| 46 | input_section.write(prefix) |
| 47 | params = example.get('input', {}) |
| 48 | comments = example.get('comments') |
| 49 | if comments: |
| 50 | comments = comments.get('input') |
| 51 | param_section = input_section.add_new_section('parameters') |
| 52 | self._document_params(param_section, params, comments, [], shape) |
| 53 | closing_section = input_section.add_new_section('input-close') |
| 54 | closing_section.style.new_line() |
| 55 | closing_section.style.new_line() |
| 56 | closing_section.write('print(response)') |
| 57 | closing_section.style.end_codeblock() |
| 58 | |
| 59 | def document_output(self, section, example, shape): |
| 60 | output_section = section.add_new_section('output') |
no test coverage detected