Programming in Java - Class Problems