Package org.xwiki.rendering.block
Class LinkBlock
java.lang.Object
org.xwiki.rendering.block.AbstractBlock
org.xwiki.rendering.block.LinkBlock
Represents a Link element in a page.
- Since:
- 1.5M2
- Version:
- $Id: 3c8452834a64287bbbd0a2b1ee08f1256403f033 $
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.xwiki.rendering.block.Block
Block.Axes -
Field Summary
Fields inherited from interface org.xwiki.rendering.block.Block
LIST_BLOCK_TYPE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidSendListenerevents corresponding to the end of the block.voidSendListenerevents corresponding to the start of the block.clone(BlockFilter blockFilter) Return a copy of the block with filtered children.booleaninthashCode()booleanMethods inherited from class org.xwiki.rendering.block.AbstractBlock
addChild, addChildren, clone, get, getAttribute, getAttributes, getBlocks, getChildren, getFirstBlock, getNextSibling, getParameter, getParameters, getParent, getPreviousSibling, getRoot, getSyntaxMetadata, indexOf, insertChildAfter, insertChildBefore, removeBlock, replaceChild, replaceChild, setAttribute, setAttributes, setChildren, setNextSiblingBlock, setParameter, setParameters, setParent, setPreviousSiblingBlock, traverse
-
Constructor Details
-
LinkBlock
- Parameters:
childrenBlocks- the nested children blocksreference- the reference to the target resource to link tofreestanding- if true then the link is a free standing URI directly in the text- Since:
- 2.5RC1
-
LinkBlock
public LinkBlock(List<Block> childrenBlocks, ResourceReference reference, boolean freestanding, Map<String, String> parameters) - Parameters:
childrenBlocks- the nested children blocksreference- the reference to the target resource to link tofreestanding- if true then the link is a free standing URI directly in the textparameters- the parameters to set- Since:
- 2.5RC1
-
-
Method Details
-
getReference
- Returns:
- the reference to the target to link to
- Since:
- 2.5RC1
- See Also:
-
isFreeStandingURI
public boolean isFreeStandingURI()- Returns:
- true if the link is a free standing URI directly in the text, false otherwise
-
before
Description copied from class:AbstractBlockSendListenerevents corresponding to the start of the block. For example for a Bold block, this allows an XHTML Listener (aka a Renderer) to output<b>.- Overrides:
beforein classAbstractBlock- Parameters:
listener- the listener that will receive the events sent by this block before its children blocks have emitted their own events.
-
after
Description copied from class:AbstractBlockSendListenerevents corresponding to the end of the block. For example for a Bold block, this allows an XHTML Listener (aka a Renderer) to output</b>.- Overrides:
afterin classAbstractBlock- Parameters:
listener- the listener that will receive the events sent by this block before its children blocks have emitted their own events.
-
clone
Return a copy of the block with filtered children.- Specified by:
clonein interfaceBlock- Overrides:
clonein classAbstractBlock- Parameters:
blockFilter- the Block filter.- Returns:
- the filtered Block.
- Since:
- 1.8RC2
-
equals
- Overrides:
equalsin classAbstractBlock
-
hashCode
public int hashCode()- Overrides:
hashCodein classAbstractBlock
-