01: package persistence.antlr.collections;
02:
03: /* ANTLR Translator Generator
04: * Project led by Terence Parr at http://www.jGuru.com
05: * Software rights: http://www.antlr.org/license.html
06: *
07: */
08:
09: import java.util.NoSuchElementException;
10:
11: /** A simple stack definition; restrictive in that you cannot
12: * access arbitrary stack elements.
13: *
14: * @author Terence Parr
15: * <a href=http://www.MageLang.com>MageLang Institute</a>
16: */
17: public interface Stack {
18: public int height();
19:
20: public Object pop() throws NoSuchElementException;
21:
22: public void push(Object o);
23:
24: public Object top() throws NoSuchElementException;
25: }
|