private Resource resource;
private Rule rule;
private String message;
private RulePriority priority;
private Integer lineId;
<BUG>private Double cost;
public Violation(Rule rule) {</BUG>
this.rule = rule;
<BUG>}
public Violation(Rule rule, Resource resource) {</BUG>
this.resource = resource;

private Resource resource;
private Rule rule;
private String message;
private RulePriority priority;
private Integer lineId;
private Double cost;
@Deprecated
public Violation(Rule rule) {
this.rule = rule;
}
@Deprecated
public Violation(Rule rule, Resource resource) {
