Creates a usage details section for the provided action group.
(action_group)
| 574 | |
| 575 | |
| 576 | def _MakeUsageDetailsSection(action_group): |
| 577 | """Creates a usage details section for the provided action group.""" |
| 578 | item_strings = [] |
| 579 | for name, member in action_group.GetItems(): |
| 580 | info = inspectutils.Info(member) |
| 581 | item = name |
| 582 | docstring_info = info.get('docstring_info') |
| 583 | if (docstring_info |
| 584 | and not custom_descriptions.NeedsCustomDescription(member)): |
| 585 | summary = docstring_info.summary |
| 586 | elif custom_descriptions.NeedsCustomDescription(member): |
| 587 | summary = custom_descriptions.GetSummary( |
| 588 | member, LINE_LENGTH - SECTION_INDENTATION, LINE_LENGTH) |
| 589 | else: |
| 590 | summary = None |
| 591 | item = _CreateItem(name, summary) |
| 592 | item_strings.append(item) |
| 593 | return (action_group.plural.upper(), |
| 594 | _NewChoicesSection(action_group.name.upper(), item_strings)) |
| 595 | |
| 596 | |
| 597 | def _ValuesUsageDetailsSection(component, values): |
no test coverage detected