Skip to content

Commit

Permalink
Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
nathan-artie committed Mar 29, 2024
1 parent b0bd5a8 commit 0250f1e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ type batchIterator[T any] struct {
batches [][]T
}

// Returns an iterator that returns multiple batches.
// Returns an iterator that produces multiple batches.
func NewBatchIterator[T any](batches [][]T) *batchIterator[T] {
return &batchIterator[T]{batches: batches}
}

// Returns an iterator that returns a single batch.
// Returns an iterator that produces a single batch.
func NewSingleBatchIterator[T any](batches []T) *batchIterator[T] {
return NewBatchIterator([][]T{batches})
}
Expand Down

0 comments on commit 0250f1e

Please sign in to comment.