de.caff.generics.util.combi

## Class Combinations.OfRange

- java.lang.Object
- - de.caff.generics.util.combi.Combinations.OfRange

- All Implemented Interfaces:
    java.lang.Iterable<IntIndexable>
  Enclosing class:
    Combinations<T>

      public static class Combinations.OfRange
      extends java.lang.Object
      implements java.lang.Iterable<IntIndexable>

  The combinations of an index range.

  The iterator will return an indexable with integer values, and you can use these values as indices into any set you have, although in most cases using the enclosing class `Combinations` is simpler because it already handles this for you.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `OfRange(int n, int k)` Constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getSize()` Get the size of the range.
    `java.util.Iterator<IntIndexable>` | `iterator()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface java.lang.Iterable

      `forEach, spliterator`

- - ### Constructor Detail

    - #### OfRange

          public OfRange(int n,
                         int k)

      Constructor.
      Parameters:
        `n` - size of the range, non-negative
        `k` - size of the subset to be chosen, non-negative and not more than `n`

  - ### Method Detail

    - #### getSize

          public int getSize()

      Get the size of the range.
      Returns:
        size of this range

    - #### iterator

          @NotNull
          public java.util.Iterator<IntIndexable> iterator()

      Specified by:
        `iterator` in interface `java.lang.Iterable<IntIndexable>`