eotransform.transformers.repeat.Repeat

class Repeat(n: int)[source]

Bases: Transformer[RepeatedT, Iterator[RepeatedT]]

Repeat the input n times and return an iterator which can for instance be used to create a collection, such as list. >>> list(Repeat(3)(42)) [42, 42, 42]

Parameters:

n – Number of times the input is repeated.

Methods