/// <summary> /// Gets the parts of a buffer that are stored, within a specified range. /// </summary> /// <param name="start">The offset of the first byte of interest.</param> /// <param name="count">The number of bytes of interest.</param> /// <returns>An enumeration of stream extents, indicating stored bytes.</returns> public override IEnumerable <StreamExtent> GetExtentsInRange(long start, long count) { long absStart = _first + start; long absEnd = Math.Min(absStart + count, _first + _length); return(OffsetExtents(_parent.GetExtentsInRange(absStart, absEnd - absStart))); }
/// <summary> /// Gets the parts of a stream that are stored, within a specified range. /// </summary> /// <param name="start">The offset of the first byte of interest.</param> /// <param name="count">The number of bytes of interest.</param> /// <returns>An enumeration of stream extents, indicating stored bytes.</returns> public override IEnumerable <StreamExtent> GetExtentsInRange(long start, long count) { return(_buffer.GetExtentsInRange(start, count)); }