AggTag, AnaTag, BaseHideTag, BaseLoopTag, BaseTag, CommentTag, ForEachTag, FormulaTag, ForTag, GroupTag, HideColsTag, HideRowsTag, HideSheetTag, HyperlinkTag, IfTag, ImageTag, MultiForEachTag, NameTag, NullTag, PageBreakTag, RickrollTag, SetTag, SpanTag, StyleTag, TotalTagpublic interface Tag
A Tag represents an XML tag that can reside in a
Cell. A Tag represents special processing inside
its own Block of Cells (the tag "body"). Each
Tag is responsible for processing its own Block.
Any concrete subclass of Tag must have a public, no-argument
constructor.
| Modifier and Type | Method | Description |
|---|---|---|
java.util.Map<java.lang.String,org.apache.poi.ss.usermodel.RichTextString> |
getAttributes() |
A
Tag can retrieve its attributes by calling this method. |
TagContext |
getContext() |
Returns the
TagContext to which the Tag is
associated. |
java.lang.String |
getName() |
Returns the name of the
Tag. |
Tag |
getParentTag() |
Returns the parent
Tag to this Tag. |
WorkbookContext |
getWorkbookContext() |
Returns the
WorkbookContext to which the Tag is
associated. |
boolean |
isBodiless() |
Returns whether this
Tag is bodiless. |
boolean |
processTag() |
Validates all attributes and attribute values.
|
void |
setAttributes(java.util.Map<java.lang.String,org.apache.poi.ss.usermodel.RichTextString> attributes) |
When a
Tag is created, the attributes are passed in via a
(possibly empty) Map of attribute names and values. |
void |
setBodiless(boolean bodiless) |
Sets whether this
Tag is bodiless. |
void |
setContext(TagContext context) |
Sets the
TagContext to which the Tag is
associated. |
void |
setParentTag(Tag parent) |
Sets the parent
Tag to this Tag. |
void |
setWorkbookContext(WorkbookContext context) |
Sets the
WorkbookContext to which the Tag is
associated. |
java.lang.String getName()
Tag.Tag.void setAttributes(java.util.Map<java.lang.String,org.apache.poi.ss.usermodel.RichTextString> attributes)
Tag is created, the attributes are passed in via a
(possibly empty) Map of attribute names and values.attributes - A Map of attribute names and values.void setBodiless(boolean bodiless)
Tag is bodiless.bodiless - true if this tag does not have a body,
false if this tag does have a body.boolean isBodiless()
Tag is bodiless.true if this tag does not have a body,
false if this tag does have a body.java.util.Map<java.lang.String,org.apache.poi.ss.usermodel.RichTextString> getAttributes()
Tag can retrieve its attributes by calling this method.Map of attribute names and attribute values.void setContext(TagContext context)
TagContext to which the Tag is
associated.context - A TagContext.TagContext getContext()
TagContext to which the Tag is
associated.TagContext.void setWorkbookContext(WorkbookContext context)
WorkbookContext to which the Tag is
associated.context - A WorkbookContext.WorkbookContext getWorkbookContext()
WorkbookContext to which the Tag is
associated.WorkbookContext.void setParentTag(Tag parent)
Tag to this Tag. The parent
tag is the tag that encloses this tag in the template spreadsheet.parent - The parent Tag, or null if none.Tag getParentTag()
Tag to this Tag. The parent
tag is the tag that encloses this tag in the template spreadsheet.Tag, or null if none.boolean processTag()
Validates all attributes and attribute values. Processes this
Tag.
For 0.3.0, the methods "checkAttributes" and "process" were removed
and replace by this method, to allow for additional logic. The methods
still exist in BaseTag, where they are called by a concrete
processTag method.
true if the Cell containing this
Tag was transformed, false if it needs to be
transformed again. This may happen if the Block
associated with the Tag was removed.TagParseException - If all required
attributes are not present, if there is an unrecognized attribute or
attribute value, or if any tag data is unacceptable in any other way.Copyright © 2012–2018 Jett Team. All rights reserved.