Albert
Loading...
Searching...
No Matches
albert::MatchConfig Class Reference

#include <albert/matchconfig.h>

Detailed Description

Configuration for string matching.

See also
Matcher, IndexQueryHandler

Public Attributes

QRegularExpression separator_regex
 The separator regex used to split the compared strings.
 
bool ignore_case = true
 Match strings case insensitive.
 
bool ignore_diacritics = true
 Match strings normalized.
 
bool ignore_word_order = true
 Match strings independent of their order.
 
bool fuzzy = false
 Match strings error tolerant.
 

Static Public Attributes

static const uint error_tolerance_divisor = 4
 The error tolerance.
 

Member Data Documentation

◆ error_tolerance_divisor

const uint albert::MatchConfig::error_tolerance_divisor = 4
static

The error tolerance.

This hardcodes the error tolerance on enabled fuzzy to 25%.

◆ fuzzy

bool albert::MatchConfig::fuzzy = false

Match strings error tolerant.

◆ ignore_case

bool albert::MatchConfig::ignore_case = true

Match strings case insensitive.

◆ ignore_diacritics

bool albert::MatchConfig::ignore_diacritics = true

Match strings normalized.

◆ ignore_word_order

bool albert::MatchConfig::ignore_word_order = true

Match strings independent of their order.

◆ separator_regex

QRegularExpression albert::MatchConfig::separator_regex
Initial value:
=
QRegularExpression("([\\s\\\\/\\-\\[\\](){}#!?<>\"'=+*.:,;_]+)")

The separator regex used to split the compared strings.


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