Reputation: 6302
I am using lombok API in my codebase to generate getter and setter functionality internally for DTO. Here is one example.
import lombok.Data;
@Data
public class TemplateDTO {
private String templateId;
private String templateName;
}
The issue is while using the get/set methods of TemplateDTO in my codebase eclipse is showing me error messages.
However maven install is working fine (if I run via the command line).
Is there anyway I can disable error messages in eclipse or is there anyway I can resolve getter and setter code?
I am using Eclipse Neon.2 Release (4.6.2) in OSX.
Upvotes: 3
Views: 2223
Reputation: 6302
I will answer this question myself. Thanks to lukjar and @MrSimpleMind response.
Just append following lines in eclipse.ini.
Basically add lombok.jar in your javaagent and Xbootclasspath arguments.
-Xbootclasspath/a:/Users/test/lombok/lombok.jar
-javaagent:/Users/test/lombok/lombok.jar
After this
maven clean install
It's good to go now.
Upvotes: 4