crashpad::ElfImageReader::NoteReader Class Reference

This class enables reading note segments from an ELF image. More...

`#include "snapshot/elf/elf_image_reader.h"`

## Public Types

enum | Result
| The return value for NextNote(). More...
using | NoteType = decltype(Elf64_Nhdr::n_type)
| A type large enough to hold a note type, potentially across bitness.

## Public Member Functions

Result | NextNote (std::string *name, NoteType *type, std::string *desc)
| Searches for the next note in the image. More...
| NoteReader (const ElfImageReader *elf_reader_, const ProcessMemoryRange *range, const ProgramHeaderTable *phdr_table, ssize_t max_note_size, const std::string &name_filter=std::string(), NoteType type_filter=0, bool use_filter=false)

## Detailed Description

This class enables reading note segments from an ELF image.

Objects of this class should be created by calling ElfImageReader::Notes() or ElfImageReader::NotesWithNameAndType().

## Member Enumeration Documentation

## Result

enum crashpad::ElfImageReader::NoteReader::Result

strong

The return value for NextNote().

Enumerator
kError | An error occurred. The NoteReader is invalidated and message is logged.
kSuccess | A note was found.
kNoMoreNotes | No more notes were found.

## Member Function Documentation

## NextNote()

ElfImageReader::NoteReader::Result crashpad::ElfImageReader::NoteReader::NextNote | ( | std::string * | name,
|  | NoteType * | type,
|  | std::string * | desc
| ) |  |

Searches for the next note in the image.

Parameters

  [out] | name | The name of the note owner, if not `nullptr`.
  [out] | type | A type for the note, if not `nullptr`.
  [out] | desc | The note descriptor.

Returns
  a Result value. name, type, and desc are only valid if this method returns Result::kSuccess.

The documentation for this class was generated from the following files:

- snapshot/elf/elf_image_reader.h
- snapshot/elf/elf_image_reader.cc