MCPcopy Index your code
hub / github.com/aws/aws-cli / _document_params

Method _document_params

awscli/botocore/docs/sharedexample.py:130–150  ·  view source on GitHub ↗
(self, section, value, comments, path, shape)

Source from the content-addressed store, hash-verified

128 dict_section_end.write(',')
129
130 def _document_params(self, section, value, comments, path, shape):
131 param_section = section.add_new_section('param-values')
132 self._start_nested_value(param_section, '(')
133 for key, val in value.items():
134 path.append(f'.{key}')
135 item_section = param_section.add_new_section(key)
136 item_section.style.new_line()
137 item_comment = self._get_comment(path, comments)
138 if item_comment:
139 item_section.write(item_comment)
140 item_section.style.new_line()
141 item_section.write(key + '=')
142
143 # Shape could be none if there are no input parameters
144 item_shape = None
145 if shape:
146 item_shape = shape.members.get(key)
147 self._document(item_section, val, comments, path, item_shape)
148 path.pop()
149 param_section_end = param_section.add_new_section('ending-parenthesis')
150 self._end_nested_value(param_section_end, ')')
151
152 def _document_list(self, section, value, comments, path, shape):
153 list_section = section.add_new_section('list-section')

Callers 1

document_inputMethod · 0.95

Calls 7

_start_nested_valueMethod · 0.95
_get_commentMethod · 0.95
_documentMethod · 0.95
_end_nested_valueMethod · 0.95
add_new_sectionMethod · 0.45
new_lineMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected