Interface Jdbc.BiRowMapper<T>

Type Parameters:
T -
All Superinterfaces:
com.landawn.abacus.util.Throwables.BiFunction<ResultSet,List<String>,T,SQLException>
Enclosing class:
Jdbc
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 static interface Jdbc.BiRowMapper<T> extends com.landawn.abacus.util.Throwables.BiFunction<ResultSet,List<String>,T,SQLException>
The Interface BiRowMapper.
  • Field Details

  • Method Details

    • apply

      T apply(ResultSet rs, List<String> columnLabels) throws SQLException
      Specified by:
      apply in interface com.landawn.abacus.util.Throwables.BiFunction<ResultSet,List<String>,T,SQLException>
      Parameters:
      rs -
      columnLabels -
      Returns:
      Throws:
      SQLException
    • andThen

      default <R> Jdbc.BiRowMapper<R> andThen(com.landawn.abacus.util.Throwables.Function<? super T,? extends R,SQLException> after)
      Type Parameters:
      R -
      Parameters:
      after -
      Returns:
    • toRowMapper

      @Beta @Deprecated @Stateful default Jdbc.RowMapper<T> toRowMapper()
      Deprecated.
      because it's stateful and may be misused easily&frequently
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Returns:
      See Also:
    • combine

      static <T, U> Jdbc.BiRowMapper<com.landawn.abacus.util.Tuple.Tuple2<T,U>> combine(Jdbc.BiRowMapper<? extends T> rowMapper1, Jdbc.BiRowMapper<? extends U> rowMapper2)
      Type Parameters:
      T -
      U -
      Parameters:
      rowMapper1 -
      rowMapper2 -
      Returns:
    • combine

      static <A, B, C> Jdbc.BiRowMapper<com.landawn.abacus.util.Tuple.Tuple3<A,B,C>> combine(Jdbc.BiRowMapper<? extends A> rowMapper1, Jdbc.BiRowMapper<? extends B> rowMapper2, Jdbc.BiRowMapper<? extends C> rowMapper3)
      Type Parameters:
      A -
      B -
      C -
      Parameters:
      rowMapper1 -
      rowMapper2 -
      rowMapper3 -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> targetClass)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Type Parameters:
      T -
      Parameters:
      targetClass -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> targetClass, boolean ignoreNonMatchedColumns)
      Don't cache or reuse the returned BiRowMapper instance. It's stateful.
      Type Parameters:
      T -
      Parameters:
      targetClass -
      ignoreNonMatchedColumns -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> targetClass, Predicate<? super String> columnNameFilter, Function<? super String,String> columnNameConverter)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Type Parameters:
      T -
      Parameters:
      targetClass -
      columnNameFilter -
      columnNameConverter -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> targetClass, Predicate<? super String> columnNameFilter, Function<? super String,String> columnNameConverter, boolean ignoreNonMatchedColumns)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Type Parameters:
      T -
      Parameters:
      targetClass -
      columnNameFilter -
      columnNameConverter -
      ignoreNonMatchedColumns -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> entityClass, Map<String,String> prefixAndFieldNameMap)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Type Parameters:
      T -
      Parameters:
      entityClass -
      prefixAndFieldNameMap -
      Returns:
    • to

      @SequentialOnly @Stateful static <T> Jdbc.BiRowMapper<T> to(Class<? extends T> entityClass, Map<String,String> prefixAndFieldNameMap, boolean ignoreNonMatchedColumns)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Type Parameters:
      T -
      Parameters:
      entityClass -
      prefixAndFieldNameMap -
      ignoreNonMatchedColumns -
      Returns:
    • toMap

      static Jdbc.BiRowMapper<Map<String,Object>> toMap(Predicate<Object> valueFilter)
      Parameters:
      valueFilter -
      Returns:
    • toMap

      static Jdbc.BiRowMapper<Map<String,Object>> toMap(BiPredicate<String,Object> valueFilter, IntFunction<Map<String,Object>> mapSupplier)
      Parameters:
      valueFilter -
      mapSupplier -
      Returns:
    • toMap

      @SequentialOnly @Stateful static Jdbc.BiRowMapper<Map<String,Object>> toMap(Jdbc.RowExtractor rowExtractor, BiPredicate<String,Object> valueFilter, IntFunction<Map<String,Object>> mapSupplier)
      Parameters:
      rowExtractor -
      valueFilter -
      mapSupplier -
      Returns:
    • toMap

      @SequentialOnly @Stateful static Jdbc.BiRowMapper<Map<String,Object>> toMap(Function<? super String,String> columnNameConverter)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Parameters:
      columnNameConverter -
      Returns:
    • toMap

      @SequentialOnly @Stateful static Jdbc.BiRowMapper<Map<String,Object>> toMap(Function<? super String,String> columnNameConverter, IntFunction<Map<String,Object>> mapSupplier)
      Parameters:
      columnNameConverter -
      mapSupplier -
      Returns:
    • toMap

      @SequentialOnly @Stateful static Jdbc.BiRowMapper<Map<String,Object>> toMap(Jdbc.RowExtractor rowExtractor, Function<? super String,String> columnNameConverter, IntFunction<Map<String,Object>> mapSupplier)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Parameters:
      rowExtractor -
      columnNameConverter -
      mapSupplier -
      Returns:
    • toMap

      @SequentialOnly @Stateful static Jdbc.BiRowMapper<Map<String,Object>> toMap(Jdbc.RowExtractor rowExtractor)
      Parameters:
      rowExtractor -
      Returns:
    • toArray

      @Beta static Jdbc.BiRowMapper<Object[]> toArray(Jdbc.ColumnGetter<?> columnGetterForAll)
      Parameters:
      columnGetterForAll -
      Returns:
    • toList

      @Beta static Jdbc.BiRowMapper<List<Object>> toList(Jdbc.ColumnGetter<?> columnGetterForAll)
      Parameters:
      columnGetterForAll -
      Returns:
    • toCollection

      @Beta static <C extends Collection<?>> Jdbc.BiRowMapper<C> toCollection(Jdbc.ColumnGetter<?> columnGetterForAll, IntFunction<C> supplier)
      Parameters:
      columnGetterForAll -
      supplier -
      Returns:
    • toDisposableObjArray

      @Beta @SequentialOnly @Stateful static Jdbc.BiRowMapper<com.landawn.abacus.util.NoCachingNoUpdating.DisposableObjArray> toDisposableObjArray()
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Returns:
    • toDisposableObjArray

      @Beta @SequentialOnly @Stateful static Jdbc.BiRowMapper<com.landawn.abacus.util.NoCachingNoUpdating.DisposableObjArray> toDisposableObjArray(Class<?> entityClass)
      It's stateful. Don't save or cache the returned instance for reuse or use it in parallel stream.
      Parameters:
      entityClass - used to fetch column/row value from ResultSet by the type of fields/columns defined in this class.
      Returns:
    • builder

      Returns:
    • builder

      static Jdbc.BiRowMapper.BiRowMapperBuilder builder(Jdbc.ColumnGetter<?> defaultColumnGetter)
      Parameters:
      defaultColumnGetter -
      Returns: