openIndex abstract method
Future<MimirIndex>
openIndex(
- String name, {
- String? primaryKey,
- List<
String> ? searchableFields, - List<
String> filterableFields, - List<
String> sortableFields, - List<
String> rankingRules, - List<
String> stopWords, - List<
Synonyms> synonyms, - bool typosEnabled,
- int minWordSizeForOneTypo,
- int minWordSizeForTwoTypos,
- List<
String> disallowTyposOnWords, - List<
String> disallowTyposOnFields,
Eagerly opens an index with the supplied name
and settings.
If you know the primary key (or any of the other settings) in advance,
it is recommended to use openIndex over getIndex.
See also getIndex for restrictions on what name
can be.
While getIndex opens indexes lazily (on the first method call), openIndex both opens and initializes an index before returning.
Implementation
Future<MimirIndex> openIndex(
String name, {
String? primaryKey,
List<String>? searchableFields,
List<String> filterableFields,
List<String> sortableFields,
List<String> rankingRules,
List<String> stopWords,
List<Synonyms> synonyms,
bool typosEnabled,
int minWordSizeForOneTypo,
int minWordSizeForTwoTypos,
List<String> disallowTyposOnWords,
List<String> disallowTyposOnFields,
});