}
// no else because a removed part can just be closed and a new
// part can start
if (!newStarted && mod.getType() == ModificationType.ADDED) {
AttributesImpl attrs = new AttributesImpl();
attrs.addAttribute("", "class", "class", "CDATA",
"diff-html-added");
if (mod.isFirstOfID()) {
attrs.addAttribute("", "id", "id", "CDATA", mod
.getType()
+ "-" + prefix + "-" + mod.getID());
}
addAttributes(mod, attrs);
handler.startElement("", "span", "span", attrs);
newStarted = true;
} else if (!changeStarted
&& mod.getType() == ModificationType.CHANGED) {
AttributesImpl attrs = new AttributesImpl();
attrs.addAttribute("", "class", "class", "CDATA",
"diff-html-changed");
if (mod.isFirstOfID()) {
attrs.addAttribute("", "id", "id", "CDATA", mod
.getType()
+ "-" + prefix + "-" + mod.getID());
}
addAttributes(mod, attrs);
handler.startElement("", "span", "span", attrs);
changeStarted = true;
changeTXT = mod.getChanges();
} else if (!remStarted
&& mod.getType() == ModificationType.REMOVED) {
AttributesImpl attrs = new AttributesImpl();
attrs.addAttribute("", "class", "class", "CDATA",
"diff-html-removed");
if (mod.isFirstOfID()) {
attrs.addAttribute("", "id", "id", "CDATA", mod
.getType()
+ "-" + prefix + "-" + mod.getID());
}
addAttributes(mod, attrs);