public interface StructuralNode extends ContentNode
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
SUBSTITUTION_ATTRIBUTES
Constant for attribute replacements like
{foo} . |
static java.lang.String |
SUBSTITUTION_MACROS
Constant for macro replacements like
mymacro:target[] . |
static java.lang.String |
SUBSTITUTION_POST_REPLACEMENTS
Constant for post replacements like creating line breaks from a trailing
+ in a line. |
static java.lang.String |
SUBSTITUTION_QUOTES
Constant for quote replacements like
*bold* to bold . |
static java.lang.String |
SUBSTITUTION_REPLACEMENTS
Constant for replacements like
(C) to © . |
static java.lang.String |
SUBSTITUTION_SPECIAL_CHARACTERS
Constant for special character replacement substitution like
< to &lt; . |
Modifier and Type | Method and Description |
---|---|
void |
addSubstitution(java.lang.String substitution)
Adds the given substitution to this node at the end of the substitution list.
|
void |
append(StructuralNode block)
Appends a new child block as the last block to this block.
|
java.util.List<StructuralNode> |
blocks()
Deprecated.
Please use getBlocks() instead
|
java.lang.Object |
content()
Deprecated.
Please use getContent() instead
|
java.lang.String |
convert() |
java.util.List<StructuralNode> |
findBy(java.util.Map<java.lang.Object,java.lang.Object> selector) |
java.util.List<StructuralNode> |
getBlocks() |
java.lang.String |
getCaption() |
java.lang.Object |
getContent() |
java.lang.String |
getContentModel()
Returns the content model.
|
int |
getLevel() |
Cursor |
getSourceLocation()
Returns the source location of this block.
|
java.lang.String |
getStyle() |
java.util.List<java.lang.String> |
getSubstitutions()
Returns the list of enabled substitutions.
|
java.lang.String |
getTitle() |
boolean |
isSubstitutionEnabled(java.lang.String substitution) |
void |
prependSubstitution(java.lang.String substitution)
Adds the given substitution to this node at the beginning of the substitution list.
|
void |
removeSubstitution(java.lang.String substitution)
Removes the given substitution from this node.
|
void |
setCaption(java.lang.String caption) |
void |
setLevel(int level) |
void |
setStyle(java.lang.String style) |
void |
setSubstitutions(java.lang.String... substitution)
Sets the given substitutions on this node overwriting all other substitutions.
|
void |
setTitle(java.lang.String title) |
java.lang.String |
style()
Deprecated.
Please use getStyle() instead
|
java.lang.String |
title()
Deprecated.
Please use getTitle() instead
|
addRole, context, document, getAttr, getAttr, getAttr, getAttribute, getAttribute, getAttribute, getAttributes, getContext, getDocument, getId, getNodeName, getParent, getReftext, getRole, getRoles, hasAttr, hasAttr, hasAttribute, hasAttribute, hasRole, iconUri, id, imageUri, imageUri, isAttr, isAttr, isAttribute, isAttribute, isBlock, isInline, isOption, isReftext, isRole, mediaUri, normalizeWebPath, parent, readAsset, removeRole, role, setAttr, setAttribute, setId
static final java.lang.String SUBSTITUTION_SPECIAL_CHARACTERS
<
to &lt;
.static final java.lang.String SUBSTITUTION_QUOTES
*bold*
to bold
.static final java.lang.String SUBSTITUTION_ATTRIBUTES
{foo}
.static final java.lang.String SUBSTITUTION_REPLACEMENTS
(C)
to ©
.static final java.lang.String SUBSTITUTION_MACROS
mymacro:target[]
.static final java.lang.String SUBSTITUTION_POST_REPLACEMENTS
+
in a line.@Deprecated java.lang.String title()
java.lang.String getTitle()
void setTitle(java.lang.String title)
java.lang.String getCaption()
void setCaption(java.lang.String caption)
@Deprecated java.lang.String style()
java.lang.String getStyle()
void setStyle(java.lang.String style)
@Deprecated java.util.List<StructuralNode> blocks()
java.util.List<StructuralNode> getBlocks()
void append(StructuralNode block)
block
- The new child block added as last child to this block.@Deprecated java.lang.Object content()
java.lang.Object getContent()
java.lang.String convert()
java.util.List<StructuralNode> findBy(java.util.Map<java.lang.Object,java.lang.Object> selector)
int getLevel()
void setLevel(int level)
java.lang.String getContentModel()
ContentModel
Cursor getSourceLocation()
sourcemap
option is enabled when loading or rendering the document.null
if the sourcemap
option is not enabled when loading the document.java.util.List<java.lang.String> getSubstitutions()
["specialcharacters", "quotes", "attributes", "replacements", "macros", "post_replacements"]
for paragraphs.boolean isSubstitutionEnabled(java.lang.String substitution)
substitution
- the name of a substitution, e.g. SUBSTITUTION_POST_REPLACEMENTS
true
if the name of the given substitution is enabled.void removeSubstitution(java.lang.String substitution)
substitution
- the name of a substitution, e.g. SUBSTITUTION_QUOTES
void addSubstitution(java.lang.String substitution)
substitution
- the name of a substitution, e.g. SUBSTITUTION_MACROS
void prependSubstitution(java.lang.String substitution)
substitution
- the name of a substitution, e.g. SUBSTITUTION_ATTRIBUTES
void setSubstitutions(java.lang.String... substitution)
substitution
- the name of a substitution, e.g. SUBSTITUTION_SPECIAL_CHARACTERS