Documentation ¶
Overview ¶
Package iterator provides a built-in implementation of an ideomatic generic iterator
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type T0 ¶
type T0 string
T0 is a generic type variable placeholder of an iterator element. It will not appear in the generated code
type T0GeneratorFunc ¶
T0GeneratorFunc is a function that should generate elements and send them to a given channel
func T0SliceGenerator ¶
func T0SliceGenerator(src []T0) T0GeneratorFunc
T0SliceGenerator generates elements from a given slice
type T0Iter ¶
type T0Iter interface { // Err returns error if it happened during generation Err() error // Next returns next element from iterator Next() <-chan T0 }
T0Iter implements iterator over T0 type elements
func Generate ¶
func Generate(f T0GeneratorFunc) T0Iter
Generate creates Iterator from generator func
Click to show internal directories.
Click to hide internal directories.