An example implementation of an Abstract Data Type in Java