| 34 | namespace io { |
| 35 | |
| 36 | struct ReadRange { |
| 37 | int64_t offset; |
| 38 | int64_t length; |
| 39 | |
| 40 | friend bool operator==(const ReadRange& left, const ReadRange& right) { |
| 41 | return (left.offset == right.offset && left.length == right.length); |
| 42 | } |
| 43 | friend bool operator!=(const ReadRange& left, const ReadRange& right) { |
| 44 | return !(left == right); |
| 45 | } |
| 46 | |
| 47 | bool Contains(const ReadRange& other) const { |
| 48 | return (offset <= other.offset && offset + length >= other.offset + other.length); |
| 49 | } |
| 50 | }; |
| 51 | |
| 52 | /// EXPERIMENTAL: options provider for IO tasks |
| 53 | /// |
no outgoing calls
no test coverage detected