Author: tv Date: Mon Mar 11 15:59:16 2019 New Revision: 1855244 URL: http://svn.apache.org/viewvc?rev=1855244&view=rev Log: Replace parameter array with varargs
Modified: db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AbstractFunction.java db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AggregateFunction.java db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/SQLFunction.java Modified: db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AbstractFunction.java URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AbstractFunction.java?rev=1855244&r1=1855243&r2=1855244&view=diff ============================================================================== --- db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AbstractFunction.java (original) +++ db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AbstractFunction.java Mon Mar 11 15:59:16 2019 @@ -82,10 +82,9 @@ public abstract class AbstractFunction i * @param args the function arguments, not null. */ @Override - @SuppressWarnings({ "rawtypes", "unchecked" }) - public void setArguments(Object[] args) + public void setArguments(Object... args) { - this.argumentList = new ArrayList(Arrays.asList(args)); + this.argumentList = new ArrayList<>(Arrays.asList(args)); } /** @@ -189,7 +188,7 @@ public abstract class AbstractFunction i { String tableName = null; boolean columnFound = false; - for (Object argument : argumentList) + for (Object argument : getArgumentList()) { if (argument instanceof Column) { @@ -219,7 +218,7 @@ public abstract class AbstractFunction i { String schemaName = null; boolean columnFound = false; - for (Object argument : argumentList) + for (Object argument : getArgumentList()) { if (argument instanceof Column) { @@ -251,7 +250,7 @@ public abstract class AbstractFunction i { String fullTableName = null; boolean columnFound = false; - for (Object argument : argumentList) + for (Object argument : getArgumentList()) { if (argument instanceof Column) { Modified: db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AggregateFunction.java URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AggregateFunction.java?rev=1855244&r1=1855243&r2=1855244&view=diff ============================================================================== --- db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AggregateFunction.java (original) +++ db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/AggregateFunction.java Mon Mar 11 15:59:16 2019 @@ -187,7 +187,7 @@ public class AggregateFunction implement * object is not Boolean. */ @Override - public void setArguments(Object[] args) + public void setArguments(Object... args) { if (args.length < 1) Modified: db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/SQLFunction.java URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/SQLFunction.java?rev=1855244&r1=1855243&r2=1855244&view=diff ============================================================================== --- db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/SQLFunction.java (original) +++ db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/functions/SQLFunction.java Mon Mar 11 15:59:16 2019 @@ -68,5 +68,5 @@ public interface SQLFunction extends Col * * @param args The function specific arguments. */ - void setArguments(Object[] args); + void setArguments(Object... args); } --------------------------------------------------------------------- To unsubscribe, e-mail: torque-dev-unsubscr...@db.apache.org For additional commands, e-mail: torque-dev-h...@db.apache.org