com.atlassian.renderer.links
Interface LinkResolver


public interface LinkResolver

Converts some arbitrary text (i.e. "My Issue|CONF-1234@JIRA") into a Link object that can then be rendered.


Method Summary
 Link createLink(RenderContext context, String linkText)
          Given some link text, convert it into a link object that can then be rendered into the page.
 List extractLinks(RenderContext context, String text)
           
 List extractLinkTextList(String pageContent)
           
 String removeLinkBrackets(String linkText)
           
 

Method Detail

createLink

Link createLink(RenderContext context,
                String linkText)
Given some link text, convert it into a link object that can then be rendered into the page. The link text supplied should not contain any surrounding delimiters, so for example if you write "[Foo|Bar]" in the page, you should just be passing "Foo|Bar" to this method

Parameters:
linkText - The text to turn into a link
Returns:
the corresponding link. This method should never return null, in the event of the link not being parseable, an UnparseableLink should be returned instead.

extractLinkTextList

List extractLinkTextList(String pageContent)
Parameters:
pageContent -
Returns:
a list of links in the content passed in string format

extractLinks

List extractLinks(RenderContext context,
                  String text)
Parameters:
context -
text -
Returns:
a list of Link objects extracted from the text provided

removeLinkBrackets

String removeLinkBrackets(String linkText)


Copyright © 2009 Atlassian Pty Ltd. All Rights Reserved.