|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.dao.support.DaoSupport
org.springframework.orm.ojb.support.PersistenceBrokerDaoSupport
org.apache.jetspeed.components.dao.InitablePersistenceBrokerDaoSupport
org.apache.jetspeed.page.impl.DatabasePageManager
public class DatabasePageManager
DatabasePageManager
| Field Summary |
|---|
| Fields inherited from class org.apache.jetspeed.components.dao.InitablePersistenceBrokerDaoSupport |
|---|
repositoryPath |
| Fields inherited from class org.springframework.dao.support.DaoSupport |
|---|
logger |
| Fields inherited from interface org.apache.jetspeed.page.PageManager |
|---|
SERVICE_NAME |
| Constructor Summary | |
|---|---|
DatabasePageManager(java.lang.String repositoryPath,
int cacheSize,
int cacheExpiresSeconds,
boolean isPermissionsSecurity,
boolean isConstraintsSecurity)
|
|
| Method Summary | |
|---|---|
void |
addListener(PageManagerEventListener listener)
addListener - add page manager event listener |
int |
addPages(Page[] pages)
|
boolean |
checkConstraint(java.lang.String securityConstraintName,
java.lang.String actions)
Given a securityConstraintName definition and a set of actions, run a security constraint checks |
Folder |
copyFolder(Folder source,
java.lang.String path)
Copy the source folder creating and returning a new copy of the folder with the same content as the source All subobjects are created with new ids |
Fragment |
copyFragment(Fragment source,
java.lang.String name)
Copy the source fragment creating and returning a new copy of the fragment with the parameter collection as the source The fragment is created with a new fragment id |
Link |
copyLink(Link source,
java.lang.String path)
Copy the source link creating and returning a new copy of the link |
Page |
copyPage(Page source,
java.lang.String path)
Copy the source page creating and returning a new copy of the page with the same portlet and fragment collection as the source All fragments are created with new fragment ids |
PageSecurity |
copyPageSecurity(PageSecurity source)
Copy the source page security (both global constraints and constraint references) creating and returning a new copy of the page security definition. |
void |
createUserHomePagesFromRoles(javax.security.auth.Subject subject)
Creates a user's home page from the roles of the current user. |
void |
deepCopyFolder(Folder srcFolder,
java.lang.String destinationPath,
java.lang.String owner)
Deep copy a folder. |
boolean |
folderExists(java.lang.String folderName)
Check if a folder exists for the given folder name |
NodeSet |
getAll(Folder folder)
getAll |
int |
getCacheExpiresSeconds()
getCacheExpiresSeconds |
int |
getCacheSize()
getCacheSize |
boolean |
getConstraintsEnabled()
getConstraintsEnabled |
ContentPage |
getContentPage(java.lang.String path)
ContentPage |
Folder |
getFolder(Folder folder,
java.lang.String name)
getFolder |
Folder |
getFolder(java.lang.String folderPath)
getFolder |
NodeSet |
getFolders(Folder folder)
getFolders |
Link |
getLink(Folder folder,
java.lang.String name)
getLink |
Link |
getLink(java.lang.String path)
getLink |
NodeSet |
getLinks(Folder folder)
getLinks |
Page |
getPage(Folder folder,
java.lang.String name)
getPage |
Page |
getPage(java.lang.String path)
getPage |
PageManager |
getPageManagerProxy()
getPageManagerProxy |
NodeSet |
getPages(Folder folder)
getPages |
PageSecurity |
getPageSecurity()
getPageSecurity |
PageSecurity |
getPageSecurity(Folder folder)
getPageSecurity |
boolean |
getPermissionsEnabled()
getPermissionsEnabled |
Folder |
getUserFolder(java.lang.String userName)
Retrieve a user's folder |
Page |
getUserPage(java.lang.String userName,
java.lang.String pageName)
Retrieve a page for the given user name and page name |
boolean |
linkExists(java.lang.String linkName)
Check if a link exists for the given link name |
Folder |
newFolder(java.lang.String path)
Create a new empty Folder instance |
MenuDefinition |
newFolderMenuDefinition()
newFolderMenuDefinition - creates a new empty menu definition |
MenuExcludeDefinition |
newFolderMenuExcludeDefinition()
newFolderMenuExcludeDefinition - creates a new empty menu exclude definition |
MenuIncludeDefinition |
newFolderMenuIncludeDefinition()
newFolderMenuIncludeDefinition - creates a new empty menu include definition |
MenuOptionsDefinition |
newFolderMenuOptionsDefinition()
newFolderMenuOptionsDefinition - creates a new empty menu options definition |
MenuSeparatorDefinition |
newFolderMenuSeparatorDefinition()
newFolderMenuSeparatorDefinition - creates a new empty menu separator definition |
SecurityConstraint |
newFolderSecurityConstraint()
newFolderSecurityConstraint - creates a new security constraint definition |
Fragment |
newFragment()
Creates a new empty Layout Fragment instance |
FragmentPreference |
newFragmentPreference()
newFragmentPreference - creates a new fragment preference |
SecurityConstraint |
newFragmentSecurityConstraint()
newFragmentSecurityConstraint - creates a new security constraint definition |
Link |
newLink(java.lang.String path)
Creates a new empty Link instance |
SecurityConstraint |
newLinkSecurityConstraint()
newLinkSecurityConstraint - creates a new security constraint definition |
Page |
newPage(java.lang.String path)
Creates a new empty Page instance |
MenuDefinition |
newPageMenuDefinition()
newPageMenuDefinition - creates a new empty menu definition |
MenuExcludeDefinition |
newPageMenuExcludeDefinition()
newPageMenuExcludeDefinition - creates a new empty menu exclude definition |
MenuIncludeDefinition |
newPageMenuIncludeDefinition()
newPageMenuIncludeDefinition - creates a new empty menu include definition |
MenuOptionsDefinition |
newPageMenuOptionsDefinition()
newPageMenuOptionsDefinition - creates a new empty menu options definition |
MenuSeparatorDefinition |
newPageMenuSeparatorDefinition()
newPageMenuSeparatorDefinition - creates a new empty menu separator definition |
PageSecurity |
newPageSecurity()
Creates a new empty PageSecurity instance |
SecurityConstraint |
newPageSecurityConstraint()
newPageSecurityConstraint - creates a new security constraint definition |
SecurityConstraint |
newPageSecuritySecurityConstraint()
newPageSecuritySecurityConstraint - creates a new security constraint definition |
Fragment |
newPortletFragment()
Creates a new empty Portlet Fragment instance |
SecurityConstraints |
newSecurityConstraints()
newSecurityConstraints - creates a new empty security constraints definition |
SecurityConstraintsDef |
newSecurityConstraintsDef()
newSecurityConstraintsDef - creates a new security constraints definition |
boolean |
pageExists(java.lang.String pageName)
Check if a page exists for the given page name |
void |
removeFolder(Folder folder)
Remove a folder. |
void |
removeLink(Link link)
Remove a link. |
void |
removeListener(PageManagerEventListener listener)
removeListener - remove page manager event listener |
void |
removePage(Page page)
Remove a document. |
void |
removePageSecurity(PageSecurity pageSecurity)
Remove a page security document. |
void |
reset()
reset - force subsequent refresh from persistent store |
void |
setPageManagerProxy(PageManager proxy)
setPageManagerProxy |
void |
updateFolder(Folder folder)
Update a folder and all child folders and documents in persistent storage |
void |
updateFolder(Folder folder,
boolean deep)
Update a folder in persistent storage |
void |
updateLink(Link link)
Update a link in persistent storage |
void |
updatePage(Page page)
Update a page in persistent storage |
void |
updatePageSecurity(PageSecurity pageSecurity)
Update a page security document in persistent storage |
boolean |
userFolderExists(java.lang.String userName)
Check if the root folder exists for a given user |
boolean |
userPageExists(java.lang.String userName,
java.lang.String pageName)
Check if a page exists for the given user |
| Methods inherited from class org.apache.jetspeed.components.dao.InitablePersistenceBrokerDaoSupport |
|---|
init |
| Methods inherited from class org.springframework.orm.ojb.support.PersistenceBrokerDaoSupport |
|---|
checkDaoConfig, closePersistenceBrokerIfNecessary, convertOjbAccessException, createPersistenceBrokerTemplate, getJcdAlias, getPersistenceBroker, getPersistenceBrokerTemplate, releasePersistenceBroker, setJcdAlias, setPersistenceBrokerTemplate |
| Methods inherited from class org.springframework.dao.support.DaoSupport |
|---|
afterPropertiesSet, initDao |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DatabasePageManager(java.lang.String repositoryPath,
int cacheSize,
int cacheExpiresSeconds,
boolean isPermissionsSecurity,
boolean isConstraintsSecurity)
| Method Detail |
|---|
public int getCacheSize()
public int getCacheExpiresSeconds()
public PageManager getPageManagerProxy()
public void setPageManagerProxy(PageManager proxy)
proxy - proxied page manager interface used to
inject into Folder instances to provide
transaction/interceptionpublic boolean getConstraintsEnabled()
PageManagergetConstraintsEnabled
getConstraintsEnabled in interface PageManagerpublic boolean getPermissionsEnabled()
PageManagergetPermissionsEnabled
getPermissionsEnabled in interface PageManagerpublic Page newPage(java.lang.String path)
PageManager
newPage in interface PageManagerpublic Folder newFolder(java.lang.String path)
PageManager
newFolder in interface PageManagerpublic Link newLink(java.lang.String path)
PageManager
newLink in interface PageManagerpublic PageSecurity newPageSecurity()
PageManager
newPageSecurity in interface PageManagerpublic Fragment newFragment()
PageManager
newFragment in interface PageManagerpublic Fragment newPortletFragment()
PageManager
newPortletFragment in interface PageManagerpublic MenuDefinition newFolderMenuDefinition()
PageManager
newFolderMenuDefinition in interface PageManagerpublic MenuExcludeDefinition newFolderMenuExcludeDefinition()
PageManager
newFolderMenuExcludeDefinition in interface PageManagerpublic MenuIncludeDefinition newFolderMenuIncludeDefinition()
PageManager
newFolderMenuIncludeDefinition in interface PageManagerpublic MenuOptionsDefinition newFolderMenuOptionsDefinition()
PageManager
newFolderMenuOptionsDefinition in interface PageManagerpublic MenuSeparatorDefinition newFolderMenuSeparatorDefinition()
PageManager
newFolderMenuSeparatorDefinition in interface PageManagerpublic MenuDefinition newPageMenuDefinition()
PageManager
newPageMenuDefinition in interface PageManagerpublic MenuExcludeDefinition newPageMenuExcludeDefinition()
PageManager
newPageMenuExcludeDefinition in interface PageManagerpublic MenuIncludeDefinition newPageMenuIncludeDefinition()
PageManager
newPageMenuIncludeDefinition in interface PageManagerpublic MenuOptionsDefinition newPageMenuOptionsDefinition()
PageManager
newPageMenuOptionsDefinition in interface PageManagerpublic MenuSeparatorDefinition newPageMenuSeparatorDefinition()
PageManager
newPageMenuSeparatorDefinition in interface PageManagerpublic SecurityConstraints newSecurityConstraints()
PageManager
newSecurityConstraints in interface PageManagerpublic SecurityConstraint newFolderSecurityConstraint()
PageManager
newFolderSecurityConstraint in interface PageManagerpublic SecurityConstraint newPageSecurityConstraint()
PageManager
newPageSecurityConstraint in interface PageManagerpublic SecurityConstraint newFragmentSecurityConstraint()
PageManager
newFragmentSecurityConstraint in interface PageManagerpublic SecurityConstraint newLinkSecurityConstraint()
PageManager
newLinkSecurityConstraint in interface PageManagerpublic SecurityConstraint newPageSecuritySecurityConstraint()
PageManager
newPageSecuritySecurityConstraint in interface PageManagerpublic SecurityConstraintsDef newSecurityConstraintsDef()
PageManager
newSecurityConstraintsDef in interface PageManagerpublic FragmentPreference newFragmentPreference()
PageManager
newFragmentPreference in interface PageManagerpublic void addListener(PageManagerEventListener listener)
PageManager
addListener in interface PageManagerlistener - page manager event listenerpublic void removeListener(PageManagerEventListener listener)
PageManager
removeListener in interface PageManagerlistener - page manager event listenerpublic void reset()
PageManager
reset in interface PageManager
public Page getPage(java.lang.String path)
throws PageNotFoundException,
NodeException
PageManagergetPage
Returns a Page based on its path
getPage in interface PageManagerPageNotFoundException - if the page cannot be found
NodeException
public ContentPage getContentPage(java.lang.String path)
throws PageNotFoundException,
NodeException
PageManagerContentPage
Returns a PSML document suitable for use in content rendering, for the given key
getContentPage in interface PageManagerPageNotFoundException - if the page cannot be found
NodeExceptionContentPage,
Fragment
public Link getLink(java.lang.String path)
throws DocumentNotFoundException,
NodeException
PageManagergetLink
Returns a Link document for the given path
getLink in interface PageManagerpath - The path of the document to be retrieved.
PageNotFoundException - if the page cannot be found
NodeException
DocumentNotFoundException
public boolean checkConstraint(java.lang.String securityConstraintName,
java.lang.String actions)
checkConstraint in interface PageManagersecurityConstraintName - the name of the security constraint definitionactions - one or more portlet actions (view,edit,help,..)
public PageSecurity getPageSecurity()
throws DocumentNotFoundException,
NodeException
PageManagergetPageSecurity
Returns the PageSecurity document
getPageSecurity in interface PageManagerDocumentNotFoundException - if the document cannot be found
UnsupportedDocumentTypeException
NodeException
public Folder getFolder(java.lang.String folderPath)
throws FolderNotFoundException,
InvalidFolderException,
NodeException
PageManagergetFolder
Locates a folder for the given path.
getFolder in interface PageManagerFolder object represented by the folderPath
FolderNotFoundException
InvalidFolderException
NodeException
public NodeSet getFolders(Folder folder)
throws DocumentException
PageManagergetFolders
Locates folders within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getFolders in interface PageManagerfolder - The parent folder.
NodeSet containing all sub-folders
directly under this folder.
DocumentExceptionorg.apache.jetspeed.om.folder.Folder#getFolders(org.apache.jetspeed.om.folder.Folder)
public Folder getFolder(Folder folder,
java.lang.String name)
throws FolderNotFoundException,
DocumentException
PageManagergetFolder
Locates folders within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getFolder in interface PageManagerfolder - The parent folder.name - The name of folder to retrieve.
FolderNotFoundException
DocumentExceptionorg.apache.jetspeed.om.folder.Folder#getFolder(org.apache.jetspeed.om.folder.Folder,java.lang.String)
public NodeSet getPages(Folder folder)
throws NodeException
PageManagergetPages
Locates documents within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getPages in interface PageManagerfolder - The parent folder.
NodeSet of all the Pages referenced
by this Folder.
NodeExceptionorg.apache.jetspeed.om.folder.Folder#getPages(org.apache.jetspeed.om.folder.Folder)
public Page getPage(Folder folder,
java.lang.String name)
throws PageNotFoundException,
NodeException
PageManagergetPage
Locates documents within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getPage in interface PageManagerfolder - The parent folder.name - The name of page to retrieve.
PageNotFoundException - if the Page requested could not be found.
NodeExceptionorg.apache.jetspeed.om.folder.Folder#getPage(org.apache.jetspeed.om.folder.Folder,java.lang.String)
public NodeSet getLinks(Folder folder)
throws NodeException
PageManagergetLinks
getLinks in interface PageManagerfolder - The parent folder.
NodeExceptionLocates documents within a specified parent folder.
Returned documents are filtered according to security
constraints and/or permissions.
public Link getLink(Folder folder,
java.lang.String name)
throws DocumentNotFoundException,
NodeException
PageManagergetLink
Locates documents within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getLink in interface PageManagerfolder - The parent folder.name - The name of page to retrieve.
DocumentNotFoundException - if the document requested could not be found.
NodeExceptionorg.apache.jetspeed.om.folder.Folder#getLink(org.apache.jetspeed.om.folder.Folder,java.lang.String)
public PageSecurity getPageSecurity(Folder folder)
throws DocumentNotFoundException,
NodeException
PageManagergetPageSecurity
Locates documents within a specified parent folder. Returned documents are filtered according to security constraints and/or permissions.
getPageSecurity in interface PageManagerfolder - The parent folder.
DocumentNotFoundException - if the document requested could not be found.
NodeExceptionorg.apache.jetspeed.om.folder.Folder#getPageSecurity(org.apache.jetspeed.om.folder.Folder)
public NodeSet getAll(Folder folder)
throws DocumentException
PageManagergetAll
Locates folders and documents within a specified parent folder. Returned folders and documents are filtered according to security constraints and/or permissions.
getAll in interface PageManagerfolder - The parent folder.
NodeSet containing all sub-folders
and documents directly under this folder.
DocumentExceptionorg.apache.jetspeed.om.folder.Folder#getAll(org.apache.jetspeed.om.folder.Folder)
public void updatePage(Page page)
throws NodeException,
PageNotUpdatedException
PageManager
updatePage in interface PageManagerpage - The page to be updated.
NodeException
PageNotUpdatedException
public void removePage(Page page)
throws NodeException,
PageNotRemovedException
PageManager
removePage in interface PageManagerpage - The page to be removed.
NodeException
PageNotRemovedException
public void updateFolder(Folder folder)
throws NodeException,
FolderNotUpdatedException
PageManager
updateFolder in interface PageManagerfolder - The folder to be updated.
NodeException
FolderNotUpdatedException
public void updateFolder(Folder folder,
boolean deep)
throws NodeException,
FolderNotUpdatedException
PageManager
updateFolder in interface PageManagerfolder - The folder to be updated.deep - Flag to control recursive deep updates.
NodeException
FolderNotUpdatedException
public void removeFolder(Folder folder)
throws NodeException,
FolderNotRemovedException
PageManager
removeFolder in interface PageManagerNodeException
FolderNotRemovedException
public void updateLink(Link link)
throws NodeException,
LinkNotUpdatedException
PageManager
updateLink in interface PageManagerlink - The link to be updated.
NodeException
LinkNotUpdatedException
public void removeLink(Link link)
throws NodeException,
LinkNotRemovedException
PageManager
removeLink in interface PageManagerlink - The link to be removed.
NodeException
LinkNotRemovedException
public void updatePageSecurity(PageSecurity pageSecurity)
throws NodeException,
FailedToUpdateDocumentException
PageManager
updatePageSecurity in interface PageManagerpageSecurity - The document to be updated.
NodeException
FailedToUpdateDocumentException
public void removePageSecurity(PageSecurity pageSecurity)
throws NodeException,
FailedToDeleteDocumentException
PageManager
removePageSecurity in interface PageManagerpageSecurity - The document to be removed.
NodeException
FailedToDeleteDocumentException
public Page copyPage(Page source,
java.lang.String path)
throws NodeException,
PageNotUpdatedException
PageManager
copyPage in interface PageManagersource - The source Page object to be copiedpath - a PSML normalized path to the new page to be created
NodeException
PageNotUpdatedException
public Link copyLink(Link source,
java.lang.String path)
throws NodeException,
LinkNotUpdatedException
PageManager
copyLink in interface PageManagersource - The source Link object to be copiedpath - a PSML normalized path to the new link to be created
NodeException
LinkNotUpdatedException
public Folder copyFolder(Folder source,
java.lang.String path)
throws NodeException,
PageNotUpdatedException
PageManager
copyFolder in interface PageManagersource - The source Folder object to be copiedpath - a PSML normalized path to the new folder to be created
NodeException
PageNotUpdatedException
public Fragment copyFragment(Fragment source,
java.lang.String name)
throws NodeException,
PageNotUpdatedException
PageManager
copyFragment in interface PageManagersource - The source Fragment object to be copied
NodeException
PageNotUpdatedException
public PageSecurity copyPageSecurity(PageSecurity source)
throws NodeException
PageManager
copyPageSecurity in interface PageManagersource - The source PageSecurity definitions
NodeException
public Page getUserPage(java.lang.String userName,
java.lang.String pageName)
throws PageNotFoundException,
NodeException
PageManager
getUserPage in interface PageManagerPageNotFoundException
NodeException
public Folder getUserFolder(java.lang.String userName)
throws FolderNotFoundException,
InvalidFolderException,
NodeException
PageManager
getUserFolder in interface PageManagerFolderNotFoundException
InvalidFolderException
NodeExceptionpublic boolean folderExists(java.lang.String folderName)
PageManager
folderExists in interface PageManagerpublic boolean pageExists(java.lang.String pageName)
PageManager
pageExists in interface PageManagerpublic boolean linkExists(java.lang.String linkName)
PageManager
linkExists in interface PageManagerpublic boolean userFolderExists(java.lang.String userName)
PageManager
userFolderExists in interface PageManager
public boolean userPageExists(java.lang.String userName,
java.lang.String pageName)
PageManager
userPageExists in interface PageManager
public void createUserHomePagesFromRoles(javax.security.auth.Subject subject)
throws NodeException
PageManager
createUserHomePagesFromRoles in interface PageManagersubject - The full user Java Security subject.
NodeException
public void deepCopyFolder(Folder srcFolder,
java.lang.String destinationPath,
java.lang.String owner)
throws NodeException,
PageNotUpdatedException
PageManager
deepCopyFolder in interface PageManagerowner - set owner of the new folder(s), or null for no owner
NodeException
PageNotUpdatedException
public int addPages(Page[] pages)
throws NodeException
addPages in interface PageManagerNodeException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||