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

Method _document_list

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

Source from the content-addressed store, hash-verified

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')
154 self._start_nested_value(list_section, '[')
155 item_shape = shape.member
156 for index, val in enumerate(value):
157 item_section = list_section.add_new_section(index)
158 item_section.style.new_line()
159 path.append(f'[{index}]')
160 item_comment = self._get_comment(path, comments)
161 if item_comment:
162 item_section.write(item_comment)
163 item_section.style.new_line()
164 self._document(item_section, val, comments, path, item_shape)
165 path.pop()
166 list_section_end = list_section.add_new_section('ending-bracket')
167 self._end_nested_value(list_section_end, '],')
168
169 def _document_str(self, section, value, path):
170 # We do the string conversion because this might accept a type that

Callers 1

_documentMethod · 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