if ("!doctype".equals(tagName)) {
this.doctype = tag.toHtml();
} else if (type == Tag.Type.CLOSE) {
if (!isKnownBrixTag(tagName)) {
Map<String, String> attributes = Collections.emptyMap();
items.add(new SimpleTag(tagName, type, attributes));
}
} else {
Map<String, String> attributes = getAttributes(tag);
if (isKnownBrixTag(tagName)) {
processBrixTag(nodes, current, items, tagName, getAttributes(tag), type);
} else {
items.add(new SimpleTag(tagName, type, attributes));
}
}
}