Skip to content

Commit 5b68162

Browse files
committed
[ci] Run auto formatting
1 parent 1fdc7e1 commit 5b68162

File tree

283 files changed

+4310
-6963
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

283 files changed

+4310
-6963
lines changed

core/format.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2006-2023 the original author or authors.
4+
Copyright 2006-2025 the original author or authors.
55
66
Licensed under the Apache License, Version 2.0 (the "License");
77
you may not use this file except in compliance with the License.

core/mybatis-generator-core/format.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2006-2023 the original author or authors.
4+
Copyright 2006-2025 the original author or authors.
55
66
Licensed under the Apache License, Version 2.0 (the "License");
77
you may not use this file except in compliance with the License.

core/mybatis-generator-core/src/main/java/org/mybatis/generator/ant/GeneratorAntTask.java

Lines changed: 14 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@
4040
import org.mybatis.generator.internal.DefaultShellCallback;
4141

4242
/**
43-
* This is an Ant task that will run the generator. The following is a sample
44-
* Ant script that shows how to run the generator from Ant:
43+
* This is an Ant task that will run the generator. The following is a sample Ant script that shows how to run the
44+
* generator from Ant:
4545
*
4646
* <pre>
4747
* &lt;project default="genfiles" basedir="."&gt;
@@ -58,23 +58,18 @@
5858
* &lt;/target&gt;
5959
* &lt;/project&gt;
6060
* </pre>
61-
*
62-
* <p>The task requires that the attribute "configFile" be set to an existing XML
63-
* configuration file.
64-
*
65-
* <p>The task supports these optional attributes:
61+
* <p>
62+
* The task requires that the attribute "configFile" be set to an existing XML configuration file.
63+
* <p>
64+
* The task supports these optional attributes:
6665
* <ul>
67-
* <li>"overwrite" - if true, then existing Java files will be overwritten. if
68-
* false (default), then existing Java files will be untouched and the generator
69-
* will write new Java files with a unique name</li>
70-
* <li>"verbose" - if true, then the generator will log progress messages to the
71-
* Ant log. Default is false</li>
66+
* <li>"overwrite" - if true, then existing Java files will be overwritten. if false (default), then existing Java files
67+
* will be untouched and the generator will write new Java files with a unique name</li>
68+
* <li>"verbose" - if true, then the generator will log progress messages to the Ant log. Default is false</li>
7269
* <li>"contextIds" - a comma delimited list of contaxtIds to use for this run</li>
73-
* <li>"fullyQualifiedTableNames" - a comma-delimited list of fully qualified
74-
* table names to use for this run</li>
70+
* <li>"fullyQualifiedTableNames" - a comma-delimited list of fully qualified table names to use for this run</li>
7571
* </ul>
7672
*
77-
*
7873
* @author Jeff Butler
7974
*/
8075
public class GeneratorAntTask extends Task {
@@ -98,8 +93,7 @@ public void execute() {
9893

9994
List<String> warnings = new ArrayList<>();
10095
try {
101-
Properties p = propertyset == null ? null : propertyset
102-
.getProperties();
96+
Properties p = propertyset == null ? null : propertyset.getProperties();
10397

10498
ConfigurationParser cp = new ConfigurationParser(p, warnings);
10599
Configuration config = cp.parseConfiguration(configurationFile);
@@ -108,8 +102,7 @@ public void execute() {
108102

109103
MyBatisGenerator myBatisGenerator = new MyBatisGenerator(config, callback, warnings);
110104

111-
myBatisGenerator.generate(new AntProgressCallback(this, verbose), contexts,
112-
fullyqualifiedTables);
105+
myBatisGenerator.generate(new AntProgressCallback(this, verbose), contexts, fullyqualifiedTables);
113106

114107
} catch (XMLParserException | InvalidConfigurationException e) {
115108
for (String error : e.getErrors()) {
@@ -148,8 +141,7 @@ private Set<String> calculateContexts() {
148141
private Set<String> calculateTables() {
149142
Set<String> fullyqualifiedTables = new HashSet<>();
150143
if (stringHasValue(fullyQualifiedTableNames)) {
151-
StringTokenizer st = new StringTokenizer(fullyQualifiedTableNames,
152-
","); //$NON-NLS-1$
144+
StringTokenizer st = new StringTokenizer(fullyQualifiedTableNames, ","); //$NON-NLS-1$
153145
while (st.hasMoreTokens()) {
154146
String s = st.nextToken().trim();
155147
if (!s.isEmpty()) {
@@ -165,11 +157,9 @@ private File calculateConfigurationFile() {
165157
throw new BuildException(getString("RuntimeError.0")); //$NON-NLS-1$
166158
}
167159

168-
169160
File configurationFile = new File(configfile);
170161
if (!configurationFile.exists()) {
171-
throw new BuildException(getString(
172-
"RuntimeError.1", configfile)); //$NON-NLS-1$
162+
throw new BuildException(getString("RuntimeError.1", configfile)); //$NON-NLS-1$
173163
}
174164
return configurationFile;
175165
}

0 commit comments

Comments
 (0)