Class RankedSearchList
- Namespace
- MailFathom.Application.Emails.BrowseSearch
- Assembly
- MailFathom.Application.dll
The one ranked list a paged search walks: what the query is, what the filters admit, and the fingerprint tying a cursor to both.
public sealed record RankedSearchList : IEquatable<RankedSearchList>
- Inheritance
-
RankedSearchList
- Implements
- Inherited Members
Remarks
It is to a search what EmailTimelineFilter is to a timeline. A timeline's identity is its filters and the end it is read from; a ranked list's is its filters and the text it is ranked against, because changing either produces a different sequence and a boundary taken in one names nothing in the other.
The filters are held apart from the query text rather than folded into it, which is the whole of what constraining rather than ranking means here: Selection reaches the query as a predicate, so a message it excludes cannot be returned however well it matches, and QueryText reaches it as the text the remaining mail is ordered by. Nothing in this type can turn one into the other.
The list is bounded at MaximumRankedDepth results, and paging walks inside that bound. A ranked order has no total ordering of its own the way a timeline has — indexing one message re-ranks everything — so what a cursor into it names is a place in a list of fixed depth rather than a position in an order that will still exist tomorrow. RankedSearchCursor states what that costs a client.
Fields
- MaximumRankedDepth
How many ranked results paging can reach before the list ends.
Properties
- Fingerprint
Gets the fingerprint identifying this list to a continuation cursor.
- QueryText
Gets the validated free text the eligible mail is ranked against.
- Selection
Gets the validated filters that decide which mail is eligible before anything is ranked.
Methods
- Create(MailboxScope, string?, string?, string?, DateTimeOffset?, DateTimeOffset?, bool?, bool?, bool?)
Validates and normalizes what a search asked for.