diff --git a/src/site/es/xdoc/configuration.xml b/src/site/es/xdoc/configuration.xml
index ae995427efb..3d7e30e01dc 100644
--- a/src/site/es/xdoc/configuration.xml
+++ b/src/site/es/xdoc/configuration.xml
@@ -561,6 +561,22 @@ SqlSessionFactory factory = new SqlSessionFactoryBuilder().build(reader, environ
false
+
+
+ defaultSqlProviderType
+
+
+ Specifies an sql provider class that holds provider method (Since 3.5.6).
+ This class apply to the type(or value) attribute on sql provider annotation(e.g. @SelectProvider),
+ when these attribute was omitted.
+
+
+ A type alias or fully qualified class name
+
+
+ Not set
+
+
diff --git a/src/site/es/xdoc/java-api.xml b/src/site/es/xdoc/java-api.xml
index 9e14192618c..8a7bdda71a5 100644
--- a/src/site/es/xdoc/java-api.xml
+++ b/src/site/es/xdoc/java-api.xml
@@ -480,7 +480,8 @@ void rollback(boolean force)
via the ProviderContext(available since MyBatis 3.4.5 or later) as method argument.(In MyBatis 3.4 or later, it's allow multiple parameters)
Atributos: value, type y method.
El atributo value y type es el nombre completamente cualificado de una clase
- (The type attribute is alias for value, you must be specify either one).
+ (The type attribute is alias for value, you must be specify either one.
+ But both attributes can be omit when specify the defaultSqlProviderType as global configuration).
El method es el nombre un método de dicha clase
(Since 3.5.1, you can omit method attribute, the MyBatis will resolve a target method via the
ProviderMethodResolver interface.
@@ -635,6 +636,29 @@ class UserSqlProvider implements ProviderMethodResolver {
}
}]]>
+
This example shows usage that share an sql provider class to all mapper methods using global configuration(Available since 3.5.6):
+
+
+
This example shows usage the default implementation of ProviderMethodResolver(available since MyBatis 3.5.1 or later):
なお、メソッド引数にはMapperメソッドの引数に渡したオブジェクトに加え、ProviderContext(MyBatis 3.4.5以降で利用可能)を介して「Mapperインタフェースの型」「Mapperメソッド」「データベースID」を渡すことができます。(MyBatis 3.4以降では、複数の引数を渡すことができます)
キー: value, type, method.
value と type にはクラスオブジェクトを指定します
- (type は value の別名で、どちらか一方を指定する必要があります)。
+ (type は value の別名で、どちらか一方を指定する必要があります。
+ ただし、グローバル設定としてdefaultSqlProviderTypeを指定している場合は両方とも省略することができます)。
method にはメソッド名を指定します
(MyBatis 3.5.1以降では、method 属性を省略することができます。その際MyBatisは、ProviderMethodResolver インタフェースを介して対象メソッドの解決を試み、
対象メソッドが解決できない場合は、provideSqlという名前のメソッドを代替メソッドとして利用します)。
@@ -619,6 +620,29 @@ class UserSqlBuilder {
}
}]]>
+
매핑된 구문을 실행할 때 마이바티스는 클래스의 인스턴스를 만들고 메소드를 실행한다.
Mapper 메서드의 인수인 "Mapper interface type" and "Database ID" 과 ProviderContext(Mybatis 3.4.5 부터) 를 이용한 "Mapper method" 로 전달 된 객체를 메서드 매개변수로 전달할 수 있다.(마이바티스 3.4이상에서는 복수 파라미터를 허용한다.)
사용가능한 속성들 : value, type, method.
- value and type 속성은 클래스 (The type attribute is alias for value, you must be specify either one).
+ value and type 속성은 클래스 (The type attribute is alias for value, you must be specify either one.
+ But both attributes can be omit when specify the defaultSqlProviderType as global configuration).
method 속성은 메소드명이다
(Since 3.5.1, you can omit method attribute, the MyBatis will resolve a target method via the
ProviderMethodResolver interface.
@@ -749,6 +750,29 @@ class UserSqlBuilder {
}
}]]>
+
This example shows usage that share an sql provider class to all mapper methods using global configuration(Available since 3.5.6):
+
+
+
This example shows usage the default implementation of ProviderMethodResolver(available since MyBatis 3.5.1 or later):
(In MyBatis 3.4 or later, it's allow multiple parameters)
Attributes: value, type, method and databaseId.
The value and type attribute is a class
- (The type attribute is alias for value, you must be specify either one).
+ (The type attribute is alias for value, you must be specify either one.
+ But both attributes can be omit when specify the defaultSqlProviderType as global configuration).
The method is the name of the method on that class
(Since 3.5.1, you can omit method attribute, the MyBatis will resolve a target method via the
ProviderMethodResolver interface.
@@ -672,6 +673,29 @@ class UserSqlBuilder {
}
}]]>
+
This example shows usage that share an sql provider class to all mapper methods using global configuration(Available since 3.5.6):
+
+
+
This example shows usage the default implementation of ProviderMethodResolver(available since MyBatis 3.5.1 or later):
+
This example shows usage the databaseId attribute on the statement annotation(Available since 3.5.5):