| Modifier and Type | Method and Description |
|---|---|
FibonacciStackFrame |
FibonacciStackFrame.getCaller()
Get the creator of this call stack.
|
| Modifier and Type | Method and Description |
|---|---|
void |
FibonacciStackFrame.execute(Stack<FibonacciStackFrame> callStack)
Start or resume execution of this stack frame.
|
void |
FibonacciStackFrame.returnValueToCaller(BigInteger retVal,
Stack<FibonacciStackFrame> callStack)
Returns the value of F(n) to the creator (
this.caller)
of this stack frame if the creator was another FibonacciStackFrame
instance, and then pops this stack frame from the call stack. |
| Constructor and Description |
|---|
FibonacciStackFrame(int n,
FibonacciStackFrame caller)
Creates a stack frame to compute F(n).
|