diff --git a/jOOQ/src/main/java/org/jooq/Records.java b/jOOQ/src/main/java/org/jooq/Records.java index 7bbb76c228..7a269b1df6 100644 --- a/jOOQ/src/main/java/org/jooq/Records.java +++ b/jOOQ/src/main/java/org/jooq/Records.java @@ -95,7 +95,7 @@ public final class Records { * .fetch(BOOK.TITLE); * */ - public static final > Collector> toList() { + public static final > Collector> intoList() { return Collectors.mapping(Record1::value1, Collectors.toCollection(ArrayList::new)); } @@ -121,7 +121,7 @@ public final class Records { * .fetch(BOOK.TITLE); * */ - public static final Collector> toList(Function function) { + public static final Collector> intoList(Function function) { return Collectors.mapping(function, Collectors.toCollection(ArrayList::new)); } @@ -149,8 +149,8 @@ public final class Records { * .fetchSet(BOOK.TITLE); * */ - public static final > Collector> toSet() { - return toSet(Record1::value1); + public static final > Collector> intoSet() { + return intoSet(Record1::value1); } /** @@ -175,7 +175,7 @@ public final class Records { * .fetchSet(BOOK.TITLE); * */ - public static final Collector> toSet(Function function) { + public static final Collector> intoSet(Function function) { return Collectors.mapping(function, Collectors.toCollection(LinkedHashSet::new)); } @@ -206,8 +206,8 @@ public final class Records { * .fetchMap(BOOK.ID, BOOK.TITLE); * */ - public static final > Collector> toMap() { - return toMap(Record2::value1, Record2::value2); + public static final > Collector> intoMap() { + return intoMap(Record2::value1, Record2::value2); } /** @@ -236,8 +236,8 @@ public final class Records { * .fetchMap(BOOK.ID); * */ - public static final Collector> toMap(Function keyMapper) { - return toMap(keyMapper, r -> r); + public static final Collector> intoMap(Function keyMapper) { + return intoMap(keyMapper, r -> r); } /** @@ -267,7 +267,7 @@ public final class Records { * .fetchMap(BOOK.ID, BOOK.TITLE); * */ - public static final Collector> toMap( + public static final Collector> intoMap( Function keyMapper, Function valueMapper ) { @@ -305,8 +305,8 @@ public final class Records { * .fetchGroups(BOOK.ID, BOOK.TITLE); * */ - public static final > Collector>> toGroups() { - return toGroups(Record2::value1, Record2::value2); + public static final > Collector>> intoGroups() { + return intoGroups(Record2::value1, Record2::value2); } /** @@ -334,7 +334,7 @@ public final class Records { * */ @SuppressWarnings("unchecked") - public static final Collector>> toGroups(Function keyMapper) { + public static final Collector>> intoGroups(Function keyMapper) { return Collectors.groupingBy( keyMapper, LinkedHashMap::new, @@ -379,7 +379,7 @@ public final class Records { * .fetchGroups(BOOK.ID, BOOK.TITLE); * */ - public static final Collector>> toGroups( + public static final Collector>> intoGroups( Function keyMapper, Function valueMapper ) { diff --git a/jOOQ/src/main/java/org/jooq/impl/ResultImpl.java b/jOOQ/src/main/java/org/jooq/impl/ResultImpl.java index 847ee1e1d4..dc66d3edbf 100644 --- a/jOOQ/src/main/java/org/jooq/impl/ResultImpl.java +++ b/jOOQ/src/main/java/org/jooq/impl/ResultImpl.java @@ -38,10 +38,7 @@ package org.jooq.impl; -import static org.jooq.Records.toGroups; -import static org.jooq.Records.toList; -import static org.jooq.Records.toMap; -import static org.jooq.Records.toSet; +import static org.jooq.Records.intoList; import static org.jooq.impl.Tools.EMPTY_FIELD; import static org.jooq.impl.Tools.converterOrFail; import static org.jooq.impl.Tools.indexOrFail; @@ -183,7 +180,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final List getValues(Field field) { - return collect(toList(recordType().mapper(field))); + return collect(intoList(recordType().mapper(field))); } @Override @@ -200,7 +197,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final List getValues(int fieldIndex) { - return collect(toList(recordType().mapper(fieldIndex))); + return collect(intoList(recordType().mapper(fieldIndex))); } @Override @@ -218,7 +215,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final List getValues(String fieldName) { - return collect(toList(recordType().mapper(fieldName))); + return collect(intoList(recordType().mapper(fieldName))); } @Override @@ -235,7 +232,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final List getValues(Name fieldName) { - return collect(toList(recordType().mapper(fieldName))); + return collect(intoList(recordType().mapper(fieldName))); } @Override @@ -261,42 +258,42 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Map intoMap(Field key) { - return collect(toMap(recordType().mapper(key))); + return collect(Records.intoMap(recordType().mapper(key))); } @Override public final Map intoMap(int keyFieldIndex) { - return collect(toMap(recordType().mapper(keyFieldIndex))); + return collect(Records.intoMap(recordType().mapper(keyFieldIndex))); } @Override public final Map intoMap(String keyFieldName) { - return collect(toMap(recordType().mapper(keyFieldName))); + return collect(Records.intoMap(recordType().mapper(keyFieldName))); } @Override public final Map intoMap(Name keyFieldName) { - return collect(toMap(recordType().mapper(keyFieldName))); + return collect(Records.intoMap(recordType().mapper(keyFieldName))); } @Override public final Map intoMap(Field key, Field value) { - return collect(toMap(recordType().mapper(key), recordType().mapper(value))); + return collect(Records.intoMap(recordType().mapper(key), recordType().mapper(value))); } @Override public final Map intoMap(int keyFieldIndex, int valueFieldIndex) { - return collect(toMap(recordType().mapper(keyFieldIndex), recordType().mapper(valueFieldIndex))); + return collect(Records.intoMap(recordType().mapper(keyFieldIndex), recordType().mapper(valueFieldIndex))); } @Override public final Map intoMap(String keyFieldName, String valueFieldName) { - return collect(toMap(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); + return collect(Records.intoMap(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); } @Override public final Map intoMap(Name keyFieldName, Name valueFieldName) { - return collect(toMap(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); + return collect(Records.intoMap(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); } @Override @@ -424,172 +421,172 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Map intoMap(Class keyType) { - return collect(toMap(recordType().mapper(Tools.configuration(this), keyType))); + return collect(Records.intoMap(recordType().mapper(Tools.configuration(this), keyType))); } @Override public final Map intoMap(Class keyType, Class valueType) { - return collect(toMap(recordType().mapper(Tools.configuration(this), keyType), recordType().mapper(Tools.configuration(this), valueType))); + return collect(Records.intoMap(recordType().mapper(Tools.configuration(this), keyType), recordType().mapper(Tools.configuration(this), valueType))); } @Override public final Map intoMap(Class keyType, RecordMapper valueMapper) { - return collect(toMap(recordType().mapper(Tools.configuration(this), keyType), valueMapper)); + return collect(Records.intoMap(recordType().mapper(Tools.configuration(this), keyType), valueMapper)); } @Override public final Map intoMap(RecordMapper keyMapper) { - return collect(toMap(keyMapper)); + return collect(Records.intoMap(keyMapper)); } @Override public final Map intoMap(RecordMapper keyMapper, Class valueType) { - return collect(toMap(keyMapper, recordType().mapper(Tools.configuration(this), valueType))); + return collect(Records.intoMap(keyMapper, recordType().mapper(Tools.configuration(this), valueType))); } @Override public final Map intoMap(RecordMapper keyMapper, RecordMapper valueMapper) { - return collect(toMap(keyMapper, valueMapper)); + return collect(Records.intoMap(keyMapper, valueMapper)); } @Override public final Map intoMap(Table table) { - return collect(toMap(recordType().mapper(table))); + return collect(Records.intoMap(recordType().mapper(table))); } @Override public final Map intoMap(Table keyTable, Table valueTable) { - return collect(toMap(recordType().mapper(keyTable), recordType().mapper(valueTable))); + return collect(Records.intoMap(recordType().mapper(keyTable), recordType().mapper(valueTable))); } @Override public final Map intoMap(Table table, Class type) { - return collect(toMap(recordType().mapper(table), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(recordType().mapper(table), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map intoMap(Table table, RecordMapper mapper) { - return collect(toMap(recordType().mapper(table), mapper)); + return collect(Records.intoMap(recordType().mapper(table), mapper)); } @Override public final Map intoMap(int keyFieldIndex, Class type) { - return collect(toMap(recordType().mapper(keyFieldIndex), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(recordType().mapper(keyFieldIndex), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map intoMap(String keyFieldName, Class type) { - return collect(toMap(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map intoMap(Name keyFieldName, Class type) { - return collect(toMap(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map intoMap(Field key, Class type) { - return collect(toMap(recordType().mapper(key), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(recordType().mapper(key), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map intoMap(int keyFieldIndex, RecordMapper mapper) { - return collect(toMap(recordType().mapper(keyFieldIndex), mapper)); + return collect(Records.intoMap(recordType().mapper(keyFieldIndex), mapper)); } @Override public final Map intoMap(String keyFieldName, RecordMapper mapper) { - return collect(toMap(recordType().mapper(keyFieldName), mapper)); + return collect(Records.intoMap(recordType().mapper(keyFieldName), mapper)); } @Override public final Map intoMap(Name keyFieldName, RecordMapper mapper) { - return collect(toMap(recordType().mapper(keyFieldName), mapper)); + return collect(Records.intoMap(recordType().mapper(keyFieldName), mapper)); } @Override public final Map intoMap(Field key, RecordMapper mapper) { - return collect(toMap(recordType().mapper(key), mapper)); + return collect(Records.intoMap(recordType().mapper(key), mapper)); } @Override public final Map> intoGroups(Field key) { - return collect(toGroups(recordType().mapper(key))); + return collect(Records.intoGroups(recordType().mapper(key))); } @Override public final Map> intoGroups(int keyFieldIndex) { - return collect(toGroups(recordType().mapper(keyFieldIndex))); + return collect(Records.intoGroups(recordType().mapper(keyFieldIndex))); } @Override public final Map> intoGroups(String keyFieldName) { - return collect(toGroups(recordType().mapper(keyFieldName))); + return collect(Records.intoGroups(recordType().mapper(keyFieldName))); } @Override public final Map> intoGroups(Name keyFieldName) { - return collect(toGroups(recordType().mapper(keyFieldName))); + return collect(Records.intoGroups(recordType().mapper(keyFieldName))); } @Override public final Map> intoGroups(Field key, Field value) { - return collect(toGroups(recordType().mapper(key), recordType().mapper(value))); + return collect(Records.intoGroups(recordType().mapper(key), recordType().mapper(value))); } @Override public final Map> intoGroups(int keyFieldIndex, int valueFieldIndex) { - return (Map) collect(toGroups(recordType().mapper(keyFieldIndex), recordType().mapper(valueFieldIndex))); + return (Map) collect(Records.intoGroups(recordType().mapper(keyFieldIndex), recordType().mapper(valueFieldIndex))); } @Override public final Map> intoGroups(String keyFieldName, String valueFieldName) { - return (Map) collect(toGroups(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); + return (Map) collect(Records.intoGroups(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); } @Override public final Map> intoGroups(Name keyFieldName, Name valueFieldName) { - return (Map) collect(toGroups(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); + return (Map) collect(Records.intoGroups(recordType().mapper(keyFieldName), recordType().mapper(valueFieldName))); } @Override public final Map> intoGroups(int keyFieldIndex, Class type) { - return collect(toGroups(recordType().mapper(keyFieldIndex), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(recordType().mapper(keyFieldIndex), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map> intoGroups(String keyFieldName, Class type) { - return collect(toGroups(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map> intoGroups(Name keyFieldName, Class type) { - return collect(toGroups(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(recordType().mapper(keyFieldName), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map> intoGroups(Field key, Class type) { - return collect(toGroups(recordType().mapper(key), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(recordType().mapper(key), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map> intoGroups(Field key, RecordMapper mapper) { - return collect(toGroups(recordType().mapper(key), mapper)); + return collect(Records.intoGroups(recordType().mapper(key), mapper)); } @Override public final Map> intoGroups(int keyFieldIndex, RecordMapper mapper) { - return collect(toGroups(recordType().mapper(keyFieldIndex), mapper)); + return collect(Records.intoGroups(recordType().mapper(keyFieldIndex), mapper)); } @Override public final Map> intoGroups(String keyFieldName, RecordMapper mapper) { - return collect(toGroups(recordType().mapper(keyFieldName), mapper)); + return collect(Records.intoGroups(recordType().mapper(keyFieldName), mapper)); } @Override public final Map> intoGroups(Name keyFieldName, RecordMapper mapper) { - return collect(toGroups(recordType().mapper(keyFieldName), mapper)); + return collect(Records.intoGroups(recordType().mapper(keyFieldName), mapper)); } @Override @@ -715,42 +712,42 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Map> intoGroups(Class keyType) { - return collect(toGroups(recordType().mapper(Tools.configuration(this), keyType))); + return collect(Records.intoGroups(recordType().mapper(Tools.configuration(this), keyType))); } @Override public final Map> intoGroups(Class keyType, Class valueType) { - return collect(toGroups(recordType().mapper(Tools.configuration(this), keyType), recordType().mapper(Tools.configuration(this), valueType))); + return collect(Records.intoGroups(recordType().mapper(Tools.configuration(this), keyType), recordType().mapper(Tools.configuration(this), valueType))); } @Override public final Map> intoGroups(Class keyType, RecordMapper valueMapper) { - return collect(toGroups(recordType().mapper(Tools.configuration(this), keyType), valueMapper)); + return collect(Records.intoGroups(recordType().mapper(Tools.configuration(this), keyType), valueMapper)); } @Override public final Map> intoGroups(RecordMapper keyMapper) { - return collect(toGroups(keyMapper)); + return collect(Records.intoGroups(keyMapper)); } @Override public final Map> intoGroups(RecordMapper keyMapper, Class valueType) { - return collect(toGroups(keyMapper, recordType().mapper(Tools.configuration(this), valueType))); + return collect(Records.intoGroups(keyMapper, recordType().mapper(Tools.configuration(this), valueType))); } @Override public final Map> intoGroups(RecordMapper keyMapper, RecordMapper valueMapper) { - return collect(toGroups(keyMapper, valueMapper)); + return collect(Records.intoGroups(keyMapper, valueMapper)); } @Override public final Map> intoGroups(Table table) { - return collect(toGroups(recordType().mapper(table))); + return collect(Records.intoGroups(recordType().mapper(table))); } @Override public final Map> intoGroups(Table keyTable, Table valueTable) { - // [#9288] TODO: Can't use collect(toGroups(recordType().mapper(keyTable), recordType().mapper(valueTable))) yet + // [#9288] TODO: Can't use collect(Records.intoGroups(recordType().mapper(keyTable), recordType().mapper(valueTable))) yet Map> map = new LinkedHashMap<>(); for (R record : this) @@ -761,12 +758,12 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Map> intoGroups(Table table, Class type) { - return collect(toGroups(recordType().mapper(table), recordType().mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(recordType().mapper(table), recordType().mapper(Tools.configuration(this), type))); } @Override public final Map> intoGroups(Table table, RecordMapper mapper) { - return collect(toGroups(recordType().mapper(table), mapper)); + return collect(Records.intoGroups(recordType().mapper(table), mapper)); } @Override @@ -842,12 +839,12 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Set intoSet(RecordMapper mapper) { - return collect(toSet(mapper)); + return collect(Records.intoSet(mapper)); } @Override public final Set intoSet(int fieldIndex) { - return collect(toSet(recordType().mapper(fieldIndex))); + return collect(Records.intoSet(recordType().mapper(fieldIndex))); } @Override @@ -864,7 +861,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Set intoSet(String fieldName) { - return collect(toSet(recordType().mapper(fieldName))); + return collect(Records.intoSet(recordType().mapper(fieldName))); } @Override @@ -881,7 +878,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Set intoSet(Name fieldName) { - return collect(toSet(recordType().mapper(fieldName))); + return collect(Records.intoSet(recordType().mapper(fieldName))); } @Override @@ -898,7 +895,7 @@ final class ResultImpl extends AbstractResult implements Re @Override public final Set intoSet(Field field) { - return collect(toSet(recordType().mapper(field))); + return collect(Records.intoSet(recordType().mapper(field))); } @Override diff --git a/jOOQ/src/main/java/org/jooq/impl/ResultQueryTrait.java b/jOOQ/src/main/java/org/jooq/impl/ResultQueryTrait.java index 63ce1ebac4..f4466e7dc7 100644 --- a/jOOQ/src/main/java/org/jooq/impl/ResultQueryTrait.java +++ b/jOOQ/src/main/java/org/jooq/impl/ResultQueryTrait.java @@ -37,9 +37,6 @@ */ package org.jooq.impl; -import static org.jooq.Records.toGroups; -import static org.jooq.Records.toMap; -import static org.jooq.Records.toSet; import static org.jooq.impl.Tools.blocking; import java.lang.reflect.Array; @@ -786,82 +783,82 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Map fetchMap(Field key) { - return collect(toMap(mapper(key))); + return collect(Records.intoMap(mapper(key))); } @Override default Map fetchMap(int keyFieldIndex) { - return collect(toMap(mapper(keyFieldIndex))); + return collect(Records.intoMap(mapper(keyFieldIndex))); } @Override default Map fetchMap(String keyFieldName) { - return collect(toMap(mapper(keyFieldName))); + return collect(Records.intoMap(mapper(keyFieldName))); } @Override default Map fetchMap(Name keyFieldName) { - return collect(toMap(mapper(keyFieldName))); + return collect(Records.intoMap(mapper(keyFieldName))); } @Override default Map fetchMap(Field key, Field value) { - return collect(toMap(mapper(key), mapper(value))); + return collect(Records.intoMap(mapper(key), mapper(value))); } @Override default Map fetchMap(int keyFieldIndex, int valueFieldIndex) { - return collect(toMap(mapper(keyFieldIndex), mapper(valueFieldIndex))); + return collect(Records.intoMap(mapper(keyFieldIndex), mapper(valueFieldIndex))); } @Override default Map fetchMap(String keyFieldName, String valueFieldName) { - return collect(toMap(mapper(keyFieldName), mapper(valueFieldName))); + return collect(Records.intoMap(mapper(keyFieldName), mapper(valueFieldName))); } @Override default Map fetchMap(Name keyFieldName, Name valueFieldName) { - return collect(toMap(mapper(keyFieldName), mapper(valueFieldName))); + return collect(Records.intoMap(mapper(keyFieldName), mapper(valueFieldName))); } @Override default Map fetchMap(Field key, Class type) { - return collect(toMap(mapper(key), mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(mapper(key), mapper(Tools.configuration(this), type))); } @Override default Map fetchMap(int keyFieldIndex, Class type) { - return collect(toMap(mapper(keyFieldIndex), mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(mapper(keyFieldIndex), mapper(Tools.configuration(this), type))); } @Override default Map fetchMap(String keyFieldName, Class type) { - return collect(toMap(mapper(keyFieldName), mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(mapper(keyFieldName), mapper(Tools.configuration(this), type))); } @Override default Map fetchMap(Name keyFieldName, Class type) { - return collect(toMap(mapper(keyFieldName), mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(mapper(keyFieldName), mapper(Tools.configuration(this), type))); } @Override default Map fetchMap(Field key, RecordMapper mapper) { - return collect(toMap(mapper(key), mapper)); + return collect(Records.intoMap(mapper(key), mapper)); } @Override default Map fetchMap(int keyFieldIndex, RecordMapper mapper) { - return collect(toMap(mapper(keyFieldIndex), mapper)); + return collect(Records.intoMap(mapper(keyFieldIndex), mapper)); } @Override default Map fetchMap(String keyFieldName, RecordMapper mapper) { - return collect(toMap(mapper(keyFieldName), mapper)); + return collect(Records.intoMap(mapper(keyFieldName), mapper)); } @Override default Map fetchMap(Name keyFieldName, RecordMapper mapper) { - return collect(toMap(mapper(keyFieldName), mapper)); + return collect(Records.intoMap(mapper(keyFieldName), mapper)); } @Override @@ -946,52 +943,52 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Map fetchMap(Class keyType) { - return collect(toMap(mapper(Tools.configuration(this), keyType))); + return collect(Records.intoMap(mapper(Tools.configuration(this), keyType))); } @Override default Map fetchMap(Class keyType, Class valueType) { - return collect(toMap(mapper(Tools.configuration(this), keyType), mapper(Tools.configuration(this), valueType))); + return collect(Records.intoMap(mapper(Tools.configuration(this), keyType), mapper(Tools.configuration(this), valueType))); } @Override default Map fetchMap(Class keyType, RecordMapper valueMapper) { - return collect(toMap(mapper(Tools.configuration(this), keyType), valueMapper)); + return collect(Records.intoMap(mapper(Tools.configuration(this), keyType), valueMapper)); } @Override default Map fetchMap(RecordMapper keyMapper) { - return collect(toMap(keyMapper)); + return collect(Records.intoMap(keyMapper)); } @Override default Map fetchMap(RecordMapper keyMapper, Class valueType) { - return collect(toMap(keyMapper, mapper(Tools.configuration(this), valueType))); + return collect(Records.intoMap(keyMapper, mapper(Tools.configuration(this), valueType))); } @Override default Map fetchMap(RecordMapper keyMapper, RecordMapper valueMapper) { - return collect(toMap(keyMapper, valueMapper)); + return collect(Records.intoMap(keyMapper, valueMapper)); } @Override default Map fetchMap(Table table) { - return collect(toMap(mapper(table))); + return collect(Records.intoMap(mapper(table))); } @Override default Map fetchMap(Table keyTable, Table valueTable) { - return collect(toMap(mapper(keyTable), mapper(valueTable))); + return collect(Records.intoMap(mapper(keyTable), mapper(valueTable))); } @Override default Map fetchMap(Table table, Class type) { - return collect(toMap(mapper(table), mapper(Tools.configuration(this), type))); + return collect(Records.intoMap(mapper(table), mapper(Tools.configuration(this), type))); } @Override default Map fetchMap(Table table, RecordMapper mapper) { - return collect(toMap(mapper(table), mapper)); + return collect(Records.intoMap(mapper(table), mapper)); } @Override @@ -1001,82 +998,82 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Map> fetchGroups(Field key) { - return collect(toGroups(mapper(key))); + return collect(Records.intoGroups(mapper(key))); } @Override default Map> fetchGroups(int keyFieldIndex) { - return collect(toGroups(mapper(keyFieldIndex))); + return collect(Records.intoGroups(mapper(keyFieldIndex))); } @Override default Map> fetchGroups(String keyFieldName) { - return collect(toGroups(mapper(keyFieldName))); + return collect(Records.intoGroups(mapper(keyFieldName))); } @Override default Map> fetchGroups(Name keyFieldName) { - return collect(toGroups(mapper(keyFieldName))); + return collect(Records.intoGroups(mapper(keyFieldName))); } @Override default Map> fetchGroups(Field key, Field value) { - return collect(toGroups(mapper(key), mapper(value))); + return collect(Records.intoGroups(mapper(key), mapper(value))); } @Override default Map> fetchGroups(int keyFieldIndex, int valueFieldIndex) { - return (Map) collect(toGroups(mapper(keyFieldIndex), mapper(valueFieldIndex))); + return (Map) collect(Records.intoGroups(mapper(keyFieldIndex), mapper(valueFieldIndex))); } @Override default Map> fetchGroups(String keyFieldName, String valueFieldName) { - return (Map) collect(toGroups(mapper(keyFieldName), mapper(valueFieldName))); + return (Map) collect(Records.intoGroups(mapper(keyFieldName), mapper(valueFieldName))); } @Override default Map> fetchGroups(Name keyFieldName, Name valueFieldName) { - return (Map) collect(toGroups(mapper(keyFieldName), mapper(valueFieldName))); + return (Map) collect(Records.intoGroups(mapper(keyFieldName), mapper(valueFieldName))); } @Override default Map> fetchGroups(Field key, Class type) { - return collect(toGroups(mapper(key), mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(mapper(key), mapper(Tools.configuration(this), type))); } @Override default Map> fetchGroups(int keyFieldIndex, Class type) { - return collect(toGroups(mapper(keyFieldIndex), mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(mapper(keyFieldIndex), mapper(Tools.configuration(this), type))); } @Override default Map> fetchGroups(String keyFieldName, Class type) { - return collect(toGroups(mapper(keyFieldName), mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(mapper(keyFieldName), mapper(Tools.configuration(this), type))); } @Override default Map> fetchGroups(Name keyFieldName, Class type) { - return collect(toGroups(mapper(keyFieldName), mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(mapper(keyFieldName), mapper(Tools.configuration(this), type))); } @Override default Map> fetchGroups(Field key, RecordMapper mapper) { - return collect(toGroups(mapper(key), mapper)); + return collect(Records.intoGroups(mapper(key), mapper)); } @Override default Map> fetchGroups(int keyFieldIndex, RecordMapper mapper) { - return collect(toGroups(mapper(keyFieldIndex), mapper)); + return collect(Records.intoGroups(mapper(keyFieldIndex), mapper)); } @Override default Map> fetchGroups(String keyFieldName, RecordMapper mapper) { - return collect(toGroups(mapper(keyFieldName), mapper)); + return collect(Records.intoGroups(mapper(keyFieldName), mapper)); } @Override default Map> fetchGroups(Name keyFieldName, RecordMapper mapper) { - return collect(toGroups(mapper(keyFieldName), mapper)); + return collect(Records.intoGroups(mapper(keyFieldName), mapper)); } @Override @@ -1161,53 +1158,53 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Map> fetchGroups(Class keyType) { - return collect(toGroups(mapper(Tools.configuration(this), keyType))); + return collect(Records.intoGroups(mapper(Tools.configuration(this), keyType))); } @Override default Map> fetchGroups(Class keyType, Class valueType) { - return collect(toGroups(mapper(Tools.configuration(this), keyType), mapper(Tools.configuration(this), valueType))); + return collect(Records.intoGroups(mapper(Tools.configuration(this), keyType), mapper(Tools.configuration(this), valueType))); } @Override default Map> fetchGroups(Class keyType, RecordMapper valueMapper) { - return collect(toGroups(mapper(Tools.configuration(this), keyType), valueMapper)); + return collect(Records.intoGroups(mapper(Tools.configuration(this), keyType), valueMapper)); } @Override default Map> fetchGroups(RecordMapper keyMapper) { - return collect(toGroups(keyMapper)); + return collect(Records.intoGroups(keyMapper)); } @Override default Map> fetchGroups(RecordMapper keyMapper, Class valueType) { - return collect(toGroups(keyMapper, mapper(Tools.configuration(this), valueType))); + return collect(Records.intoGroups(keyMapper, mapper(Tools.configuration(this), valueType))); } @Override default Map> fetchGroups(RecordMapper keyMapper, RecordMapper valueMapper) { - return collect(toGroups(keyMapper, valueMapper)); + return collect(Records.intoGroups(keyMapper, valueMapper)); } @Override default Map> fetchGroups(Table table) { - return collect(toGroups(mapper(table))); + return collect(Records.intoGroups(mapper(table))); } @Override default Map> fetchGroups(Table keyTable, Table valueTable) { - // [#9288] TODO: Can't use collect(toGroups(recordType().mapper(keyTable), recordType().mapper(valueTable))) yet + // [#9288] TODO: Can't use collect(Records.intoGroups(recordType().mapper(keyTable), recordType().mapper(valueTable))) yet return fetch().intoGroups(keyTable, valueTable); } @Override default Map> fetchGroups(Table table, Class type) { - return collect(toGroups(mapper(table), mapper(Tools.configuration(this), type))); + return collect(Records.intoGroups(mapper(table), mapper(Tools.configuration(this), type))); } @Override default Map> fetchGroups(Table table, RecordMapper mapper) { - return collect(toGroups(mapper(table), mapper)); + return collect(Records.intoGroups(mapper(table), mapper)); } @Override @@ -1298,12 +1295,12 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Set fetchSet(RecordMapper mapper) { - return collect(toSet(mapper)); + return collect(Records.intoSet(mapper)); } @Override default Set fetchSet(int fieldIndex) { - return collect(toSet(mapper(fieldIndex))); + return collect(Records.intoSet(mapper(fieldIndex))); } @Override @@ -1320,7 +1317,7 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Set fetchSet(String fieldName) { - return collect(toSet(mapper(fieldName))); + return collect(Records.intoSet(mapper(fieldName))); } @Override @@ -1337,7 +1334,7 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Set fetchSet(Name fieldName) { - return collect(toSet(mapper(fieldName))); + return collect(Records.intoSet(mapper(fieldName))); } @Override @@ -1354,7 +1351,7 @@ interface ResultQueryTrait extends QueryPartInternal, ResultQu @Override default Set fetchSet(Field field) { - return collect(toSet(mapper(field))); + return collect(Records.intoSet(mapper(field))); } @Override