A basic linked list in Java