Skip to content

Commit 3684db6

Browse files
authored
Merge pull request #3487 from yanxutao89/fix_some_typos
fix some typos
2 parents 1186bf2 + dc41f5a commit 3684db6

File tree

6 files changed

+15
-15
lines changed

6 files changed

+15
-15
lines changed

src/main/java/org/apache/ibatis/builder/MapperBuilderAssistant.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ public ResultMap addResultMap(String id, Class<?> type, String extend, Discrimin
162162

163163
if (extend != null) {
164164
if (!configuration.hasResultMap(extend)) {
165-
throw new IncompleteElementException("Could not find a parent resultmap with id '" + extend + "'");
165+
throw new IncompleteElementException("Could not find a parent resultMap with id '" + extend + "'");
166166
}
167167
ResultMap resultMap = configuration.getResultMap(extend);
168168
List<ResultMapping> extendedResultMappings = new ArrayList<>(resultMap.getResultMappings());

src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -96,16 +96,16 @@ public class DefaultResultSetHandler implements ResultSetHandler {
9696
// pending creations property tracker
9797
private final Map<Object, PendingRelation> pendingPccRelations = new IdentityHashMap<>();
9898

99-
// nested resultmaps
99+
// nested resultMaps
100100
private final Map<CacheKey, Object> nestedResultObjects = new HashMap<>();
101101
private final Map<String, Object> ancestorObjects = new HashMap<>();
102102
private Object previousRowValue;
103103

104-
// multiple resultsets
104+
// multiple resultSets
105105
private final Map<String, ResultMapping> nextResultMaps = new HashMap<>();
106106
private final Map<CacheKey, List<PendingRelation>> pendingRelations = new HashMap<>();
107107

108-
// Cached Automappings
108+
// Cached AutoMappings
109109
private final Map<String, List<UnMappedColumnAutoMapping>> autoMappingsCache = new HashMap<>();
110110
private final Map<String, List<String>> constructorAutoMappingColumns = new HashMap<>();
111111

@@ -199,7 +199,7 @@ private void handleRefCursorOutputParameter(ResultSet rs, ParameterMapping param
199199
handleRowValues(rsw, resultMap, resultHandler, new RowBounds(), null);
200200
}
201201
} finally {
202-
// issue #228 (close resultsets)
202+
// issue #228 (close resultSets)
203203
closeResultSet(rs);
204204
}
205205
}
@@ -276,12 +276,12 @@ private ResultSetWrapper getFirstResultSet(Statement stmt) throws SQLException {
276276

277277
try {
278278
while (rs == null) {
279-
// move forward to get the first resultset in case the driver
280-
// doesn't return the resultset as the first result (HSQLDB)
279+
// move forward to get the first resultSet in case the driver
280+
// doesn't return the resultSet as the first result (HSQLDB)
281281
if (stmt.getMoreResults()) {
282282
rs = stmt.getResultSet();
283283
} else if (stmt.getUpdateCount() == -1) {
284-
// no more results. Must be no resultset
284+
// no more results. Must be no resultSet
285285
break;
286286
}
287287
}
@@ -350,7 +350,7 @@ private void handleResultSet(ResultSetWrapper rsw, ResultMap resultMap, List<Obj
350350
handleRowValues(rsw, resultMap, resultHandler, rowBounds, null);
351351
}
352352
} finally {
353-
// issue #228 (close resultsets)
353+
// issue #228 (close resultSets)
354354
closeResultSet(rsw.getResultSet());
355355
}
356356
}

src/main/java/org/apache/ibatis/mapping/ParameterMapping.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ public ParameterMapping build() {
112112

113113
private void validate() {
114114
if (ResultSet.class.equals(parameterMapping.javaType) && parameterMapping.resultMapId == null) {
115-
throw new IllegalStateException("Missing resultmap in property '" + parameterMapping.property + "'. "
116-
+ "Parameters of type java.sql.ResultSet require a resultmap.");
115+
throw new IllegalStateException("Missing resultMap in property '" + parameterMapping.property + "'. "
116+
+ "Parameters of type java.sql.ResultSet require a resultMap.");
117117
}
118118
}
119119
}

src/main/java/org/apache/ibatis/mapping/ResultMapping.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ private void validate() {
164164
throw new IllegalStateException(
165165
"Cannot define both nestedQueryId and nestedResultMapId in property " + resultMapping.property);
166166
}
167-
// Issue #4 and GH #39: column is optional only in nested resultmaps but not in the rest
167+
// Issue #4 and GH #39: column is optional only in nested resultMaps but not in the rest
168168
if (resultMapping.nestedResultMapId == null && resultMapping.column == null
169169
&& resultMapping.composites.isEmpty()) {
170170
throw new IllegalStateException("Mapping is missing column attribute for property " + resultMapping.property);

src/test/java/org/apache/ibatis/plugin/PluginTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,13 +92,13 @@ void shouldPluginNotInvokeArbitraryMethod() {
9292
map = (Map<?, ?>) new AlwaysMapPlugin().plugin(map);
9393
try {
9494
map.get("Anything");
95-
fail("Exected IllegalArgumentException, but no exception was thrown.");
95+
fail("Expected IllegalArgumentException, but no exception was thrown.");
9696
} catch (IllegalArgumentException e) {
9797
assertEquals(
9898
"Method 'public abstract java.lang.Object java.util.Map.get(java.lang.Object)' is not supported as a plugin target.",
9999
e.getMessage());
100100
} catch (Exception e) {
101-
fail("Exected IllegalArgumentException, but was " + e.getClass(), e);
101+
fail("Expected IllegalArgumentException, but was " + e.getClass(), e);
102102
}
103103
}
104104

src/test/java/org/apache/ibatis/submitted/overwritingproperties/FooMapperTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ void overwriteWithDefault() {
7272
// <result property="field4" column="field3" jdbcType="INTEGER"/>
7373
Assertions.assertEquals(inserted.getField3(), selected.getField4());
7474

75-
// field4 is explicitly remapped to field3 in the resultmap
75+
// field4 is explicitly remapped to field3 in the resultMap
7676
// <result property="field3" column="field4" jdbcType="INTEGER"/>
7777
Assertions.assertEquals(inserted.getField4(), selected.getField3());
7878

0 commit comments

Comments
 (0)