The methods to get variables do not instantiate ArrayList each time, only one is...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / compiler / ast / VariableDeclaration.java
index 8d08f65..463128a 100644 (file)
@@ -191,32 +191,26 @@ public class VariableDeclaration extends Expression implements Outlineable {
 
   /**
    * Get the variables from outside (parameters, globals ...)
-   * @return the variables from outside
    */
-  public List getOutsideVariable() {
-    return new ArrayList(1);
+  public void getOutsideVariable(final List list) {
   }
 
   /**
    * get the modified variables.
-   * @return the variables from we change value
    */
-  public List getModifiedVariable() {
-    final List list = variable.getUsedVariable();
+  public void getModifiedVariable(final List list) {
+    variable.getUsedVariable(list);
     if (initialization != null) {
-      list.addAll(initialization.getModifiedVariable());
+      initialization.getModifiedVariable(list);
     }
-    return list;
   }
 
   /**
    * Get the variables used.
-   * @return the variables used
    */
-  public List getUsedVariable() {
+  public void getUsedVariable(final List list) {
     if (initialization != null) {
-      return initialization.getUsedVariable();
+      initialization.getUsedVariable(list);
     }
-    return new ArrayList(1);
   }
 }