提交 aa455b32 authored 作者: Thomas Mueller's avatar Thomas Mueller

Small improvements.

上级 1f0b2ebe
...@@ -250,7 +250,7 @@ public class ConnectionInfo implements Cloneable { ...@@ -250,7 +250,7 @@ public class ConnectionInfo implements Cloneable {
if (getProperty("CIPHER", null) != null) { if (getProperty("CIPHER", null) != null) {
// split password into (filePassword+' '+userPassword) // split password into (filePassword+' '+userPassword)
int space = -1; int space = -1;
for (int i = 0; i < password.length; i++) { for (int i = 0, len = password.length; i < len; i++) {
if (password[i] == ' ') { if (password[i] == ' ') {
space = i; space = i;
break; break;
......
...@@ -135,7 +135,7 @@ public class FunctionAlias extends SchemaObjectBase { ...@@ -135,7 +135,7 @@ public class FunctionAlias extends SchemaObjectBase {
Class< ? > javaClass = Utils.loadUserClass(className); Class< ? > javaClass = Utils.loadUserClass(className);
Method[] methods = javaClass.getMethods(); Method[] methods = javaClass.getMethods();
ArrayList<JavaMethod> list = New.arrayList(); ArrayList<JavaMethod> list = New.arrayList();
for (int i = 0; i < methods.length; i++) { for (int i = 0, len = methods.length; i < len; i++) {
Method m = methods[i]; Method m = methods[i];
if (!Modifier.isStatic(m.getModifiers())) { if (!Modifier.isStatic(m.getModifiers())) {
continue; continue;
...@@ -338,7 +338,7 @@ public class FunctionAlias extends SchemaObjectBase { ...@@ -338,7 +338,7 @@ public class FunctionAlias extends SchemaObjectBase {
params[params.length - 1] = varArg; params[params.length - 1] = varArg;
} }
for (int a = 0; a < args.length; a++, p++) { for (int a = 0, len = args.length; a < len; a++, p++) {
boolean currentIsVarArg = varArgs && p >= paramClasses.length - 1; boolean currentIsVarArg = varArgs && p >= paramClasses.length - 1;
Class< ? > paramClass; Class< ? > paramClass;
if (currentIsVarArg) { if (currentIsVarArg) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论