Part of the English translation work, and some typos in the original project were corrected.

This commit is contained in:
Suyue
2024-02-29 22:55:03 +08:00
parent 7399955384
commit 064d15bd5a
278 changed files with 1978 additions and 1966 deletions

View File

@ -22,7 +22,7 @@
<resource>
<directory>src/main/java</directory>
<includes>
<!--properties的配置文件会和编译后的class文件放在一起-->
<!--The properties configuration file will be placed together with the compiled class file-->
<include>**/*.json</include>
</includes>
</resource>

View File

@ -34,7 +34,7 @@ public class H2Meta extends DefaultMetaService implements MetaData {
private String getDDL(Connection connection, String databaseName, String schemaName, String tableName) {
try {
// 查询表结构信息
// Query table structure information
ResultSet columns = connection.getMetaData().getColumns(databaseName, schemaName, tableName, null);
List<String> columnDefinitions = new ArrayList<>();
while (columns.next()) {
@ -59,7 +59,7 @@ public class H2Meta extends DefaultMetaService implements MetaData {
columnDefinitions.add(columnDefinition.toString());
}
// 查询表索引信息
// Query table index information
ResultSet indexes = connection.getMetaData().getIndexInfo(databaseName, schemaName, tableName, false,
false);
Map<String, List<String>> indexMap = new HashMap<>();
@ -77,7 +77,7 @@ public class H2Meta extends DefaultMetaService implements MetaData {
createTableDDL.append(tableName).append(" (\n");
createTableDDL.append(String.join(",\n", columnDefinitions));
createTableDDL.append("\n);\n");
// 输出索引信息
// Output index information
for (Map.Entry<String, List<String>> entry : indexMap.entrySet()) {
String indexName = entry.getKey();
List<String> columnList = entry.getValue();