Skip to content

Commit 3558137

Browse files
committed
Update documentation for gh-1771
1 parent 060a397 commit 3558137

File tree

7 files changed

+37
-13
lines changed

7 files changed

+37
-13
lines changed

src/main/java/org/apache/ibatis/annotations/Many.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
* Returns the result map id used to map collection.
4545
*
4646
* @return the result map id
47+
* @since 3.5.5
4748
*/
4849
String resultMap() default "";
4950

src/main/java/org/apache/ibatis/annotations/One.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
* Returns the result map id used to map single object.
4545
*
4646
* @return the result map id
47+
* @since 3.5.5
4748
*/
4849
String resultMap() default "";
4950

src/site/es/xdoc/java-api.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2009-2019 the original author or authors.
4+
Copyright 2009-2020 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.
@@ -389,16 +389,18 @@ void rollback(boolean force)</source>
389389
<td>N/A</td>
390390
<td><code>&lt;association&gt;</code></td>
391391
<td>
392-
Un mapeo a una propiedad que contiene un tipo complejo. Atributos: select, que contiene el nombre completamente cualificado de un mapped statement (o un método de mapper) que puede cargar la instancia del tipo indicado,
392+
Un mapeo a una propiedad que contiene un tipo complejo. Atributos: select, que contiene el nombre completamente cualificado de un mapped statement (o un método de mapper) que puede cargar la instancia del tipo indicado.
393393
<code>fetchType</code>, que sobrescribe el parámetro global de configuración <code>lazyLoadingEnabled</code> para este mapeo.
394+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to a single container object from select result.
394395
Nota: Habrás visto que el mapeo de tipo join no se soporta mediante el API de anotaciones. Esto es debido a las limitaciones de las anotaciones en Java que no permiten referencias circulares.</td>
395396
</tr>
396397
<tr>
397398
<td><code>@Many</code></td>
398399
<td>N/A</td>
399400
<td><code>&lt;collection&gt;</code></td>
400-
<td>Un mapeo a una propiedad que contiene una colección de tipos complejos. Atributos: select, que contiene el nombre completamente cualificado de un mapped statement (o un método de mapper) que puede cargar la instancia del tipo indicado,
401+
<td>Un mapeo a una propiedad que contiene una colección de tipos complejos. Atributos: select, que contiene el nombre completamente cualificado de un mapped statement (o un método de mapper) que puede cargar la instancia del tipo indicado.
401402
<code>fetchType</code>, que sobrescribe el parámetro global de configuración <code>lazyLoadingEnabled</code> para este mapeo.
403+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to collection object from select result.
402404
Nota: Habrás visto que el mapeo de tipo join no se soporta mediante el API de anotaciones. Esto es debido a las limitaciones de las anotaciones en Java que no permiten referencias circulares.</td>
403405
</tr>
404406
<tr>

src/site/ja/xdoc/java-api.xml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2009-2019 the original author or authors.
4+
Copyright 2009-2020 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.
@@ -397,16 +397,20 @@ void rollback(boolean force)</source>
397397
<td><code>@One</code></td>
398398
<td>N/A</td>
399399
<td><code>&lt;association&gt;</code></td>
400-
<td>複雑型のプロパティのマッピング情報を定義します。属性: <code>select</code>, <code>fetchType</code>. select は適切な型を読み込むことができるマップドステートメント(Mapper メソッド)の完全修飾名です。
400+
<td>複雑型のプロパティのマッピング情報を定義します。属性: <code>select</code>, <code>fetchType</code>, <code>resultMap</code>(3.5.5以降で利用可能).
401+
select は適切な型を読み込むことができるマップドステートメント(Mapper メソッド)の完全修飾名です。
401402
fetchType はグローバルな設定 <code>lazyLoadingEnabled</code> をオーバーライドする場合に指定します。
403+
resultMap は結果列を単一のコンテナオブジェクト(JavaBeanなど)へマッピングするための結果マップの完全修飾名を指定します。
402404
<span class="label important">NOTE</span> アノテーション API では結合マッピングがサポートされていません。これは Java アノテーションでは循環参照が許可されないためです。</td>
403405
</tr>
404406
<tr>
405407
<td><code>@Many</code></td>
406408
<td>N/A</td>
407409
<td><code>&lt;collection&gt;</code></td>
408-
<td>複雑型のプロパティのマッピング情報を定義します。属性: <code>select</code>, <code>fetchType</code>. select は適切な型のコレクションを読み込むことができるマップドステートメント(Mapper メソッド)の完全修飾名です。
410+
<td>複雑型のプロパティのマッピング情報を定義します。属性: <code>select</code>, <code>fetchType</code>, <code>resultMap</code>(3.5.5以降で利用可能).
411+
select は適切な型のコレクションを読み込むことができるマップドステートメント(Mapper メソッド)の完全修飾名です。
409412
fetchType はグローバルな設定 <code>lazyLoadingEnabled</code> をオーバーライドする場合に指定します。
413+
resultMap は結果列をコレクションオブジェクト(JavaBeanのリストなど)へマッピングするための結果マップの完全修飾名を指定します。
410414
<span class="label important">NOTE</span> アノテーション API では結合マッピングがサポートされていません。これは Java アノテーションでは循環参照が許可されないためです。</td>
411415
</tr>
412416
<tr>

src/site/ko/xdoc/java-api.xml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2009-2019 the original author or authors.
4+
Copyright 2009-2020 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.
@@ -503,7 +503,9 @@ void rollback(boolean force)</source>
503503
<td>N/A</td>
504504
<td><code>&lt;association&gt;</code></td>
505505
<td>복잡한 타입의 한개의 프로퍼티를 위한 매핑이다.
506-
사용가능한 속성들 : select(매핑 구문의 이름, 예를들어 매퍼 메소드)
506+
사용가능한 속성들 : select(매핑 구문의 이름, 예를들어 매퍼 메소드).
507+
<code>fetchType</code>, which supersedes the global configuration parameter <code>lazyLoadingEnabled</code> for this mapping.
508+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to a single container object from select result.
507509
Note: 조인 매핑은 애노테이션 API 를 통해서는 지원되지 않는다는 것을 알아야 한다.
508510
순환(circular) 참조를 허용하지 않는 자바 애노테이션의 제약사항때문이다.</td>
509511
</tr>
@@ -513,6 +515,8 @@ void rollback(boolean force)</source>
513515
<td><code>&lt;collection&gt;</code></td>
514516
<td>복잡한 타입의 collection 프로퍼티를 위한 매핑이다.
515517
사용가능한 속성들 : select(매핑 구문의 이름, 예를들어 매퍼 메소드)
518+
<code>fetchType</code>, which supersedes the global configuration parameter <code>lazyLoadingEnabled</code> for this mapping.
519+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to collection object from select result.
516520
Note: 조인 매핑은 애노테이션 API 를 통해서는 지원되지 않는다는 것을 알아야 한다.
517521
순환(circular) 참조를 허용하지 않는 자바 애노테이션의 제약사항때문이다.</td>
518522
</tr>

src/site/xdoc/java-api.xml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
4-
Copyright 2009-2019 the original author or authors.
4+
Copyright 2009-2020 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.
@@ -418,9 +418,11 @@ void rollback(boolean force)</source>
418418
<td>N/A</td>
419419
<td><code>&lt;association&gt;</code></td>
420420
<td>A mapping to a single property value of a complex type. Attributes: <code>select</code>, which is the fully
421-
qualified name of a mapped statement (i.e. mapper method) that can load an instance of the appropriate type,
421+
qualified name of a mapped statement (i.e. mapper method) that can load an instance of the appropriate type.
422422
<code>fetchType</code>, which supersedes the global configuration parameter <code>lazyLoadingEnabled</code> for this
423423
mapping.
424+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to
425+
a single container object from select result.
424426
<span class="label important">NOTE</span> You will notice that join mapping is not supported via the Annotations API.
425427
This is due to the limitation in Java Annotations that does not allow for circular references.</td>
426428
</tr>
@@ -430,8 +432,10 @@ void rollback(boolean force)</source>
430432
<td><code>&lt;collection&gt;</code></td>
431433
<td>A mapping to a collection property of a complex type. Attributes: <code>select</code>, which is the fully
432434
qualified name of a mapped statement (i.e. mapper method) that can load a collection of instances of the appropriate
433-
types, <code>fetchType</code>, which supersedes the global configuration parameter <code>lazyLoadingEnabled</code> for this
435+
types. <code>fetchType</code>, which supersedes the global configuration parameter <code>lazyLoadingEnabled</code> for this
434436
mapping.
437+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to
438+
collection object from select result.
435439
<span class="label important">NOTE</span> You will notice that join mapping is not supported via the
436440
Annotations API. This is due to the limitation in Java Annotations that does not allow for circular references.</td>
437441
</tr>

src/site/zh/xdoc/java-api.xml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -385,13 +385,21 @@ try (SqlSession session = sqlSessionFactory.openSession()) {
385385
<td><code>@One</code></td>
386386
<td>N/A</td>
387387
<td><code>&lt;association&gt;</code></td>
388-
       <td>复杂类型的单个属性映射。属性:<code>select</code>,指定可加载合适类型实例的映射语句(也就是映射器方法)全限定名;<code>fetchType</code>,指定在该映射中覆盖全局配置参数 <code>lazyLoadingEnabled</code>。<span class="label important">提示</span> 注解 API 不支持联合映射。这是由于 Java 注解不允许产生循环引用。</td>
388+
       <td>复杂类型的单个属性映射。属性:
389+
<code>select</code>,指定可加载合适类型实例的映射语句(也就是映射器方法)全限定名;
390+
<code>fetchType</code>,指定在该映射中覆盖全局配置参数 <code>lazyLoadingEnabled</code>;
391+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to a single container object from select result。
392+
<span class="label important">提示</span> 注解 API 不支持联合映射。这是由于 Java 注解不允许产生循环引用。</td>
389393
</tr>
390394
<tr>
391395
<td><code>@Many</code></td>
392396
<td>N/A</td>
393397
<td><code>&lt;collection&gt;</code></td>
394-
       <td>复杂类型的集合属性映射。属性:<code>select</code>,指定可加载合适类型实例集合的映射语句(也就是映射器方法)全限定名;<code>fetchType</code>,指定在该映射中覆盖全局配置参数 <code>lazyLoadingEnabled</code>。<span class="label important">提示</span> 注解 API 不支持联合映射。这是由于 Java 注解不允许产生循环引用。</td>
398+
       <td>复杂类型的集合属性映射。属性:
399+
<code>select</code>,指定可加载合适类型实例集合的映射语句(也就是映射器方法)全限定名;
400+
<code>fetchType</code>,指定在该映射中覆盖全局配置参数 <code>lazyLoadingEnabled</code>
401+
<code>resultMap</code>(available since 3.5.5), which is the fully qualified name of a result map that map to collection object from select result。
402+
<span class="label important">提示</span> 注解 API 不支持联合映射。这是由于 Java 注解不允许产生循环引用。</td>
395403
</tr>
396404
<tr>
397405
<td><code>@MapKey</code></td>

0 commit comments

Comments
 (0)