Remove nodes with given value from a singlely linked list (java).