#[repr(C)]pub struct C4IndexOptions {
pub language: *const c_char,
pub ignoreDiacritics: bool,
pub disableStemming: bool,
pub stopWords: *const c_char,
}Expand description
Options for indexes; these each apply to specific types of indexes.
Fields§
§language: *const c_charDominant language of text to be indexed; setting this enables word stemming, i.e. matching different cases of the same word (“big” and “bigger”, for instance.) Can be an ISO-639 language code or a lowercase (English) language name; supported languages are: da/danish, nl/dutch, en/english, fi/finnish, fr/french, de/german, hu/hungarian, it/italian, no/norwegian, pt/portuguese, ro/romanian, ru/russian, es/spanish, sv/swedish, tr/turkish. If left null, or set to an unrecognized language, no language-specific behaviors such as stemming and stop-word removal occur.
ignoreDiacritics: boolShould diacritical marks (accents) be ignored? Defaults to false. Generally this should be left false for non-English text.
disableStemming: bool“Stemming” coalesces different grammatical forms of the same word (“big” and “bigger”,
for instance.) Full-text search normally uses stemming if the language is one for
which stemming rules are available, but this flag can be set to true to disable it.
Stemming is currently available for these languages: da/danish, nl/dutch, en/english,
fi/finnish, fr/french, de/german, hu/hungarian, it/italian, no/norwegian, pt/portuguese,
ro/romanian, ru/russian, s/spanish, sv/swedish, tr/turkish.
stopWords: *const c_charList of words to ignore (“stop words”) for full-text search. Ignoring common words
like “the” and “a” helps keep down the size of the index.
If NULL, a default word list will be used based on the language option, if there is
one for that language.
To suppress stop-words, use an empty string.
To provide a custom list of words, use a string containing the words in lowercase
separated by spaces.
Trait Implementations§
Source§impl Clone for C4IndexOptions
impl Clone for C4IndexOptions
Source§fn clone(&self) -> C4IndexOptions
fn clone(&self) -> C4IndexOptions
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more