18 using System.Collections.Generic;
19 using Lucene.Net.Support;
21 namespace Lucene.Net.Index
37 this.consumer = consumer;
38 this.endConsumer = endConsumer;
41 internal override void SetFieldInfos(
FieldInfos fieldInfos)
43 base.SetFieldInfos(fieldInfos);
44 consumer.SetFieldInfos(fieldInfos);
45 endConsumer.SetFieldInfos(fieldInfos);
51 var childThreadsAndFields =
new HashMap<InvertedDocConsumerPerThread, ICollection<InvertedDocConsumerPerField>>();
52 var endChildThreadsAndFields =
new HashMap<InvertedDocEndConsumerPerThread, ICollection<InvertedDocEndConsumerPerField>>();
54 foreach (var entry
in threadsAndFields)
58 ICollection<InvertedDocConsumerPerField> childFields =
new HashSet<InvertedDocConsumerPerField>();
59 ICollection<InvertedDocEndConsumerPerField> endChildFields =
new HashSet<InvertedDocEndConsumerPerField>();
63 childFields.Add(perField.consumer);
64 endChildFields.Add(perField.endConsumer);
67 childThreadsAndFields[perThread.consumer] = childFields;
68 endChildThreadsAndFields[perThread.endConsumer] = endChildFields;
71 consumer.Flush(childThreadsAndFields, state);
72 endConsumer.Flush(endChildThreadsAndFields, state);
77 consumer.CloseDocStore(state);
78 endConsumer.CloseDocStore(state);
81 public override void Abort()
87 public override bool FreeRAM()
89 return consumer.FreeRAM();