mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-04-04 05:32:56 +00:00
28 lines
354 B
Java
28 lines
354 B
Java
|
|
import java.util.Stack;
|
|
|
|
class JSStack {
|
|
|
|
Stack stack = new Stack();
|
|
|
|
void push(StackValue v)
|
|
{
|
|
stack.push(v);
|
|
}
|
|
|
|
boolean isEmpty()
|
|
{
|
|
return stack.isEmpty();
|
|
}
|
|
|
|
StackValue pop()
|
|
{
|
|
return (StackValue)stack.pop();
|
|
}
|
|
|
|
int size()
|
|
{
|
|
return stack.size();
|
|
}
|
|
|
|
} |