public void Seek(long postion, BssomSeekOrgin orgin, long limit) { if (orgin == BssomSeekOrgin.Current) { Position += postion; } else { Position = postion; } if (limit != -1 && Position > limit) { BssomSerializationOperationException.ReaderEndOfBufferException(); } if (Spans.Length == 1) { CurrentSpanPosition = (int)Position; } else { CurrentSpanIndex = Array.BinarySearch(SpansCumulativeBoundary, Position); if (CurrentSpanIndex <= -1) { CurrentSpanIndex = ~CurrentSpanIndex - 1; } CurrentSpanPosition = (int)(Position - SpansCumulativeBoundary[CurrentSpanIndex]); } }
public void Seek(long postion, BssomSeekOrgin orgin = BssomSeekOrgin.Begin) { SeekWithOutVerify(postion, orgin); if (position > Length) { BssomSerializationOperationException.ReaderEndOfBufferException(); } }
public void Seek(long postion, BssomSeekOrgin orgin) { SeekWithOutVerify(postion, orgin); if (_offset > _buffer.Length) { BssomSerializationOperationException.ReaderEndOfBufferException(); } }
public void SeekWithOutVerify(long postion, BssomSeekOrgin orgin) { if (orgin == BssomSeekOrgin.Current) { position += (int)postion; } else { position = (int)postion; } }
//Call: reader.Buffer.Seek(pos) public static Expression Call_Reader_BufferSeek(Expression pos, BssomSeekOrgin orgin = BssomSeekOrgin.Begin) { return(Expression.Call(Field_ReaderBuffer, Type_Buffer_Seek, pos, Expression.Constant(orgin, typeof(BssomSeekOrgin)))); }
public void Seek(long position, BssomSeekOrgin orgin = BssomSeekOrgin.Begin) { complexBuffer.Seek(position, orgin, Buffered); }
public void SeekWithOutVerify(long postion, BssomSeekOrgin orgin) { complexBuffer.SeekWithOutVerify(postion, orgin); }
public void Seek(long postion, BssomSeekOrgin orgin) { Seek(postion, orgin, Boundary); }
public void SeekWithOutVerify(long postion, BssomSeekOrgin orgin) { Seek(postion, orgin, -1); }