Is it possible to retain information via a helper function with java, without using static variables.
For example,
public void foo(){ int v = 0;
You could return a list or a similar data structure:
public List fooHelper( int v, int depth ){ if( depth == 0 ) return new ArrayList(); v++; List result = fooHelper( v, depth-1 ); result.add( new Integer(v) ); return result; }