public abstract class BaseStaticXmlWidget extends BaseStaticWidget implements StaticXmlWidget
Modifier | Constructor and Description |
---|---|
protected |
BaseStaticXmlWidget(String prefix,
String tagName,
String namespaceURI) |
Modifier and Type | Method and Description |
---|---|
Map<String,String> |
getAdditionalNamespaceURIs()
Some XML tags may use namespaces in addition to the one declared for their tag.
|
String |
getAttribute(String name) |
String |
getNamespaceURI()
Gets the namespace URI for this tag, or null if it is unspecified.
|
String |
getPrefix()
Gets the namespace prefix of this tag, or null if it is unspecified
|
String |
getTextContent() |
protected boolean |
isSelfClosing()
Returns true if this widget is self closing (i.e.
|
void |
putAdditionalNamespaceURI(String prefix,
String uri) |
void |
putAttribute(String name,
String value) |
void |
setTextContent(String textContent) |
void |
write(Writer writer) |
protected void |
writeAttribute(Writer writer,
String name,
String value)
Writes the attribute with the given name and value to the given writer.
|
getChildren, getClientProperty, getParent, putClientProperty, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getChildren, getClientProperty, putClientProperty
public String getPrefix()
getPrefix
in interface StaticXmlWidget
public String getNamespaceURI()
getNamespaceURI
in interface StaticXmlWidget
public String getAttribute(String name)
getAttribute
in interface StaticXmlWidget
public void putAttribute(String name, String value)
putAttribute
in interface StaticXmlWidget
public String getTextContent()
getTextContent
in interface StaticXmlWidget
public void setTextContent(String textContent)
setTextContent
in interface StaticXmlWidget
public Map<String,String> getAdditionalNamespaceURIs()
StaticXmlWidget
getAdditionalNamespaceURIs
in interface StaticXmlWidget
public void write(Writer writer) throws IOException
write
in interface StaticWidget
write
in class BaseStaticWidget
IOException
protected void writeAttribute(Writer writer, String name, String value) throws IOException
By default, does not write attributes whose value is null (does write empty values,
which is important for <option value=""/>
). Subclasses can override this
method to suppress writing attributes for other reasons.
IOException
protected boolean isSelfClosing()
Copyright © 2015. All Rights Reserved.