|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.atlassian.core.bean.EntityObject
com.atlassian.confluence.core.ConfluenceEntityObject
com.atlassian.confluence.core.AbstractVersionedEntityObject
com.atlassian.confluence.core.ContentEntityObject
com.atlassian.confluence.core.SpaceContentEntityObject
com.atlassian.confluence.pages.AbstractPage
com.atlassian.confluence.pages.Page
public class Page
Represents a Page within Confluence.
Field Summary | |
---|---|
static java.lang.String |
CONTENT_TYPE
|
static java.util.Comparator |
pageComparator
|
Fields inherited from class com.atlassian.confluence.core.ContentEntityObject |
---|
CREATED, CURRENT, DELETED, MODIFIED |
Fields inherited from class com.atlassian.confluence.core.AbstractVersionedEntityObject |
---|
INITIAL_VERSION |
Constructor Summary | |
---|---|
Page()
|
Method Summary | |
---|---|
void |
addChild(Page child)
|
void |
convertToHistoricalVersion()
Remove all data from the object that does not need to be saved by historical versions. |
java.util.List |
getAncestors()
|
java.util.List |
getChildren()
|
java.util.List |
getDescendents()
|
java.lang.String |
getNameForComparison()
Subclasses should implement this method, giving a String back so that the content can be alphabetically sorted in a mixed-type list of content-entities. |
Page |
getParent()
|
java.lang.Integer |
getPosition()
|
java.util.List |
getSortedChildren()
|
java.lang.String |
getType()
An easy name for the type of this content: makes it easy for things like the #contentLink macro to work out what to draw. |
boolean |
hasChildren()
|
void |
incPosition()
|
boolean |
isHomePage()
|
boolean |
isRootLevel()
|
void |
remove(PageManager pageManager)
Sever any homepage |
void |
removeChild(Page child)
|
void |
setAncestors(java.util.List ancestors)
|
void |
setChildren(java.util.List children)
|
void |
setParent(Page parent)
Deprecated. Do not call this method. It exists solely for hibernate to use. Use #setParentPage instead. I would have made this method private, but CGLIB was complaining. |
void |
setParentPage(Page parent)
Public setter that makes sure that the parent page is valid |
void |
setPosition(java.lang.Integer position)
|
void |
setSpace(Space newSpace)
|
void |
severParentChildRelationships()
sever parent/child relationships |
void |
trash()
places content in trash can |
Methods inherited from class com.atlassian.confluence.pages.AbstractPage |
---|
addComment, getAttachmentsUrlPath, getComments, getOriginalVersionPage, getPreviousVersion, getSearchableDependants, getTopLevelComments, getUrlPath, hasInvalidTitleCharacters, isValidPageTitle, isValidPageTitleCharacter, isValidTitleLength, removeComment, setComments, setOriginalVersionPage, setTitle |
Methods inherited from class com.atlassian.confluence.core.SpaceContentEntityObject |
---|
addTrackbackLink, getSpace, getSpaceKey, hashCode, isIndexable, isInSpace |
Methods inherited from class com.atlassian.confluence.core.AbstractVersionedEntityObject |
---|
getLatestVersion, getOriginalVersion, getVersion, isLatestVersion, isNew, setOriginalVersion, setVersion |
Methods inherited from class com.atlassian.confluence.core.ConfluenceEntityObject |
---|
getCreatorName, getLastModifierName, isPersistent, setCreatorName, setLastModifierName |
Methods inherited from class com.atlassian.core.bean.EntityObject |
---|
getCreationDate, getCurrentDate, getId, getLastModificationDate, setClock, setCreationDate, setId, setLastModificationDate |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.atlassian.bonnie.Searchable |
---|
getId |
Methods inherited from interface com.atlassian.confluence.core.Addressable |
---|
getId |
Field Detail |
---|
public static final java.lang.String CONTENT_TYPE
public static final java.util.Comparator pageComparator
Constructor Detail |
---|
public Page()
Method Detail |
---|
public void setPosition(java.lang.Integer position)
public void incPosition()
public java.lang.Integer getPosition()
public boolean isRootLevel()
isRootLevel
in interface Hierarchical
public Page getParent()
getParent
in interface Hierarchical
public void setParent(Page parent)
setParent
in interface Hierarchical
public void setParentPage(Page parent)
parent
- the page to set as this page's parent
java.lang.IllegalArgumentException
- if the parent page is in a different space.public java.util.List getChildren()
getChildren
in interface Hierarchical
public boolean hasChildren()
hasChildren
in interface Hierarchical
public java.util.List getSortedChildren()
public void setChildren(java.util.List children)
setChildren
in interface Hierarchical
public void addChild(Page child)
addChild
in interface Hierarchical
public void removeChild(Page child)
removeChild
in interface Hierarchical
public boolean isHomePage()
public java.lang.String getType()
ContentEntityObject
getType
in interface Addressable
getType
in class ContentEntityObject
public void convertToHistoricalVersion()
Versioned
When using Hibernate to persist versioned objects, take special care to null any field that might contain a Hibernate-persisted collection, as Hibernate does not allow two different persistent objects to refer to the same persisted collection at the same time.
convertToHistoricalVersion
in interface Versioned
convertToHistoricalVersion
in class AbstractPage
public java.lang.String getNameForComparison()
ContentEntityObject
getNameForComparison
in class SpaceContentEntityObject
public void severParentChildRelationships()
public void remove(PageManager pageManager)
remove
in class AbstractPage
public void trash()
ContentEntityObject
trash
in class ContentEntityObject
public java.util.List getDescendents()
public java.util.List getAncestors()
getAncestors
in interface Hierarchical
public void setAncestors(java.util.List ancestors)
public void setSpace(Space newSpace)
setSpace
in class SpaceContentEntityObject
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |