Immutable owning selection; remains readable after session/source replacement. text is the exact decoded UTF-8 literal. snippet contains bounded preceding whole-grapheme context and the match; it is empty when the match exceeds its snippet cap. Neither string borrows source pages or UI state.
More...
#include <document_search.hpp>
|
|
DocumentRevision | revision |
| | Exact source namespace and provider revision.
|
|
std::uint64_t | byteOffset {} |
| | Inclusive offset in the original source encoding.
|
|
std::uint64_t | byteLength {} |
| | Original byte length, with an exclusive whole-grapheme end.
|
|
std::string | text = std::string(0, '\0') |
| | Complete UTF-8 match, bounded by maxQueryBytes.
|
|
std::string | snippet = std::string(0, '\0') |
| | Whole-grapheme context, bounded by maxSnippetBytes.
|
|
std::size_t | snippetMatchOffset {} |
| | Inclusive UTF-8 match offset inside snippet.
|
|
std::size_t | snippetMatchLength {} |
| | UTF-8 match length inside snippet; zero for an omitted snippet.
|
|
bool | snippetTruncated {} |
| | The complete match cannot fit inside the configured snippet cap.
|
|
|
class | DocumentSearchSession |
Immutable owning selection; remains readable after session/source replacement. text is the exact decoded UTF-8 literal. snippet contains bounded preceding whole-grapheme context and the match; it is empty when the match exceeds its snippet cap. Neither string borrows source pages or UI state.
◆ retainedBytes()
| std::size_t portals::DocumentSearchMatch::retainedBytes |
( |
| ) |
const |
|
inlinenoexcept |
- Returns
- Retained credit bytes; no allocation, locking or source access.
The documentation for this struct was generated from the following file: