Exception in thread “main” java.lang.Error: Unresolved compilation problems
Your problem is in this line: Message messageObject = new Message ();This error says that the Message class is not known at compile time. So you need to import the Message class. Something like this: Check this out. http://docs.oracle.com/javase/tutorial/java/package/usepkgs.html