public <T extends Source> T addCategory(Category category) {
complete();
Element el = category.getParentElement();
if (el != null && el instanceof Categories) {
Categories cats = category.getParentElement();
category = (Category)category.clone();
try {
if (category.getScheme() == null && cats.getScheme() != null)
category.setScheme(cats.getScheme().toString());
} catch (Exception e) {
// Do nothing, shouldn't happen
}
}
addChild((OMElement)category);