Class Repeated<T>

  • Type Parameters:
    T - Element type
    All Implemented Interfaces:
    Iterable<T>

    public final class Repeated<T>
    extends IterableEnvelope<T>
    Repeat an element.

    If you need to repeat endlessly, use Endless.

    Since:
    0.1
    • Constructor Detail

      • Repeated

        public Repeated​(int total,
                        T elm)
        Ctor.
        Parameters:
        total - The total number of repetitions
        elm - The element to repeat
      • Repeated

        public Repeated​(int total,
                        Scalar<? extends T> elm)
        Ctor.
        Parameters:
        total - The total number of repetitions
        elm - The element to repeat