Code example for EmptyStackException

0
		return this.top==-1;
	} 
	public Object pop()
	{ 
		if(this.isEmpty())
			throw new EmptyStackException();
		return this.data[this.top--];
	} 
	public void push(Object value)
	{ 
		if(this.top+1==this.data.length)
			throw new OutOfMemoryError();
		this.data[++this.top]=value;
	} 
	public Enumeration<Object> getEnumeration()
	{ 
		return new StackEnumeration(); 
	} 
	private class StackEnumeration implements Enumeration<Object>
	{ 
		private int counter=top;