net.chayden.eliza
Class KeyStack

java.lang.Object
  |
  +--net.chayden.eliza.KeyStack

public class KeyStack
extends java.lang.Object

A stack of keys. The keys are kept in rank order.


Constructor Summary
KeyStack()
           
 
Method Summary
 Key key(int n)
          Get a key from the stack.
 int keyTop()
          Get the stack size.
 void print()
          Prints the key stack.
 void pushKey(Key key)
          Push a key in the stack.
 void reset()
          Reset the key stack.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyStack

public KeyStack()
Method Detail

print

public void print()
Prints the key stack.


keyTop

public int keyTop()
Get the stack size.


reset

public void reset()
Reset the key stack.


key

public Key key(int n)
Get a key from the stack.


pushKey

public void pushKey(Key key)
Push a key in the stack. Keep the highest rank keys at the bottom.