// Herbruikbare package... 
package be.hogent.h20;

public class H20_StackComposition {
	
	private H20_List stackList;
	
	public H20_StackComposition() {
		stackList = new H20_List("Stack");
	}
	
	public synchronized void push(Object object) {
		stackList.insertAtFront(object);
	}
	
	public synchronized Object pop() throws H20_EmptyListException {
		return stackList.removeFromFront();
	}
	
	public synchronized boolean isEmpty() {
		return stackList.isEmpty();
	}
	
	public synchronized void print() {
		stackList.print();
	}

}
