MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / apply_offset

Method apply_offset

src/expr/src/row/collection.rs:219–231  ·  view source on GitHub ↗

Immediately applies an offset to this iterator.

(mut self, offset: usize)

Source from the content-addressed store, hash-verified

217
218 /// Immediately applies an offset to this iterator.
219 pub fn apply_offset(mut self, offset: usize) -> RowCollectionIter {
220 Self::advance_by(
221 &self.collection,
222 &mut self.row_idx,
223 &mut self.diff_idx,
224 offset,
225 );
226
227 // Keep track of how many rows we've offset by.
228 self.offset = self.offset.saturating_add(offset);
229
230 self
231 }
232
233 /// Sets the limit for this iterator.
234 pub fn with_limit(mut self, limit: usize) -> RowCollectionIter {

Callers 4

finish_innerMethod · 0.80
test_sorted_iter_offsetFunction · 0.80

Calls 1

saturating_addMethod · 0.80

Tested by 2

test_sorted_iter_offsetFunction · 0.64