0
如果我使用Lombok的@Setting註釋上的場的PRIVATE聲納錯誤
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Notification implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Setter(value = AccessLevel.PRIVATE)
private String id;
private long userId;
private Event event;
private long timestamp = System.currentTimeMillis();
public Notification(final String id) {
this.id = id;
}
}
的值。聲納Maven插件提供了以下錯誤:
ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.7.1:sonar (default-cli) on project mio-events: Unable to analyze .class file tv/nativ/mio/event/model/Notification: 0 is not a valid line for a file -> [Help 1]
將@Setting值更改爲public可修復此問題,就像完全刪除@Setting併爲該字段添加手動私有設置器一樣。
任何想法可能是什麼問題?
感謝
尼克
你能提供堆棧跟蹤嗎?我認爲你正面臨着這個問題:[sonarqube-java-plugin-3-7-analysis-error](http://stackoverflow.com/questions/33521753/sonarqube-java-plugin-3-7-analysis-error/ ) –
將會有聲納java插件3.7.1的bugfix版本。 https://groups.google.com/forum/#!topic/sonarqube/rHLYkHOHUUs –
謝謝你的 – nickcodefresh