try {
if (marker != null) {
boolean elementError = true;
if (wodProblem instanceof WodBindingNameProblem) {
String name = ((WodBindingNameProblem) wodProblem).getBindingName();
FuzzyXMLAttribute attribute = _element.getAttributeNode(name);
if (attribute != null) {
elementError = false;
int offset = attribute.getOffset() + 1;
marker.setAttribute(IMarker.LINE_NUMBER, WodHtmlUtils.getLineAtOffset(_cache.getHtmlEntry().getContents(), offset));
marker.setAttribute(IMarker.CHAR_START, offset);
marker.setAttribute(IMarker.CHAR_END, offset + attribute.getName().length());
}
}
else if (wodProblem instanceof WodBindingValueProblem) {
String name = ((WodBindingValueProblem) wodProblem).getBindingName();
FuzzyXMLAttribute attribute = _element.getAttributeNode(name);
if (attribute != null) {
elementError = false;
int offset = attribute.getOffset() + 1;
marker.setAttribute(IMarker.LINE_NUMBER, WodHtmlUtils.getLineAtOffset(_cache.getHtmlEntry().getContents(), offset));
marker.setAttribute(IMarker.CHAR_START, _element.getOffset() + attribute.getValueDataOffset() + 1);
marker.setAttribute(IMarker.CHAR_END, _element.getOffset() + attribute.getValueDataOffset() + 1 + attribute.getValueDataLength());
}
}
else if (wodProblem instanceof WodBindingDeprecationProblem) {
String name = ((WodBindingDeprecationProblem) wodProblem).getBindingName();
FuzzyXMLAttribute attribute = _element.getAttributeNode(name);
if (attribute != null) {
elementError = false;
int offset = _element.getOffset() + attribute.getValueDataOffset() + 1;
marker.setAttribute(IMarker.LINE_NUMBER, WodHtmlUtils.getLineAtOffset(_cache.getHtmlEntry().getContents(), offset));
marker.setAttribute(IMarker.CHAR_START, offset);
marker.setAttribute(IMarker.CHAR_END, offset + attribute.getValueDataLength());
}
}
if (elementError) {
int offset = _element.getOffset() + 1;