}
try {
String version = rootCursor.getAttrValue("version");
if (version.equals("2")) {
SMInputCursor errorsCursor = rootCursor.childElementCursor("errors");
if (errorsCursor.getNext() != null) {
parsed = true;
SMInputCursor errorCursor = errorsCursor.childElementCursor("error");
while (errorCursor.getNext() != null) {
String id = errorCursor.getAttrValue("id");
String msg = errorCursor.getAttrValue("msg");
String file = null;
String line = null;
SMInputCursor locationCursor = errorCursor.childElementCursor("location");
if (locationCursor.getNext() != null) {
file = locationCursor.getAttrValue("file");
line = locationCursor.getAttrValue("line");
}
if (isInputValid(file, line, id, msg)) {
sensor.saveUniqueViolation(project, context, CxxCppCheckRuleRepository.KEY, file, line, id, msg);
} else {