Esempio n. 1
0
                public bool MoveNext()
                {
                    ThrowIfDisposed();
                    int start = source.Position + 1;
                    int len   = source.Source.length + 1;

                    for (int i = start; i < len; i++)
                    {
                        if (!source.MoveNext())
                        {
                            current = source.Source.Substring(start, i - start);
                            return(true);
                        }
                        source.Position = i - 1;
                        separator.Reset();
                        int slen = separator.Source.length;
                        if (EqualsChunk(ref source, ref separator, slen))
                        {
                            i      += slen;
                            current = source.Source.Substring(start, i - start - slen);
                            return(true);
                        }
                        else
                        {
                            source.Position = i - slen + 2;
                        }
                    }
                    return(false);
                }
Esempio n. 2
0
 public void Reset()
 {
     ThrowIfDisposed();
     source.Reset();
 }