Hi,
I am using the latest hibernator plugin for eclipse 3.0. Maybe someone knows about my problem...
I successfully created a setting and a mapping file (for two tables). Synchronizing the Mapping file results in two JavaBeans (as you know for each table one bean), so I don't have to create these beans myself.
So far so good.
Now I create a main() method running _BaseRootDAO.initialize() on the first line. There is the error. The Log tells me that the classes which were automatically generated before can not be found. In my example, the two beans are named Noten and Faecher. Here is the exact log output:
log4j:WARN No appenders could be found for logger (net.sf.hibernate.cfg.Environment).
log4j:WARN Please initialize the log4j system properly.
java.lang.ClassNotFoundException: Noten
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at net.sf.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:268)
at net.sf.hibernate.cfg.Binder.bindClass(Binder.java:73)
at net.sf.hibernate.cfg.Binder.bindRootClass(Binder.java:165)
at net.sf.hibernate.cfg.Binder.bindRoot(Binder.java:1095)
at net.sf.hibernate.cfg.Configuration.add(Configuration.java:230)
at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:252)
at net.sf.hibernate.cfg.Configuration.addResource(Configuration.java:273)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:841)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:792)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:732)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:719)
at de.nordakademie.base._BaseRootDAO.initialize(_BaseRootDAO.java:50)
at de.nordakademie.base._BaseRootDAO.initialize(_BaseRootDAO.java:37)
at QueryFaecher.main(QueryFaecher.java:21)
rethrown as net.sf.hibernate.MappingException: persistent class not found: Noten
at net.sf.hibernate.cfg.Binder.bindClass(Binder.java:76)
at net.sf.hibernate.cfg.Binder.bindRootClass(Binder.java:165)
at net.sf.hibernate.cfg.Binder.bindRoot(Binder.java:1095)
at net.sf.hibernate.cfg.Configuration.add(Configuration.java:230)
at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:252)
at net.sf.hibernate.cfg.Configuration.addResource(Configuration.java:273)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:841)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:792)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:732)
at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:719)
at de.nordakademie.base._BaseRootDAO.initialize(_BaseRootDAO.java:50)
at de.nordakademie.base._BaseRootDAO.initialize(_BaseRootDAO.java:37)
at QueryFaecher.main(QueryFaecher.java:21)
Caused by: java.lang.ClassNotFoundException: Noten
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at net.sf.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:268)
at net.sf.hibernate.cfg.Binder.bindClass(Binder.java:73)
... 12 more
Exception in thread "main"
---------------------------------------
what is wrong here? Does anybody know?
Thanx in advance, mirco
|