public interface SinkEventAttributes extends MutableAttributeSet
All sink methods that produce some presentation-level output should have at least one form that allows to pass in a Set of SinkEventAttributes. For instance in
void text(String text, SinkEventAttributes attributes);
the attributes
parameter can be used to specify some text styling
options, or other optional parameters.
What kind of attributes are supported depends on the event and the sink implementation. The sink API just specifies a list of suggested attribute names, that sinks are expected to recognize, and parsers are expected to use preferably when emitting events.
It is recommended that for simple attributes, both keys and values should be
lower-case Strings, but this is not mandatory. One example of an exception is
the STYLE
attribute, whose value may itself be an AttributeSet again.
The base attributes that are supported by almost all events are
CLASS
, ID
, LANG
, STYLE
and TITLE
.
AttributeSet.CharacterAttribute, AttributeSet.ColorAttribute, AttributeSet.FontAttribute, AttributeSet.ParagraphAttribute
Modifier and Type | Field and Description |
---|---|
static String |
ABBRV
Specifies an abbreviated version of the content in an element.
|
static String |
ALIGN
Specifies the alignment of the event element within its parent element.
|
static String |
ALT
Defines a short description of the event element.
|
static String |
AXIS
Defines a name for a cell.
|
static String |
BGCOLOR
Specifies the background color of an event element.
|
static String |
BORDER
Defines a border around an event element.
|
static String |
CELLPADDING
Specifies the space between cell walls and contents.
|
static String |
CELLSPACING
Specifies the space between cells.
|
static String |
CHARSET
Specifies the character encoding of text associated with an event element.
|
static String |
CLASS
The class of the event element.
|
static String |
COLSPAN
Indicates the number of columns a cell should span.
|
static String |
COORDS
May be used in conjunction with
SHAPE . |
static String |
DATETIME
Specifies a machine readable date/time for the time element.
|
static String |
DECORATION
Specifies a decoration for an element.
|
static String |
EMAIL
An electronic mail address.
|
static String |
FRAME
Specifies which sides of a border surrounding an element should be visible.
|
static String |
HEADERS
A space-separated list of cell IDs that supply header information for the cell.
|
static String |
HEIGHT
Defines the height of an event element.
|
static String |
HREF
The target URL of an event element, eg a link.
|
static String |
HREFLANG
Specifies the base language of the target URL.
|
static String |
HSPACE
Defines white space on the left and right side of an event element.
|
static String |
ID
A unique id for the event element.
|
static String |
ISMAP
Defines an image as a server-side image map.
|
static String |
LANG
The language code for the event element.
|
static String |
NAME
Specifies the name of an anchor.
|
static String |
NOSHADE
Used to indicate that an element comes with a shadow.
|
static String |
NOWRAP
Whether to disable or enable automatic text wrapping for an element.
|
static String |
PROFILE
A space separated list of URL's that contains meta data information about the document.
|
static String |
REL
For references to external resourcs, specifies the relationship between
the current document and the target URL.
|
static String |
REV
For references to external resourcs, specifies the relationship between
the target URL and the current document.
|
static String |
ROWSPAN
Indicates the number of rows a cell should span.
|
static String |
RULES
Specifies horizontal/vertical divider lines between certain elements, eg table cells.
|
static String |
SCOPE
A general scope parameter.
|
static String |
SECTIONS
Specifies the semantics of an element.
|
static String |
SEMANTICS
Specifies the semantics of an element.
|
static String |
SHAPE
Defines the type of region to be defined for a mapping.
|
static String |
SIZE
Specifies the size, or thickness, or height of an event element.
|
static String |
SRC
The URL of an external resource, eg an image.
|
static String |
STYLE
An inline style definition.
|
static String |
SUMMARY
Specifies a summary of an event attribute for speech-synthesizing/non-visual target output.
|
static String |
TARGET
Where to open the target URL.
|
static String |
TITLE
A text to display in a tool tip.
|
static String |
TYPE
Specifies the MIME (Multipurpose Internet Mail Extensions) type of an
external resource URL, eg a link.
|
static String |
USEMAP
Defines an image as a client-side image map.
|
static String |
VALIGN
Specifies the vertical alignment of an element.
|
static String |
VALUE
Specifies a value for the data element.
|
static String |
VSPACE
Defines white space on the top and bottom of the event element.
|
static String |
WIDTH
Sets the width of an event element.
|
NameAttribute, ResolveAttribute
addAttribute, addAttributes, removeAttribute, removeAttributes, removeAttributes, setResolveParent
containsAttribute, containsAttributes, copyAttributes, getAttribute, getAttributeCount, getAttributeNames, getResolveParent, isDefined, isEqual
static final String CLASS
static final String ID
static final String LANG
static final String STYLE
Generally supported values are "italic", "bold", "monospaced" and AttributeSets.
If the value of this Attribute is itself an AttributeSet, it is interpreted as a sequence of CSS properties. For instance, the HTML paragraph opening
<p style="color: red; margin-left: 20px">
can be produced by an HTML Sink via the event
, where the value of the
SinkEventAttribute is an AttributeSet with two Attributes ("Sink.paragraph(SinkEventAttributes)
color
" and
"margin-left
" with values "red
" and "20px
",
respectively).
static final String TITLE
static final String PROFILE
static final String EMAIL
static final String ALIGN
Generally supported values are "left", "right", "center", "justify".
static final String ALT
static final String BORDER
static final String HEIGHT
static final String HSPACE
static final String ISMAP
static final String SRC
static final String USEMAP
static final String VSPACE
static final String WIDTH
static final String NOSHADE
static final String SIZE
static final String NAME
static final String CHARSET
static final String COORDS
SHAPE
.
Valid values are the same as for the corresponding HTML attributes.
static final String HREF
static final String HREFLANG
Used in conjunction with HREF
.
static final String REL
Valid values are the same as for the corresponding HTML attribute.
static final String REV
Valid values are the same as for the corresponding HTML attribute.
static final String SHAPE
Used with the COORDS
attribute.
static final String TARGET
Valid values are the same as for the corresponding HTML attribute.
static final String TYPE
static final String BGCOLOR
static final String CELLPADDING
static final String CELLSPACING
static final String FRAME
Valid values are the same as for the corresponding HTML attribute.
static final String RULES
static final String SUMMARY
static final String ABBRV
static final String AXIS
static final String COLSPAN
static final String HEADERS
static final String NOWRAP
static final String ROWSPAN
static final String SCOPE
static final String VALIGN
Generally accepted values are "top", "baseline", "middle", "bottom", "sup", "sub".
static final String DECORATION
Generally accepted values are "underline", "overline", "line-through", "source".
static final String SEMANTICS
Generally accepted values are "emphasis", "strong", "small", "line-through", "citation", "quote", "definition", "abbreviation", "italic", "bold", "monospaced", "code, "variable", "sample", "keyboard", "superscript", "subscript", "annotation", "highlight", "ruby", "rubyBase", "rubyText", "rubyTextContainer", "rubyParentheses", "bidirectionalIsolation", "bidirectionalOverride", "phrase", "insert", "delete".
static final String SECTIONS
Generally accepted values are "article", "section", "navigation", "sidebar".
static final String VALUE
static final String DATETIME
Copyright © 2005–2024 The Apache Software Foundation. All rights reserved.