Example #1
0
 /// <summary>
 /// If key provided matches that of this Composite, give JoinCollector
 /// iterator over values it may emit.
 /// </summary>
 /// <exception cref="System.IO.IOException"/>
 public virtual void Accept(CompositeRecordReader.JoinCollector jc, K key)
 {
     // No values from static EMPTY class
     if (HasNext() && 0 == cmp.Compare(key, Key()))
     {
         FillJoinCollector(CreateKey());
         jc.Add(id, GetDelegate());
         return;
     }
     jc.Add(id, Empty);
 }
 /// <summary>
 /// Add an iterator to the collector at the position occupied by this
 /// RecordReader over the values in this stream paired with the key
 /// provided (ie register a stream of values from this source matching K
 /// with a collector).
 /// </summary>
 /// <exception cref="System.IO.IOException"/>
 public virtual void Accept(CompositeRecordReader.JoinCollector i, K key)
 {
     // JoinCollector comes from parent, which has
     // no static type for the slot this sits in
     vjoin.Clear();
     if (0 == cmp.Compare(key, khead))
     {
         do
         {
             vjoin.Add(vhead);
         }while (Next() && 0 == cmp.Compare(key, khead));
     }
     i.Add(id, vjoin);
 }