The example demonstrates a typical usage of the class.
stringindexFolder=@"c:\MyIndex\";stringdocumentsFolder=@"c:\MyDocuments\";stringquery="daterange(2017-01-01 ~~ 2019-12-31)";Indexindex=newIndex(indexFolder);// Creating an index in the specified folderindex.Add(documentsFolder);// Indexing documents from the specified folderSearchOptionsoptions=newSearchOptions();options.DateFormats.Clear();// Removing default date formatsDateFormatElement[]elements=newDateFormatElement[]{DateFormatElement.MonthTwoDigits,DateFormatElement.DateSeparator,DateFormatElement.DayOfMonthTwoDigits,DateFormatElement.DateSeparator,DateFormatElement.YearFourDigits,};// Creating a date format pattern 'MM/dd/yyyy'DateFormatdateFormat=newDateFormat(elements,"/");options.DateFormats.Add(dateFormat);SearchResultresult=index.Search(query,options);// Search in index