Added Java Beans and fixed some class errors