org.apache.lenya.cms.site.tree2
Class DelegatingSiteTree
java.lang.Object
org.apache.lenya.cms.site.tree2.DelegatingSiteTree
- All Implemented Interfaces:
- org.apache.lenya.cms.repository.RepositoryItem, org.apache.lenya.cms.site.SiteStructure, SiteTree
public class DelegatingSiteTree
- extends java.lang.Object
- implements org.apache.lenya.cms.site.SiteStructure, SiteTree
Site tree implementation which delegates all operations to a shared site tree.
Constructor Summary |
DelegatingSiteTree(org.apache.avalon.framework.service.ServiceManager manager,
org.apache.lenya.cms.publication.Area area,
SiteTreeImpl tree)
|
Method Summary |
org.apache.lenya.cms.site.SiteNode |
add(java.lang.String path)
|
org.apache.lenya.cms.site.Link |
add(java.lang.String path,
org.apache.lenya.cms.publication.Document doc)
|
org.apache.lenya.cms.site.SiteNode |
add(java.lang.String path,
java.lang.String followingSiblingPath)
|
boolean |
contains(java.lang.String path)
|
boolean |
contains(java.lang.String path,
java.lang.String language)
|
boolean |
containsByUuid(java.lang.String uuid,
java.lang.String language)
|
boolean |
containsInAnyLanguage(java.lang.String uuid)
|
java.lang.String |
getArea()
|
org.apache.lenya.cms.site.Link |
getByUuid(java.lang.String uuid,
java.lang.String language)
|
protected org.apache.lenya.cms.site.Link |
getLink(org.apache.lenya.cms.site.Link delegate)
|
protected DelegatingNode |
getNode(org.apache.lenya.cms.site.SiteNode delegate)
|
org.apache.lenya.cms.site.SiteNode |
getNode(java.lang.String path)
|
protected org.apache.lenya.cms.repository.NodeFactory |
getNodeFactory()
|
org.apache.lenya.cms.site.SiteNode[] |
getNodes()
|
org.apache.lenya.cms.publication.Publication |
getPublication()
|
org.apache.lenya.cms.repository.Node |
getRepositoryNode()
|
org.apache.lenya.cms.repository.Session |
getSession()
|
protected java.lang.String |
getSourceUri()
|
org.apache.lenya.cms.site.SiteNode[] |
getTopLevelNodes()
|
void |
moveDown(java.lang.String path)
Move down the node amongst its siblings. |
void |
moveUp(java.lang.String path)
Move up the node amongst its siblings. |
org.apache.lenya.cms.site.SiteNode[] |
preOrder()
|
void |
save()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DelegatingSiteTree
public DelegatingSiteTree(org.apache.avalon.framework.service.ServiceManager manager,
org.apache.lenya.cms.publication.Area area,
SiteTreeImpl tree)
- Parameters:
manager
- The service manager.area
- The area which this tree belongs to.tree
- The tree to delegate to.
add
public org.apache.lenya.cms.site.Link add(java.lang.String path,
org.apache.lenya.cms.publication.Document doc)
throws org.apache.lenya.cms.site.SiteException
- Specified by:
add
in interface org.apache.lenya.cms.site.SiteStructure
- Throws:
org.apache.lenya.cms.site.SiteException
add
public org.apache.lenya.cms.site.SiteNode add(java.lang.String path)
throws org.apache.lenya.cms.site.SiteException
- Specified by:
add
in interface org.apache.lenya.cms.site.SiteStructure
- Throws:
org.apache.lenya.cms.site.SiteException
add
public org.apache.lenya.cms.site.SiteNode add(java.lang.String path,
java.lang.String followingSiblingPath)
throws org.apache.lenya.cms.site.SiteException
- Specified by:
add
in interface org.apache.lenya.cms.site.SiteStructure
- Throws:
org.apache.lenya.cms.site.SiteException
contains
public boolean contains(java.lang.String path)
- Specified by:
contains
in interface org.apache.lenya.cms.site.SiteStructure
contains
public boolean contains(java.lang.String path,
java.lang.String language)
- Specified by:
contains
in interface org.apache.lenya.cms.site.SiteStructure
containsByUuid
public boolean containsByUuid(java.lang.String uuid,
java.lang.String language)
- Specified by:
containsByUuid
in interface org.apache.lenya.cms.site.SiteStructure
containsInAnyLanguage
public boolean containsInAnyLanguage(java.lang.String uuid)
- Specified by:
containsInAnyLanguage
in interface org.apache.lenya.cms.site.SiteStructure
getArea
public java.lang.String getArea()
- Specified by:
getArea
in interface org.apache.lenya.cms.site.SiteStructure
getByUuid
public org.apache.lenya.cms.site.Link getByUuid(java.lang.String uuid,
java.lang.String language)
throws org.apache.lenya.cms.site.SiteException
- Specified by:
getByUuid
in interface org.apache.lenya.cms.site.SiteStructure
- Throws:
org.apache.lenya.cms.site.SiteException
getLink
protected org.apache.lenya.cms.site.Link getLink(org.apache.lenya.cms.site.Link delegate)
getNode
protected DelegatingNode getNode(org.apache.lenya.cms.site.SiteNode delegate)
getNode
public org.apache.lenya.cms.site.SiteNode getNode(java.lang.String path)
throws org.apache.lenya.cms.site.SiteException
- Specified by:
getNode
in interface org.apache.lenya.cms.site.SiteStructure
- Throws:
org.apache.lenya.cms.site.SiteException
getNodes
public org.apache.lenya.cms.site.SiteNode[] getNodes()
- Specified by:
getNodes
in interface org.apache.lenya.cms.site.SiteStructure
getPublication
public org.apache.lenya.cms.publication.Publication getPublication()
- Specified by:
getPublication
in interface org.apache.lenya.cms.site.SiteStructure
getTopLevelNodes
public org.apache.lenya.cms.site.SiteNode[] getTopLevelNodes()
- Specified by:
getTopLevelNodes
in interface org.apache.lenya.cms.site.SiteStructure
getSession
public org.apache.lenya.cms.repository.Session getSession()
- Specified by:
getSession
in interface org.apache.lenya.cms.repository.RepositoryItem
getNodeFactory
protected org.apache.lenya.cms.repository.NodeFactory getNodeFactory()
getRepositoryNode
public org.apache.lenya.cms.repository.Node getRepositoryNode()
- Specified by:
getRepositoryNode
in interface org.apache.lenya.cms.site.SiteStructure
getSourceUri
protected java.lang.String getSourceUri()
moveDown
public void moveDown(java.lang.String path)
throws org.apache.lenya.cms.site.SiteException
- Description copied from interface:
SiteTree
- Move down the node amongst its siblings.
- Specified by:
moveDown
in interface SiteTree
- Parameters:
path
- The document id of the node.
- Throws:
org.apache.lenya.cms.site.SiteException
- if the moving failed.
moveUp
public void moveUp(java.lang.String path)
throws org.apache.lenya.cms.site.SiteException
- Description copied from interface:
SiteTree
- Move up the node amongst its siblings.
- Specified by:
moveUp
in interface SiteTree
- Parameters:
path
- The document id of the node.
- Throws:
org.apache.lenya.cms.site.SiteException
- if the moving failed.
preOrder
public org.apache.lenya.cms.site.SiteNode[] preOrder()
- Specified by:
preOrder
in interface SiteTree
- Returns:
- The nodes in pre order.
save
public void save()
throws org.apache.lenya.cms.repository.RepositoryException
- Throws:
org.apache.lenya.cms.repository.RepositoryException
Copyright © $ Apache Software Foundation. All Rights Reserved.