public class XDOM extends MetaDataBlock
Block
that represent a XWiki Document's content.Block.Axes
Modifier and Type | Field and Description |
---|---|
static XDOM |
EMPTY
Constructs an empty XDOM.
|
LIST_BLOCK_TYPE
Constructor and Description |
---|
XDOM(List<? extends Block> childBlocks) |
XDOM(List<? extends Block> childBlocks,
IdGenerator idGenerator) |
XDOM(List<? extends Block> childBlocks,
IdGenerator idGenerator,
MetaData metaData) |
XDOM(List<? extends Block> childBlocks,
MetaData metaData) |
Modifier and Type | Method and Description |
---|---|
void |
after(Listener listener)
Send
Listener events corresponding to the end of the block. |
void |
before(Listener listener)
Send
Listener events corresponding to the start of the block. |
XDOM |
clone() |
IdGenerator |
getIdGenerator() |
void |
setIdGenerator(IdGenerator idGenerator) |
equals, getMetaData, hashCode
addChild, addChildren, clone, getBlocks, getChildren, getFirstBlock, getNextSibling, getParameter, getParameters, getParent, getPreviousSibling, getRoot, indexOf, insertChildAfter, insertChildBefore, removeBlock, replaceChild, replaceChild, setChildren, setNextSiblingBlock, setParameter, setParameters, setParent, setPreviousSiblingBlock, traverse
public static final XDOM EMPTY
public XDOM(List<? extends Block> childBlocks)
childBlocks
- the list of children blocks of the block to constructAbstractBlock(List)
public XDOM(List<? extends Block> childBlocks, MetaData metaData)
childBlocks
- the list of children blocks of the block to constructmetaData
- the meta data to add for this blockAbstractBlock(List)
public XDOM(List<? extends Block> childBlocks, IdGenerator idGenerator)
childBlocks
- the list of children blocks of the block to constructidGenerator
- a stateful id generator for this documentpublic XDOM(List<? extends Block> childBlocks, IdGenerator idGenerator, MetaData metaData)
childBlocks
- the list of children blocks of the block to constructmetaData
- the meta data to add for this blockidGenerator
- a stateful id generator for this documentAbstractBlock(List)
public IdGenerator getIdGenerator()
public void setIdGenerator(IdGenerator idGenerator)
idGenerator
- a stateful id generator for the whole document.public void before(Listener listener)
AbstractBlock
Listener
events corresponding to the start of the block. For example
for a Bold block, this allows an XHTML Listener (aka a Renderer) to output <b>
.before
in class MetaDataBlock
listener
- the listener that will receive the events sent by this block before its children blocks have
emitted their own events.public void after(Listener listener)
AbstractBlock
Listener
events corresponding to the end of the block. For example for a Bold block, this allows an
XHTML Listener (aka a Renderer) to output </b>
.after
in class MetaDataBlock
listener
- the listener that will receive the events sent by this block before its children blocks have
emitted their own events.public XDOM clone()
clone
in interface Block
clone
in class MetaDataBlock
Object.clone()
Copyright © 2004–2021 XWiki. All rights reserved.