mirror of
https://github.com/vran-dev/databasir.git
synced 2025-09-20 02:39:20 +08:00
fix: checkstyle
This commit is contained in:
@@ -31,11 +31,6 @@ public interface DatabaseMetaConverter {
|
|||||||
return of(database, tables, columnMap, indexMap, triggerMap, fkMap);
|
return of(database, tables, columnMap, indexMap, triggerMap, fkMap);
|
||||||
}
|
}
|
||||||
|
|
||||||
default <R> Map<Integer, List<R>> groupBy(List<R> content, Function<R, Integer> idMapping) {
|
|
||||||
return content.stream()
|
|
||||||
.collect(Collectors.groupingBy(idMapping));
|
|
||||||
}
|
|
||||||
|
|
||||||
default DatabaseMeta of(DatabaseDocumentPojo database,
|
default DatabaseMeta of(DatabaseDocumentPojo database,
|
||||||
List<TableDocumentPojo> tables,
|
List<TableDocumentPojo> tables,
|
||||||
Map<Integer, List<TableColumnDocumentPojo>> columnGroupByTableId,
|
Map<Integer, List<TableColumnDocumentPojo>> columnGroupByTableId,
|
||||||
@@ -69,4 +64,8 @@ public interface DatabaseMetaConverter {
|
|||||||
@Mapping(target = "columnNames", source = "pojo.columnNameArray")
|
@Mapping(target = "columnNames", source = "pojo.columnNameArray")
|
||||||
IndexMeta of(TableIndexDocumentPojo pojo);
|
IndexMeta of(TableIndexDocumentPojo pojo);
|
||||||
|
|
||||||
|
default <R> Map<Integer, List<R>> groupBy(List<R> content, Function<R, Integer> idMapping) {
|
||||||
|
return content.stream()
|
||||||
|
.collect(Collectors.groupingBy(idMapping));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user