Documentation
¶
Index ¶
- Constants
- func NewRange[TValue constraints.Float | constraints.Integer](args ...TValue) compounditerators.ReadForIndexIterator[int, TValue]
- func NewRepeat[TValue any](generator func() (TValue, bool), limit int) compounditerators.ReadForIndexIterator[int, TValue]
- type Range
- func (it *Range[TValue]) Get() (value TValue, found bool)
- func (it *Range[TValue]) GetKey() (value int, found bool)
- func (it *Range[TValue]) Index() (int, bool)
- func (it *Range[TValue]) IsBegin() bool
- func (it *Range[TValue]) IsEnd() bool
- func (it *Range[TValue]) IsFirst() bool
- func (it *Range[TValue]) IsLast() bool
- func (it *Range[TValue]) IsValid() bool
- func (it *Range[TValue]) Next() bool
- func (it *Range[TValue]) NextN(n int) bool
- func (it *Range[TValue]) Size() int
- type Repeat
- func (it *Repeat[TValue]) Get() (value TValue, found bool)
- func (it *Repeat[TValue]) GetKey() (int, bool)
- func (it *Repeat[TValue]) Index() (int, bool)
- func (it *Repeat[TValue]) IsBegin() bool
- func (it *Repeat[TValue]) IsEnd() bool
- func (it *Repeat[TValue]) IsFirst() bool
- func (it *Repeat[TValue]) IsLast() bool
- func (it *Repeat[TValue]) IsValid() bool
- func (it *Repeat[TValue]) Next() bool
- func (it *Repeat[TValue]) NextN(n int) bool
- func (it *Repeat[TValue]) Size() int
Constants ¶
View Source
const ( ErrorNegativeRange = "range must be increasing" ErrorUncleanStep = "step would overshoot stop" ErrorTooManyArgs = "the number of args must be in the range of [0,3]" )
Variables ¶
This section is empty.
Functions ¶
func NewRange ¶
func NewRange[TValue constraints.Float | constraints.Integer](args ...TValue) compounditerators.ReadForIndexIterator[int, TValue]
func NewRepeat ¶
func NewRepeat[TValue any](generator func() (TValue, bool), limit int) compounditerators.ReadForIndexIterator[int, TValue]
Types ¶
type Range ¶
type Range[TValue constraints.Float | constraints.Integer] struct { // contains filtered or unexported fields }
Click to show internal directories.
Click to hide internal directories.