Esempio n. 1
0
        /// <summary>
        /// <inheritDoc/>
        ///
        /// </summary>
        /// <exception cref="System.IO.IOException"/>
        public virtual bool Next(K key, V value)
        {
            if (jc.Flush(ivalue))
            {
                WritableUtils.CloneInto(key, jc.Key());
                WritableUtils.CloneInto(value, Emit(ivalue));
                return(true);
            }
            jc.Clear();
            K iterkey = CreateKey();
            PriorityQueue <ComposableRecordReader <K, object> > q = GetRecordReaderQueue();

            while (!q.IsEmpty())
            {
                FillJoinCollector(iterkey);
                jc.Reset(iterkey);
                if (jc.Flush(ivalue))
                {
                    WritableUtils.CloneInto(key, jc.Key());
                    WritableUtils.CloneInto(value, Emit(ivalue));
                    return(true);
                }
                jc.Clear();
            }
            return(false);
        }
Esempio n. 2
0
            /// <exception cref="System.IO.IOException"/>
            public virtual bool Next(V val)
            {
                bool ret;

                if (ret = this._enclosing.jc.Flush(this._enclosing.ivalue))
                {
                    WritableUtils.CloneInto(val, this._enclosing.Emit(this._enclosing.ivalue));
                }
                return(ret);
            }
Esempio n. 3
0
 /// <summary>
 /// Write key-value pair at the head of this stream to the objects provided;
 /// get next key-value pair from proxied RR.
 /// </summary>
 /// <exception cref="System.IO.IOException"/>
 public virtual bool Next(K key, U value)
 {
     if (HasNext())
     {
         WritableUtils.CloneInto(key, khead);
         WritableUtils.CloneInto(value, vhead);
         Next();
         return(true);
     }
     return(false);
 }
Esempio n. 4
0
 /// <summary>Clone the key at the head of this RR into the object supplied.</summary>
 /// <exception cref="System.IO.IOException"/>
 public virtual void Key(K qkey)
 {
     WritableUtils.CloneInto(qkey, khead);
 }
Esempio n. 5
0
 /// <exception cref="System.IO.IOException"/>
 public virtual bool Replay(V val)
 {
     WritableUtils.CloneInto(val, this._enclosing.Emit(this._enclosing.ivalue));
     return(true);
 }
Esempio n. 6
0
 /// <summary>Clone the key at the top of this RR into the given object.</summary>
 /// <exception cref="System.IO.IOException"/>
 public virtual void Key(K key)
 {
     WritableUtils.CloneInto(key, Key());
 }