Dictionary of sections (read-only)
(self)
| 3489 | |
| 3490 | @property |
| 3491 | def sections(self) -> Mapping[str, 'Section']: |
| 3492 | """Dictionary of sections (read-only)""" |
| 3493 | count = ctypes.c_ulonglong(0) |
| 3494 | section_list = core.BNGetSections(self.handle, count) |
| 3495 | assert section_list is not None, "core.BNGetSections returned None" |
| 3496 | result = {} |
| 3497 | try: |
| 3498 | for i in range(0, count.value): |
| 3499 | section_handle = core.BNNewSectionReference(section_list[i]) |
| 3500 | assert section_handle is not None, "core.BNNewSectionReference returned None" |
| 3501 | result[core.BNSectionGetName(section_list[i])] = Section(section_handle) |
| 3502 | return result |
| 3503 | finally: |
| 3504 | core.BNFreeSectionList(section_list, count.value) |
| 3505 | |
| 3506 | @property |
| 3507 | def allocated_ranges(self) -> List['variable.AddressRange']: |