aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java')
-rw-r--r--src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java b/src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java
index f8bea1d..a1ddf2b 100644
--- a/src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java
+++ b/src/main/java/org/zwobble/mammoth/html/HtmlSelfClosingElement.java
@@ -11,14 +11,16 @@ public class HtmlSelfClosingElement implements HtmlNode {
this.attributes = attributes;
}
+ public String getTagName() {
+ return tagName;
+ }
+
public Map<String, String> getAttributes() {
return attributes;
}
@Override
- public void write(StringBuilder builder) {
- builder.append("<").append(tagName);
- HtmlWriter.generateAttributes(attributes, builder);
- builder.append(" />");
+ public void visit(Visitor visitor) {
+ visitor.visit(this);
}
}