/// <summary> /// Constructor /// </summary> /// <param name="inputDataProvider">DataProvider - factory, which can produce you IData type</param> public Searcher(IDataProvider inputDataProvider, IOutDataProvider outputDataProvider) { m_inputDataProvider = inputDataProvider; m_outputDataProvider = outputDataProvider; m_outputDataProvider.setResultList(m_outputList); m_tokOptions = new TokenizeOptions(new List<KeyValuePair<string, string>>(0), SharedTypes.CaseSensType.CIgnore); m_tokenizer = new Tokenizer(m_tokOptions); InitializeOptions<IData> initOptions; initOptions = new InitializeOptions<IData>(m_tokenizer, StringComparer.InvariantCultureIgnoreCase, (a, b) => { if (!a.UserData.Contains(b[0])) a.UserData.Add(b[0]); } , (rdr) => { return m_inputDataProvider.produce(rdr); }); m_finderEngine = new FinderEngine<IData>(initOptions); }