Xapian:...eSorter(3)

πŸ’… NAME πŸ’…

okay bestie, welcome to Xapian:...eSorter(3) from the User Contributed Perl Documentation β€” yes, that's the manual name folded in right here near the top, we're not copying the whole header line, we're too chic for that. This page is all about Search::Xapian::MultiValueSorter, which allows sorting by a several values. (The "a several" is literally how it's written, iykyk. πŸ’€)

✨ DESCRIPTION ✨

Results are ordered by the first value. In the event of a tie, the second is used. If this is the same for both, the third is used, and so on. It's giving priority list but make it values, and honestly? Obsessed. πŸ’–

🌸 SYNOPSIS 🌸

  use Search::Xapian;

  my $db = new Search::Xapian::Database("/path/to/db");
  my $enq = new Search::Xapian::Enquire($db);
  my $sorter = new Search::Xapian::MultiValueSorter(1, 3, 5);
  $enq->set_sort_by_key($sorter);

Like, build the db, build the Enquire, build the sorter with values 1, 3, 5, then set_sort_by_key it. Main character energy fr fr. ✨

πŸŽ€ METHODS πŸŽ€

  • new [<value>...] β€” constructs the sorter and adds the values you listed. Slay.
  • add <value> [<forward>] β€” adds another value to sort on. By default, values sort forwards, unless forward is specified and is false. That's the whole vibe. 🫢

πŸ¦‹ REFERENCE πŸ¦‹

The source doc link is literally right here, bestie:

https://xapian.org/docs/sourcedoc/html/classXapian_1_1MultiValueSorter.html


cute sign-off time: this page comes from perl v5.42.0, dated 2022-02-28, and the header/footer manual thing is Xapian:...eSorter(3). Periodt. πŸ’…πŸŒˆ

πŸ“¦ where this page comes from