ProjectLombok - Undefined method in Eclipse after installing Eclipse Luna

I downloaded Eclipse Luna and imported a stable existing Maven project that uses @Getter and @Setter lombok annotations. Annotations are recognized, but Eclipse makes any calls to the getter or setter methods, giving an error message

The getSomething () method is undefined for type Foo

Unlike other stackoverflow questions like this , I am experiencing this problem even though I updated my eclipse.ini and added lombok.jar to the same directory as the eclipse.exe and eclipse.ini file. The eclipse.ini changes have not changed, but I still have error markets!

eclipse.ini

-startup plugins/org.eclipse.equinox.launcher_1.3.0.v20140415-2008.jar --launcher.library plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20140603-1326 -product org.eclipse.epp.package.jee.product --launcher.defaultAction openFile --launcher.XXMaxPermSize 256M -showsplash org.eclipse.platform --launcher.XXMaxPermSize 256m --launcher.defaultAction openFile -vm C:\Program Files\Java\jdk1.7.0_51\bin\javaw.exe --launcher.appendVmargs -vmargs -Dosgi.requiredJavaVersion=1.6 -Xms40m -Xmx512m -javaagent:lombok.jar -Xbootclasspath/a:lombok.jar 

I made the project> clean, I tried to use the full path to my lombok jar, I exited and restarted Eclipse, but nothing worked.

What am I missing here? Thanks for any help !!!

+5
source share
3 answers

I experienced this problem because the lombok version used by my project, 0.9.3, was not supported in Eclipse Luna. I upgraded my version to version 1.14.8, and now everything works as expected.

For more information on setting up lombok in eclipse luna, see .

+2
source

Actually there is no real idea, but maybe something helps.

Eclipse uses its own compiler, and Maven probably uses javac . So you usually have to run, and these two things are not connected.

A restart of Eclipse has always been enough for me.

Take a look at the Help / About Eclipse SDK: is there an entry in Lombok?

My eclipse.ini contains absolute paths:

 -javaagent:/home/maaartin/eclipse/lombok.jar -Xbootclasspath/a:/home/maaartin/eclipse/lombok.jar 

but the relative path should work too. The question is "regarding what?"

Typically, Lombok can find the Eclipse installation directory and install it on its own. You must do this manually only when using non-standard installation directories.

Open the error log window, maybe something is going wrong. Just in case, see also the log files on disk.

Eclipse-lombok.png

+1
source

Maven repository for the Lombok project is installed on an accessible page on the project home page

http://projectlombok.org/mavenrepo/

Just delete this area and it works on Eclipse Luna with version 1.14.8.

0
source

Source: https://habr.com/ru/post/1203983/


All Articles