/// <summary> /// This option allows you to control the number of typos in the result set. /// </summary> public Query SetTypoTolerance(TypoTolerance typoTolerance) { this.typoTolerance = typoTolerance; return(this); }
/// <summary> /// Create a new query. /// </summary> /// <param name="query">The query.</param> public Query(String query) { minWordSizeForApprox1 = 3; minWordSizeForApprox2 = 7; getRankingInfo = false; ignorePlural = false; distinct = 0; minProximity = 1; page = 0; maxValuesPerFacets = 0; hitsPerPage = 20; this.query = query; queryType = QueryType.PREFIX_LAST; removeWordsIfNoResult = RemoveWordsIfNoResult.NONE; analytics = synonyms = replaceSynonyms = allowTyposOnNumericTokens = true; typoTolerance = TypoTolerance.TYPO_TRUE; }
/// <summary> /// This option allows you to control the number of typos in the result set. /// </summary> public Query SetTypoTolerance(TypoTolerance typoTolerance) { this.typoTolerance = typoTolerance; return this; }
/// <summary> /// If set to false, disable typo-tolerance. Default to true. /// </summary> public Query EnableTypoTolerance(bool enabled) { if (enabled) { typoTolerance = TypoTolerance.TYPO_TRUE; } else { typoTolerance = TypoTolerance.TYPO_FALSE; } return this; }