org.xwiki.rendering.block
Class LinkBlock

java.lang.Object
  extended by org.xwiki.rendering.block.AbstractBlock
      extended by org.xwiki.rendering.block.LinkBlock
All Implemented Interfaces:
Cloneable, Block

public class LinkBlock
extends AbstractBlock

Represents a Link element in a page.

Since:
1.5M2
Version:
$Id: 6bd29f37f8e17d53d51df02bdb9972f10fcdabc9 $

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.xwiki.rendering.block.Block
Block.Axes
 
Constructor Summary
LinkBlock(List<Block> childrenBlocks, ResourceReference reference, boolean isFreeStandingURI)
           
LinkBlock(List<Block> childrenBlocks, ResourceReference reference, boolean isFreeStandingURI, Map<String,String> parameters)
           
 
Method Summary
 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.
 LinkBlock clone(BlockFilter blockFilter)
          Return a copy of the block with filtered children.
 ResourceReference getReference()
           
 boolean isFreeStandingURI()
           
 
Methods inherited from class org.xwiki.rendering.block.AbstractBlock
addChild, addChildren, clone, equals, getBlocks, getChildren, getChildrenByType, getFirstBlock, getNextSibling, getParameter, getParameters, getParent, getParentBlockByType, getPreviousBlockByType, getPreviousSibling, getRoot, hashCode, insertChildAfter, insertChildBefore, removeBlock, replaceChild, replaceChild, setChildren, setNextSiblingBlock, setParameter, setParameters, setParent, setPreviousSiblingBlock, traverse
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinkBlock

public LinkBlock(List<Block> childrenBlocks,
                 ResourceReference reference,
                 boolean isFreeStandingURI)
Parameters:
childrenBlocks - the nested children blocks
reference - the reference to the target resource to link to
isFreeStandingURI - 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 isFreeStandingURI,
                 Map<String,String> parameters)
Parameters:
childrenBlocks - the nested children blocks
reference - the reference to the target resource to link to
isFreeStandingURI - if true then the link is a free standing URI directly in the text
parameters - the parameters to set
Since:
2.5RC1
Method Detail

getReference

public ResourceReference getReference()
Returns:
the reference to the target to link to
Since:
2.5RC1
See Also:
ResourceReference

isFreeStandingURI

public boolean isFreeStandingURI()
Returns:
true if the link is a free standing URI directly in the text, false otherwise

before

public void before(Listener listener)
Description copied from class: AbstractBlock
Send 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>.

Overrides:
before in class AbstractBlock
Parameters:
listener - the listener that will receive the events sent by this block before its children blocks have emitted their own events.

after

public void after(Listener listener)
Description copied from class: AbstractBlock
Send 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>.

Overrides:
after in class AbstractBlock
Parameters:
listener - the listener that will receive the events sent by this block before its children blocks have emitted their own events.

clone

public LinkBlock clone(BlockFilter blockFilter)
Return a copy of the block with filtered children.

Specified by:
clone in interface Block
Overrides:
clone in class AbstractBlock
Parameters:
blockFilter - the Block filter.
Returns:
the filtered Block.
Since:
1.8RC2


Copyright © 2004-2011 XWiki. All Rights Reserved.