X-Git-Url: http://git.phpeclipse.com diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/ast/ArrayVariableDeclaration.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/ast/ArrayVariableDeclaration.java index 38d3527..c213bd3 100644 --- a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/ast/ArrayVariableDeclaration.java +++ b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/ast/ArrayVariableDeclaration.java @@ -1,5 +1,8 @@ package net.sourceforge.phpdt.internal.compiler.ast; +import java.util.List; +import java.util.ArrayList; + /** * This variable declaration do not extend AbstractVariableDeclaration because * it could take Expression as key. @@ -9,13 +12,13 @@ public class ArrayVariableDeclaration extends Expression { public Expression key,value; - public ArrayVariableDeclaration(Expression key,Expression value) { + public ArrayVariableDeclaration(final Expression key,final Expression value) { super(key.sourceStart, value.sourceEnd); this.key = key; this.value = value; } - public ArrayVariableDeclaration(Expression key,int sourceEnd) { + public ArrayVariableDeclaration(final Expression key,final int sourceEnd) { super(key.sourceStart, sourceEnd); this.key = key; } @@ -32,4 +35,35 @@ public class ArrayVariableDeclaration extends Expression { } return buff.toString(); } + + + + /** + * Get the variables from outside (parameters, globals ...) + * @return the variables from outside + */ + public List getOutsideVariable() { + return new ArrayList(); + } + + /** + * get the modified variables. + * @return the variables from we change value + */ + public List getModifiedVariable() { + final ArrayList list = new ArrayList(); + list.addAll(key.getModifiedVariable()); + list.addAll(value.getModifiedVariable()); + return list; + } + + /** + * Get the variables used. + * @return the variables used + */ + public List getUsedVariable() { + final ArrayList list = new ArrayList(); + list.addAll(value.getUsedVariable()); + return list; + } }