String name = paramParser.nextToken();
paramParser.nextToken(); //ignore ":"
String type = paramParser.nextToken();
mapping.setPropertyName(name);
mapping.setJdbcTypeName(type);
TypeHandler handler;
if (parameterClass == null) {
handler = typeHandlerFactory.getUnkownTypeHandler();
} else {
handler = resolveTypeHandler(typeHandlerFactory, parameterClass, name, null, type);
}
mapping.setTypeHandler(handler);
return mapping;
} else if (n1 >= 5) {
String name = paramParser.nextToken();
paramParser.nextToken(); //ignore ":"
String type = paramParser.nextToken();
paramParser.nextToken(); //ignore ":"
String nullValue = paramParser.nextToken();
while (paramParser.hasMoreTokens()) {
nullValue = nullValue + paramParser.nextToken();
}
mapping.setPropertyName(name);
mapping.setJdbcTypeName(type);
mapping.setNullValue(nullValue);
TypeHandler handler;
if (parameterClass == null) {
handler = typeHandlerFactory.getUnkownTypeHandler();
} else {
handler = resolveTypeHandler(typeHandlerFactory, parameterClass, name, null, type);
}
mapping.setTypeHandler(handler);
return mapping;
} else {
throw new SqlMapException("Incorrect inline parameter map format: " + token);
}
} else {
mapping.setPropertyName(token);
TypeHandler handler;
if (parameterClass == null) {
handler = typeHandlerFactory.getUnkownTypeHandler();
} else {
handler = resolveTypeHandler(typeHandlerFactory, parameterClass, token, null, null);
}