Package org.apache.ibatis.reflection
Class ParamNameResolver
java.lang.Object
org.apache.ibatis.reflection.ParamNameResolver
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetNamedParams
(Object[] args) A single non-special parameter is returned without a name.String[]
getNames()
Returns parameter names referenced by SQL providers.static Object
wrapToMapIfCollection
(Object object, String actualParamName) Wrap to aMapperMethod.ParamMap
if object isCollection
or array.
-
Field Details
-
GENERIC_NAME_PREFIX
- See Also:
-
-
Constructor Details
-
ParamNameResolver
-
-
Method Details
-
getNames
Returns parameter names referenced by SQL providers.- Returns:
- the names
-
getNamedParams
A single non-special parameter is returned without a name. Multiple parameters are named using the naming rule. In addition to the default names, this method also adds the generic names (param1, param2, ...).
- Parameters:
args
- the args- Returns:
- the named params
-
wrapToMapIfCollection
Wrap to aMapperMethod.ParamMap
if object isCollection
or array.- Parameters:
object
- a parameter objectactualParamName
- an actual parameter name (If specify a name, set an object toMapperMethod.ParamMap
with specified name)- Returns:
- a
MapperMethod.ParamMap
- Since:
- 3.5.5
-