cox.jmatt.java.MathTools.markup.svg
Class UseTag
java.lang.Object
cox.jmatt.java.MathTools.markup.Tag
cox.jmatt.java.MathTools.markup.svg.StyleTag
cox.jmatt.java.MathTools.markup.svg.UseTag
public class UseTag
- extends StyleTag
This class implements the SVG <use> tag. It has no public constructors because the 'HREF=' attribute is mandatory. The purpose of this tag is
to allow something to be defined once and used multiple times, perhaps with multiple different styles and transformations. This class simplifies that process.
Since the HREF is mandatory it is preserved when reset()
is called. This allows a UseTag
to be defined around a particular reference
then styled and transformed, reset, then re-styled and re-transformed, all without losing the reference.
Fields inherited from class cox.jmatt.java.MathTools.markup.Tag |
myTagName |
Method Summary |
static UseTag |
newInstance(java.lang.String HREF)
Static factory method for constructing these tags. |
void |
reset()
Overridden to preserve the HREF even when all other data is cleared. |
UseTag |
setHREF(java.lang.String HREF)
Change the tag's 'href=' attribute. |
Methods inherited from class cox.jmatt.java.MathTools.markup.Tag |
_addAttribute, _addAttributes, _addNAttribute, _asBoolean, _asDouble, _asInt, _attributes, _clampNAttribute, _clampNAttribute, _content, _fixKey, _setContent, _setEnableXMLTag, badPizza, closeTag, configureTag, configureTagFromGlobalPizza, makeTag, openTag, setID, toString, validString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
newInstance
public static final UseTag newInstance(java.lang.String HREF)
- Static factory method for constructing these tags. If 'HREF' is null or blank the return value is null.
setHREF
public UseTag setHREF(java.lang.String HREF)
- Change the tag's 'href=' attribute. Null or blank values are ignored.
reset
public void reset()
- Overridden to preserve the HREF even when all other data is cleared.
- Overrides:
reset
in class Tag