com.atlassian.confluence.xhtml.api
Class RichTextLinkBody

java.lang.Object
  extended by com.atlassian.confluence.xhtml.api.RichTextLinkBody
All Implemented Interfaces:
LinkBody<java.lang.String>

public class RichTextLinkBody
extends java.lang.Object
implements LinkBody<java.lang.String>

A RichTextLinkBody is one that contains XHTML data and may be displayed on an XHTML client without requiring any encoding. It is an unfortunate implementation detail of the Confluence XHTML backend that we actually convert all HTML received from the editor to XML(XHTML) so while a RichTextLinkBody should actually represent HTML in actual use you can assume it to be XML.

Developer Notes:
If we want to transition this to be correct we should do the following -

Once this is done the back-end is ready to properly handle HTML link bodies. However we would still be converting HTML received from the editor to XML higher in the stack which is the reason I haven't done this yet.


Constructor Summary
RichTextLinkBody(java.lang.String body)
           
 
Method Summary
 boolean equals(java.lang.Object other)
           
 java.lang.String getBody()
           
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RichTextLinkBody

public RichTextLinkBody(java.lang.String body)
Method Detail

getBody

public java.lang.String getBody()
Specified by:
getBody in interface LinkBody<java.lang.String>
Returns:
the underlying data represented by this link body.

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2003-2014 Atlassian. All Rights Reserved.