org.keycloak.models.map.common

## Class StreamUtils.AbstractToPairSpliterator<K,V,M>

- java.lang.Object
- - org.keycloak.models.map.common.StreamUtils.AbstractToPairSpliterator<K,V,M>

- All Implemented Interfaces:
    Spliterator<StreamUtils.Pair<K,V>>
  Enclosing class:
    StreamUtils

      public abstract static class StreamUtils.AbstractToPairSpliterator<K,V,M>
      extends Object
      implements Spliterator<StreamUtils.Pair<K,V>>

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface java.util.Spliterator

      `Spliterator.OfDouble, Spliterator.OfInt, Spliterator.OfLong, Spliterator.OfPrimitive<T,T_CONS,T_SPLITR extends Spliterator.OfPrimitive<T,T_CONS,T_SPLITR>>`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected K` | `currentKey`
    `protected Iterator<V>` | `flatMapIterator`
    `protected M` | `mapper`
    `protected Iterator<K>` | `streamIterator`

    - ### Fields inherited from interface java.util.Spliterator

      `CONCURRENT, DISTINCT, IMMUTABLE, NONNULL, ORDERED, SIZED, SORTED, SUBSIZED`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractToPairSpliterator(Stream<K> stream, M mapper)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `characteristics()`
    `long` | `estimateSize()`
    `protected abstract void` | `nextKey()`
    `boolean` | `tryAdvance(Consumer<? super StreamUtils.Pair<K,V>> action)`
    `Spliterator<StreamUtils.Pair<K,V>>` | `trySplit()`

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

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

    - ### Methods inherited from interface java.util.Spliterator

      `forEachRemaining, getComparator, getExactSizeIfKnown, hasCharacteristics`

- - ### Field Detail

    - #### streamIterator

          protected final Iterator<K> streamIterator

    - #### mapper

          protected final M mapper

    - #### flatMapIterator

          protected Iterator<V> flatMapIterator

    - #### currentKey

          protected K currentKey

  - ### Constructor Detail

    - #### AbstractToPairSpliterator

          public AbstractToPairSpliterator(Stream<K> stream,
                                           M mapper)

  - ### Method Detail

    - #### nextKey

          protected abstract void nextKey()

    - #### tryAdvance

          public boolean tryAdvance(Consumer<? super StreamUtils.Pair<K,V>> action)

      Specified by:
        `tryAdvance` in interface `Spliterator<StreamUtils.Pair<K,V>>`

    - #### trySplit

          public Spliterator<StreamUtils.Pair<K,V>> trySplit()

      Specified by:
        `trySplit` in interface `Spliterator<StreamUtils.Pair<K,V>>`

    - #### estimateSize

          public long estimateSize()

      Specified by:
        `estimateSize` in interface `Spliterator<StreamUtils.Pair<K,V>>`

    - #### characteristics

          public int characteristics()

      Specified by:
        `characteristics` in interface `Spliterator<StreamUtils.Pair<K,V>>`

Copyright © 2020 JBoss by Red Hat. All rights reserved.