com.atlassian.confluence.links
Class OutgoingLink

java.lang.Object
  extended by com.atlassian.core.bean.EntityObject
      extended by com.atlassian.confluence.core.ConfluenceEntityObject
          extended by com.atlassian.confluence.links.AbstractLink
              extended by com.atlassian.confluence.links.OutgoingLink
All Implemented Interfaces:
Serializable, Cloneable, Comparable

public class OutgoingLink
extends AbstractLink
implements Comparable

Represents a link from a source page to a destination.

The destination can currently be:

See Also:
Serialized Form

Constructor Summary
OutgoingLink()
          Default constructor
OutgoingLink(ContentEntityObject sourceContent, String destinationSpaceKey, String destinationPageTitle)
          Convenience constructor
 
Method Summary
 int compareTo(Object o)
           
 boolean equals(Object o)
           
 String getDestinationPageTitle()
           
 String getDestinationSpaceKey()
           
 String getUrlLink()
           
 int hashCode()
           
 boolean isFrom(AbstractPage page)
          Is the link directed from a page, or from some of its contents (i.e.
 boolean isUrlLink()
           
 void setDestinationPageTitle(String destinationPageTitle)
           
 void setDestinationSpaceKey(String destinationSpaceKey)
           
 String toString()
           
 
Methods inherited from class com.atlassian.confluence.links.AbstractLink
getLinkTitle, getSourceContent, setLinkTitle, setSourceContent
 
Methods inherited from class com.atlassian.confluence.core.ConfluenceEntityObject
getCreatorName, getLastModifierName, getRealClass, isPersistent, setCreatorName, setLastModifierName
 
Methods inherited from class com.atlassian.core.bean.EntityObject
clone, getCreationDate, getCurrentDate, getId, getLastModificationDate, setClock, setCreationDate, setId, setLastModificationDate
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OutgoingLink

public OutgoingLink()
Default constructor


OutgoingLink

public OutgoingLink(ContentEntityObject sourceContent,
                    String destinationSpaceKey,
                    String destinationPageTitle)
Convenience constructor

Parameters:
sourceContent - content object that the link comes from
destinationSpaceKey - space the link points to
destinationPageTitle - page the link points to
Method Detail

getDestinationPageTitle

public String getDestinationPageTitle()

setDestinationPageTitle

public void setDestinationPageTitle(String destinationPageTitle)

getDestinationSpaceKey

public String getDestinationSpaceKey()

setDestinationSpaceKey

public void setDestinationSpaceKey(String destinationSpaceKey)

isUrlLink

public boolean isUrlLink()

getUrlLink

public String getUrlLink()

equals

public boolean equals(Object o)
Overrides:
equals in class AbstractLink

hashCode

public int hashCode()
Overrides:
hashCode in class AbstractLink

compareTo

public int compareTo(Object o)
Specified by:
compareTo in interface Comparable

toString

public String toString()
Overrides:
toString in class Object

isFrom

public boolean isFrom(AbstractPage page)
Is the link directed from a page, or from some of its contents (i.e. comments)? Used to filter out internal links from a page's links list.



Copyright © 2003-2012 Atlassian. All Rights Reserved.