public Collection<VariableDependency> getVariableDependencies(ValueMapPath path) { Vector<VariableDependency> deps = new Vector<VariableDependency>(); String leftVar = path.substituteJavaName(getName()); Collection<String> rightVars = JavaParser.getAllVariables(path.substitute(variable.getInitialValue())); for (String var : rightVars) deps.add(new VariableDependency(leftVar, var, VariableDependency.ASSIGN)); Collection<String> ifVars = getCodeBundleContainingMe().getIfClauseVariables(path); for (String var : ifVars) deps.add(new VariableDependency(leftVar, var, VariableDependency.LITERAL_if)); return (deps); }
public Collection<String> getSetVariables(ValueMapPath path) { Vector<String> vars = new Vector(); vars.add(path.substituteJavaName(getName())); return (vars); }