public class BrowseBean extends Object implements IContextListener, Serializable
Constructor and Description |
---|
BrowseBean()
Default Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
addNodeEventListener(NodeEventListener listener)
Add a listener to those called by the BrowseBean when nodes are created
|
void |
areaChanged()
Method called by UIContextService.areaChanged() to inform all registered beans that
the user has changed area i.e.
|
void |
clickDescendantSpace(ActionEvent event)
Action called when a folders direct descendant (in the 'list' browse mode) is clicked.
|
void |
clickSpace(ActionEvent event)
Action called when a folder space is clicked.
|
void |
clickSpace(org.alfresco.service.cmr.repository.NodeRef nodeRef)
Action called when a folder space is clicked.
|
void |
clickSpacePath(ActionEvent event)
Handler called when a path element is clicked - navigate to the appropriate Space
|
void |
closeSearch(ActionEvent event)
Action called to Close the search dialog by returning to the last view node Id
|
void |
contextUpdated()
Method called by UIContextService.notifyBeans() to inform all registered beans that
all UI Beans should refresh dump all cached data and settings.
|
void |
deleteFile(ActionEvent event)
Event handler used when a file is being deleted, checks that the node
does not have an associated working copy.
|
void |
deleteSpace(ActionEvent event)
Handles the deleteSpace action by deciding which delete dialog to display
|
void |
expandPanel(ActionEvent event)
Save the state of the panel that was expanded/collapsed
|
void |
externalAccessRefresh()
Support for refresh of lists via special case for an External Access URL.
|
Node |
getActionSpace() |
String |
getBrowseViewMode() |
protected CheckOutCheckInService |
getCheckOutCheckInService() |
List<Node> |
getContent()
Page accessed bean method to get the content nodes currently being browsed
|
UIRichList |
getContentRichList() |
String |
getDeleteMessage() |
protected org.alfresco.service.cmr.dictionary.DictionaryService |
getDictionaryService() |
Node |
getDocument() |
protected FileFolderService |
getFileFolderService() |
protected LockService |
getLockService() |
static int |
getMinimumSearchLength() |
protected MultilingualContentService |
getMultilingualContentService() |
List<Node> |
getNodes()
Page accessed bean method to get the container nodes currently being browsed
|
protected org.alfresco.service.cmr.repository.NodeService |
getNodeService() |
int |
getPageSizeContent() |
String |
getPageSizeContentStr() |
int |
getPageSizeSpaces() |
String |
getPageSizeSpacesStr() |
Map<String,Boolean> |
getPanels() |
List<Node> |
getParentNodes(org.alfresco.service.cmr.repository.NodeRef currNodeRef)
Page accessed bean method to get the parent container nodes currently being browsed
|
protected org.alfresco.service.cmr.search.SearchService |
getSearchService() |
String |
getSitesSpaceWarningHTML()
Returns the HTML to display if a space is a 'Sites' space
|
UIRichList |
getSpacesRichList() |
UIStatusMessage |
getStatusMessage() |
boolean |
isDashboardView() |
boolean |
isSitesSpace()
Determines whether the current space is a 'Sites' space
|
void |
removeNodeEventListener(NodeEventListener listener)
Remove a listener from the list of those called by BrowseBean
|
void |
removeSpaceFromBreadcrumb(Node node)
Removes the given node from the breadcrumb i.e.
|
void |
search(ActionEvent event)
Action called from the Simple Search component.
|
void |
setActionSpace(Node actionSpace) |
void |
setBrowseViewMode(String browseViewMode) |
void |
setCheckOutCheckInService(CheckOutCheckInService checkOutCheckInService) |
void |
setContentRichList(UIRichList contentRichList) |
void |
setDashboardView(boolean dashboardView) |
void |
setDeleteMessage(String deleteMessage) |
void |
setDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService) |
void |
setDocument(Node document) |
void |
setFileFolderService(FileFolderService fileFolderService) |
void |
setLockService(LockService lockService) |
void |
setMultilingualContentService(MultilingualContentService multilingualContentService) |
void |
setNavigator(NavigationBean navigator) |
void |
setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService) |
void |
setPageSizeContent(int pageSizeContent) |
void |
setPageSizeContentStr(String pageSizeContentStr) |
void |
setPageSizeSpaces(int pageSizeSpaces) |
void |
setPageSizeSpacesStr(String pageSizeSpacesStr) |
void |
setPanels(Map<String,Boolean> panels) |
void |
setSearchService(org.alfresco.service.cmr.search.SearchService searchService) |
void |
setSpacesRichList(UIRichList spacesRichList) |
void |
setStatusMessage(UIStatusMessage statusMessage) |
void |
setupCommonBindingProperties(Node node)
Setup the common properties required at data-binding time.
|
void |
setupContentAction(ActionEvent event)
Action event called by all actions that need to setup a Content Document context on the
BrowseBean before an action page/wizard is called.
|
void |
setupContentAction(String id,
boolean invalidate)
Public helper to setup action pages with content context
|
void |
setupDeleteAction(ActionEvent event)
Acrtion event called by Delete Space actions.
|
void |
setupMLContainerContentAction(ActionEvent event)
Action event called by all actions that need to setup a Multilingual Content Document context on the
BrowseBean before an action page/wizard is called.
|
void |
setupSpaceAction(ActionEvent event)
Action event called by all Browse actions that need to setup a Space context
before an action page/wizard is called.
|
void |
setupSpaceAction(String id,
boolean invalidate)
Public helper to setup action pages with Space context
|
void |
setUserPreferencesBean(UserPreferencesBean userPreferencesBean) |
void |
spaceChanged()
Method called by UIContextService.spaceChanged() to inform all registered beans that
the current space has changed.
|
void |
updateContentPageSize(ActionEvent event)
Update page size based on user selection
|
void |
updateSpacesPageSize(ActionEvent event)
Update page size based on user selection
|
void |
updateUILocation(org.alfresco.service.cmr.repository.NodeRef ref)
Refresh the UI after a Space selection change.
|
void |
viewModeChanged(ActionEvent event)
Change the current view mode based on user selection
|
public static final String BEAN_NAME
public NodePropertyResolver resolverDownload
public NodePropertyResolver resolverUrl
public NodePropertyResolver resolverWebdavUrl
public NodePropertyResolver resolverCifsPath
public NodePropertyResolver resolverLinkDownload
public NodePropertyResolver resolverLinkUrl
public NodePropertyResolver resolverLinkWebdavUrl
public NodePropertyResolver resolverLinkCifsPath
public NodePropertyResolver resolverFileType16
public NodePropertyResolver resolverFileType32
public NodePropertyResolver resolverPath
public NodePropertyResolver resolverDisplayPath
public NodePropertyResolver resolverSpaceIcon
public NodePropertyResolver resolverSmallIcon
public NodePropertyResolver resolverMimetype
public NodePropertyResolver resolverEncoding
public NodePropertyResolver resolverSize
public NodePropertyResolver resolverLang
public static final String BROWSE_VIEW_ID
public static final String CATEGORY_VIEW_ID
public static final String SPACE_SMALL_DEFAULT
public static final String MSG_SEARCH_MINIMUM
protected NavigationBean navigator
protected UserPreferencesBean userPreferencesBean
protected ViewsConfigElement viewsConfig
protected Set<NodeEventListener> nodeEventListeners
protected UIRichList spacesRichList
protected UIRichList contentRichList
protected List<Node> containerNodes
protected Node actionSpace
protected Node document
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
nodeService
- The NodeService to set.protected org.alfresco.service.cmr.repository.NodeService getNodeService()
public void setCheckOutCheckInService(CheckOutCheckInService checkOutCheckInService)
checkOutCheckInService
- The service for check-in and check-out.protected CheckOutCheckInService getCheckOutCheckInService()
public void setSearchService(org.alfresco.service.cmr.search.SearchService searchService)
searchService
- The Searcher to set.protected org.alfresco.service.cmr.search.SearchService getSearchService()
public void setUserPreferencesBean(UserPreferencesBean userPreferencesBean)
userPreferencesBean
- The UserPreferencesBean to set.public void setLockService(LockService lockService)
lockService
- The Lock Service to set.protected LockService getLockService()
public void setNavigator(NavigationBean navigator)
navigator
- The NavigationBean to set.public void setDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)
dictionaryService
- The DictionaryService to set.protected org.alfresco.service.cmr.dictionary.DictionaryService getDictionaryService()
public void setMultilingualContentService(MultilingualContentService multilingualContentService)
multilingualContentService
- The Multilingual Content Service to set.protected MultilingualContentService getMultilingualContentService()
public void setFileFolderService(FileFolderService fileFolderService)
fileFolderService
- The FileFolderService to set.protected FileFolderService getFileFolderService()
public String getBrowseViewMode()
public void setBrowseViewMode(String browseViewMode)
browseViewMode
- The browse View mode to set. See UIRichList.public boolean isDashboardView()
public void setDashboardView(boolean dashboardView)
dashboardView
- The dashboard view mode to set.public int getPageSizeContent()
public void setPageSizeContent(int pageSizeContent)
public int getPageSizeSpaces()
public void setPageSizeSpaces(int pageSizeSpaces)
public String getPageSizeContentStr()
public void setPageSizeContentStr(String pageSizeContentStr)
public String getPageSizeSpacesStr()
public void setPageSizeSpacesStr(String pageSizeSpacesStr)
public static int getMinimumSearchLength()
public void setPanels(Map<String,Boolean> panels)
panels
- The panels expanded state map.public Node getActionSpace()
public void setActionSpace(Node actionSpace)
actionSpace
- Set the Space Node to be used for the current browse screen action.public Node getDocument()
public void setDocument(Node document)
document
- The document node to be used for the current operationpublic void setContentRichList(UIRichList contentRichList)
contentRichList
- The contentRichList to set.public UIRichList getContentRichList()
public void setSpacesRichList(UIRichList spacesRichList)
spacesRichList
- The spacesRichList to set.public UIRichList getSpacesRichList()
public UIStatusMessage getStatusMessage()
public void setStatusMessage(UIStatusMessage statusMessage)
statusMessage
- The statusMessage component to set.public String getDeleteMessage()
public void setDeleteMessage(String deleteMessage)
deleteMessage
- The deleteMessage to set.public List<Node> getNodes()
public List<Node> getContent()
public List<Node> getParentNodes(org.alfresco.service.cmr.repository.NodeRef currNodeRef)
public boolean isSitesSpace()
public String getSitesSpaceWarningHTML()
public void setupCommonBindingProperties(Node node)
These are properties used by components on the page when iterating over the nodes. The properties are available as the Node is a Map so they can be accessed directly by name. Information such as download URL, size and filetype are provided etc.
We use a set of anonymous inner classes to provide the implemention for the property getters. The interfaces are only called when the properties are first requested.
node
- Node to add the properties toopublic void contextUpdated()
IContextListener
contextUpdated
in interface IContextListener
IContextListener.contextUpdated()
public void areaChanged()
IContextListener
areaChanged
in interface IContextListener
IContextListener.areaChanged()
public void spaceChanged()
IContextListener
spaceChanged
in interface IContextListener
IContextListener.spaceChanged()
public void addNodeEventListener(NodeEventListener listener)
public void removeNodeEventListener(NodeEventListener listener)
public void viewModeChanged(ActionEvent event)
event
- ActionEventpublic void search(ActionEvent event)
public void closeSearch(ActionEvent event)
public void updateSpacesPageSize(ActionEvent event)
public void updateContentPageSize(ActionEvent event)
public void clickSpace(ActionEvent event)
public void clickSpace(org.alfresco.service.cmr.repository.NodeRef nodeRef)
nodeRef
- The node being clickedpublic void clickSpacePath(ActionEvent event)
public void clickDescendantSpace(ActionEvent event)
public void setupSpaceAction(ActionEvent event)
event
- ActionEventpublic void setupSpaceAction(String id, boolean invalidate)
id
- of the Space node to setup context forpublic void setupDeleteAction(ActionEvent event)
public void setupContentAction(ActionEvent event)
public void setupMLContainerContentAction(ActionEvent event)
public void setupContentAction(String id, boolean invalidate)
id
- of the content node to setup context forpublic void removeSpaceFromBreadcrumb(Node node)
node
- The space to remove from the breadcrumbpublic void externalAccessRefresh()
public void expandPanel(ActionEvent event)
public void updateUILocation(org.alfresco.service.cmr.repository.NodeRef ref)
ref
- NodeRef of the selected spacepublic void deleteFile(ActionEvent event)
event
- The eventpublic void deleteSpace(ActionEvent event)
Copyright © 2005–2017 Alfresco Software. All rights reserved.