Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception in thread "main" java.lang.ExceptionInInitializerError #1

Closed
rsrini7 opened this issue Apr 28, 2016 · 2 comments
Closed

Exception in thread "main" java.lang.ExceptionInInitializerError #1

rsrini7 opened this issue Apr 28, 2016 · 2 comments

Comments

@rsrini7
Copy link

rsrini7 commented Apr 28, 2016

I am facing below exception while trying to execute any of the samples.

Exception in thread "main" java.lang.ExceptionInInitializerError
Caused by: java.lang.IllegalArgumentException: Failed to load class org.brooth.jeta.samples.MetasitoryContainer
at org.brooth.jeta.metasitory.MapMetasitory.loadContainer(MapMetasitory.java:59)
at org.brooth.jeta.metasitory.MapMetasitory.(MapMetasitory.java:49)
at org.brooth.jeta.samples.MetaHelper.(MetaHelper.java:68)
at org.brooth.jeta.samples.MetaHelper.getInstance(MetaHelper.java:63)
at org.brooth.jeta.samples.MetaHelper.getMultiton(MetaHelper.java:134)
at org.brooth.jeta.samples.singleton.MultitonSample.(MultitonSample.java:30)
Caused by: java.lang.ClassNotFoundException: org.brooth.jeta.samples.MetasitoryContainer
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at org.brooth.jeta.metasitory.MapMetasitory.loadContainer(MapMetasitory.java:56)
... 5 more

@brooth
Copy link
Owner

brooth commented Apr 28, 2016

You need to generate all the meta code before execute the samples. Please, run build command first.

@rsrini7
Copy link
Author

rsrini7 commented Apr 28, 2016

Thanks. The problem in eclipse is that i have to explicitly specify the Generated Source directory as "build/generated/source/apt/main" from default ".apt_generated"

@rsrini7 rsrini7 closed this as completed Apr 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants