Interface LinkedHashMapRowReducer<K,V>

Type Parameters:
K - the map key type--often the primary key type of <V>.
V - the map value type, and the result element type--often the "master" object in a master/detail relation.
All Superinterfaces:
RowReducer<Map<K,V>,V>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface LinkedHashMapRowReducer<K,V> extends RowReducer<Map<K,V>,V>
A row reducer that uses LinkedHashMap (which preserves insertion order) as a result container, and returns map.values().stream() as the final result.

Implementors need only implement the RowReducer.accumulate(Object, RowView) method.

  • Method Summary

    Modifier and Type
    Method
    Description
    default Map<K,V>
    Returns a new, empty result container.
    default Stream<V>
    stream(Map<K,V> container)
    Returns a stream of result elements from the result container.

    Methods inherited from interface org.jdbi.v3.core.result.RowReducer

    accumulate
  • Method Details

    • container

      default Map<K,V> container()
      Description copied from interface: RowReducer
      Returns a new, empty result container.
      Specified by:
      container in interface RowReducer<K,V>
      Returns:
      a new result container.
    • stream

      default Stream<V> stream(Map<K,V> container)
      Description copied from interface: RowReducer
      Returns a stream of result elements from the result container.
      Specified by:
      stream in interface RowReducer<K,V>
      Parameters:
      container - the result container
      Returns:
      stream of result elements.