本文整理汇总了C#中Lucene.Net.Index.IndexReader.GetSequentialSubReaders方法的典型用法代码示例。如果您正苦于以下问题:C# Lucene.Net.Index.IndexReader.GetSequentialSubReaders方法的具体用法?C# Lucene.Net.Index.IndexReader.GetSequentialSubReaders怎么用?C# Lucene.Net.Index.IndexReader.GetSequentialSubReaders使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Lucene.Net.Index.IndexReader
的用法示例。
在下文中一共展示了Lucene.Net.Index.IndexReader.GetSequentialSubReaders方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetValues
public override DocValues GetValues(IndexReader reader)
{
IndexReader[] subReaders = reader.GetSequentialSubReaders();
if (subReaders != null)
{
// This is a composite reader
return new MultiDocValues(this, subReaders);
}
else
{
// Already an atomic reader -- just delegate
return other.GetValues(reader);
}
}
示例2: GatherSubReaders
/// <summary> Gathers sub-readers from reader into a List.
///
/// </summary>
/// <param name="allSubReaders">
/// </param>
/// <param name="reader">
/// </param>
public static void GatherSubReaders(System.Collections.IList allSubReaders, IndexReader reader)
{
IndexReader[] subReaders = reader.GetSequentialSubReaders();
if (subReaders == null)
{
// Add the reader itself, and do not recurse
allSubReaders.Add(reader);
}
else
{
for (int i = 0; i < subReaders.Length; i++)
{
GatherSubReaders(allSubReaders, subReaders[i]);
}
}
}