Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.webapp.documentsLists
Class DocumentsListsManagerBean

java.lang.Object
  extended by org.nuxeo.ecm.webapp.documentsLists.BaseDocumentsListsManager
      extended by org.nuxeo.ecm.webapp.documentsLists.DocumentsListsManagerBean
All Implemented Interfaces:
Serializable, DocumentsListsManager

@Name(value="documentsListsManager")
@Scope(value=SESSION)
public class DocumentsListsManagerBean
extends BaseDocumentsListsManager
implements DocumentsListsManager

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.nuxeo.ecm.webapp.documentsLists.DocumentsListsManager
CLIPBOARD, CURRENT_DOCUMENT_SECTION_SELECTION, CURRENT_DOCUMENT_SELECTION, CURRENT_DOCUMENT_TRASH_SELECTION, DEFAULT_WORKING_LIST
 
Constructor Summary
DocumentsListsManagerBean()
           
 
Method Summary
 List<DocumentModel> addToWorkingList(DocumentModel doc)
          Adds one document to the default list.
 List<DocumentModel> addToWorkingList(List<DocumentModel> docList)
          Adds a list of DocumentModels to the default list.
 List<DocumentModel> addToWorkingList(String listName, DocumentModel doc)
          Adds one document to the list listName.
 List<DocumentModel> addToWorkingList(String listName, List<DocumentModel> docList)
          Adds a list of DocumentModels to the list ListName.
 List<DocumentModel> addToWorkingList(String listName, List<DocumentModel> docList, Boolean forceAppend)
          Adds a list of DocumentModels to the list ListName.
 void createWorkingList(String listName, DocumentsListDescriptor descriptor)
          Creates (declares) a new named list of documents.
 List<DocumentModel> getWorkingList()
          Returns the default list.
 List<DocumentModel> getWorkingList(String listName)
          Returns the list listName.
 DocumentsListDescriptor getWorkingListDescriptor()
          Gets the descriptor (meta-data) of a default list.
 DocumentsListDescriptor getWorkingListDescriptor(String listName)
          Gets the descriptor (meta-data) of a given list.
 List<String> getWorkingListNamesForCategory(String categoryName)
          Returns the availables lists names for a given category.
 List<String> getWorkingListTypes()
          Returns the list of document types contained in the default list.
 List<String> getWorkingListTypes(String listName)
          Returns the list of document types contained into the list ListName.
 void initListManager()
          Init Method (replaces for now Registry initialization that will be done by the extension point and the Runtime).
 boolean isWorkingListEmpty()
          Checks if default list is empty.
 boolean isWorkingListEmpty(String listName)
          Check is list listName is empty.
 void refreshLists(DocumentModel currentDocument)
          Method called by Seam event service to reset lists.
 void refreshListsOnSearch()
          Refresh lists when a search is performed
 void removeFromAllLists(List<DocumentModel> documentsToRemove)
          Removes documentsToRemove from all lists.
 List<DocumentModel> removeFromWorkingList(DocumentModel doc)
          Removes one DocumentModel from the default list.
 List<DocumentModel> removeFromWorkingList(String listName, DocumentModel doc)
          Removes one DocumentModel from the list ListName.
 List<DocumentModel> removeFromWorkingList(String listName, List<DocumentModel> lst)
           
 List<DocumentModel> resetWorkingList()
          Removes DocumentModels from the default list.
 List<DocumentModel> resetWorkingList(List<DocumentModel> newDocList)
          Resets default list and fills it with newDocList.
 List<DocumentModel> resetWorkingList(String listName)
          Removes DocumentModels from the list ListName.
 List<DocumentModel> resetWorkingList(String listName, List<DocumentModel> newDocList)
          Resets list listName and fill it with newDocList.
 void setWorkingList(List<DocumentModel> docList)
          Updates the default list.
 void setWorkingList(String listName, List<DocumentModel> docList)
          Updates the list listName.
 
Methods inherited from class org.nuxeo.ecm.webapp.documentsLists.BaseDocumentsListsManager
createWorkingList
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DocumentsListsManagerBean

public DocumentsListsManagerBean()
Method Detail

initListManager

@Create
public void initListManager()
Description copied from interface: DocumentsListsManager
Init Method (replaces for now Registry initialization that will be done by the extension point and the Runtime).

Specified by:
initListManager in interface DocumentsListsManager

createWorkingList

public void createWorkingList(String listName,
                              DocumentsListDescriptor descriptor)
Description copied from interface: DocumentsListsManager
Creates (declares) a new named list of documents.

Specified by:
createWorkingList in interface DocumentsListsManager
Overrides:
createWorkingList in class BaseDocumentsListsManager
Parameters:
listName - Name of the list

getWorkingList

public List<DocumentModel> getWorkingList(String listName)
Description copied from interface: DocumentsListsManager
Returns the list listName.

Specified by:
getWorkingList in interface DocumentsListsManager
Overrides:
getWorkingList in class BaseDocumentsListsManager
Parameters:
listName - Name of the list
Returns:

getWorkingListTypes

public List<String> getWorkingListTypes(String listName)
Description copied from interface: DocumentsListsManager
Returns the list of document types contained into the list ListName.

Specified by:
getWorkingListTypes in interface DocumentsListsManager
Overrides:
getWorkingListTypes in class BaseDocumentsListsManager
Parameters:
listName - Name of the list to retrieve
Returns:
the DocumentModel List or null if the ListName is unknown

setWorkingList

public void setWorkingList(String listName,
                           List<DocumentModel> docList)
Description copied from interface: DocumentsListsManager
Updates the list listName.

Specified by:
setWorkingList in interface DocumentsListsManager
Overrides:
setWorkingList in class BaseDocumentsListsManager
Parameters:
listName - Name of the list to update
docList - the DocumentModel list to store in the list ListName

addToWorkingList

public List<DocumentModel> addToWorkingList(String listName,
                                            DocumentModel doc)
Description copied from interface: DocumentsListsManager
Adds one document to the list listName.

Specified by:
addToWorkingList in interface DocumentsListsManager
Overrides:
addToWorkingList in class BaseDocumentsListsManager
Parameters:
listName - the name of the list to update
doc - the doc to append
Returns:
the updated list of DocumentModels

addToWorkingList

public List<DocumentModel> addToWorkingList(String listName,
                                            List<DocumentModel> docList)
Description copied from interface: DocumentsListsManager
Adds a list of DocumentModels to the list ListName.

Specified by:
addToWorkingList in interface DocumentsListsManager
Overrides:
addToWorkingList in class BaseDocumentsListsManager
Parameters:
listName - the name of the list to update
docList - the DocumentModels list to append
Returns:
the updated list of DocumentModels

addToWorkingList

public List<DocumentModel> addToWorkingList(String listName,
                                            List<DocumentModel> docList,
                                            Boolean forceAppend)
Description copied from interface: DocumentsListsManager
Adds a list of DocumentModels to the list ListName.

Specified by:
addToWorkingList in interface DocumentsListsManager
Overrides:
addToWorkingList in class BaseDocumentsListsManager
Parameters:
listName - the name of the list to update
docList - the DocumentModels list to append
forceAppend - force the new elements to be appened even if the list default behaviour is reset
Returns:
the updated list of DocumentModels

removeFromWorkingList

public List<DocumentModel> removeFromWorkingList(String listName,
                                                 DocumentModel doc)
Description copied from interface: DocumentsListsManager
Removes one DocumentModel from the list ListName.

Specified by:
removeFromWorkingList in interface DocumentsListsManager
Overrides:
removeFromWorkingList in class BaseDocumentsListsManager
Returns:
the updated list of DocumentModels

removeFromWorkingList

public List<DocumentModel> removeFromWorkingList(String listName,
                                                 List<DocumentModel> lst)
Specified by:
removeFromWorkingList in interface DocumentsListsManager
Overrides:
removeFromWorkingList in class BaseDocumentsListsManager

resetWorkingList

public List<DocumentModel> resetWorkingList(String listName)
Description copied from interface: DocumentsListsManager
Removes DocumentModels from the list ListName.

Specified by:
resetWorkingList in interface DocumentsListsManager
Overrides:
resetWorkingList in class BaseDocumentsListsManager
Returns:
the updated list of DocumentModels

resetWorkingList

public List<DocumentModel> resetWorkingList(String listName,
                                            List<DocumentModel> newDocList)
Description copied from interface: DocumentsListsManager
Resets list listName and fill it with newDocList.

Specified by:
resetWorkingList in interface DocumentsListsManager
Overrides:
resetWorkingList in class BaseDocumentsListsManager
Returns:

isWorkingListEmpty

public boolean isWorkingListEmpty(String listName)
Description copied from interface: DocumentsListsManager
Check is list listName is empty.

Specified by:
isWorkingListEmpty in interface DocumentsListsManager
Overrides:
isWorkingListEmpty in class BaseDocumentsListsManager
Returns:
true if the list is Empty

removeFromAllLists

public void removeFromAllLists(List<DocumentModel> documentsToRemove)
Description copied from interface: DocumentsListsManager
Removes documentsToRemove from all lists.

Specified by:
removeFromAllLists in interface DocumentsListsManager
Overrides:
removeFromAllLists in class BaseDocumentsListsManager

getWorkingListNamesForCategory

public List<String> getWorkingListNamesForCategory(String categoryName)
Description copied from interface: DocumentsListsManager
Returns the availables lists names for a given category.

Specified by:
getWorkingListNamesForCategory in interface DocumentsListsManager
Overrides:
getWorkingListNamesForCategory in class BaseDocumentsListsManager
Returns:
the names of the available lists

getWorkingListDescriptor

public DocumentsListDescriptor getWorkingListDescriptor(String listName)
Description copied from interface: DocumentsListsManager
Gets the descriptor (meta-data) of a given list.

Specified by:
getWorkingListDescriptor in interface DocumentsListsManager
Overrides:
getWorkingListDescriptor in class BaseDocumentsListsManager
Returns:
the Descriptor of the DocumentModel list

getWorkingList

public List<DocumentModel> getWorkingList()
Description copied from interface: DocumentsListsManager
Returns the default list.

Specified by:
getWorkingList in interface DocumentsListsManager
Returns:

getWorkingListDescriptor

public DocumentsListDescriptor getWorkingListDescriptor()
Description copied from interface: DocumentsListsManager
Gets the descriptor (meta-data) of a default list.

Specified by:
getWorkingListDescriptor in interface DocumentsListsManager
Returns:
the Descriptor of the DocumentModel list

getWorkingListTypes

public List<String> getWorkingListTypes()
Description copied from interface: DocumentsListsManager
Returns the list of document types contained in the default list.

Specified by:
getWorkingListTypes in interface DocumentsListsManager
Returns:
the DocumentModel List

setWorkingList

public void setWorkingList(List<DocumentModel> docList)
Description copied from interface: DocumentsListsManager
Updates the default list.

Specified by:
setWorkingList in interface DocumentsListsManager
Parameters:
docList - the DocumentModel list to store in the default list

addToWorkingList

public List<DocumentModel> addToWorkingList(DocumentModel doc)
Description copied from interface: DocumentsListsManager
Adds one document to the default list.

Specified by:
addToWorkingList in interface DocumentsListsManager
Returns:
the updated list of DocumentModels

addToWorkingList

public List<DocumentModel> addToWorkingList(List<DocumentModel> docList)
Description copied from interface: DocumentsListsManager
Adds a list of DocumentModels to the default list.

Specified by:
addToWorkingList in interface DocumentsListsManager
Returns:
the updated list of DocumentModels

removeFromWorkingList

public List<DocumentModel> removeFromWorkingList(DocumentModel doc)
Description copied from interface: DocumentsListsManager
Removes one DocumentModel from the default list.

Specified by:
removeFromWorkingList in interface DocumentsListsManager
Returns:
the updated list of DocumentModels

resetWorkingList

public List<DocumentModel> resetWorkingList()
Description copied from interface: DocumentsListsManager
Removes DocumentModels from the default list.

Specified by:
resetWorkingList in interface DocumentsListsManager
Returns:
the updated list of DocumentModels

resetWorkingList

public List<DocumentModel> resetWorkingList(List<DocumentModel> newDocList)
Description copied from interface: DocumentsListsManager
Resets default list and fills it with newDocList.

Specified by:
resetWorkingList in interface DocumentsListsManager
Returns:
the updated list of DocumentModels

isWorkingListEmpty

public boolean isWorkingListEmpty()
Description copied from interface: DocumentsListsManager
Checks if default list is empty.

Specified by:
isWorkingListEmpty in interface DocumentsListsManager
Returns:
true if the list is Empty

refreshLists

@Observer(value="folderishDocumentSelectionChanged",
          create=false)
public void refreshLists(DocumentModel currentDocument)
Description copied from interface: DocumentsListsManager
Method called by Seam event service to reset lists.

Specified by:
refreshLists in interface DocumentsListsManager

refreshListsOnSearch

@Observer(value="searchPerformed",
          create=false)
public void refreshListsOnSearch()
Refresh lists when a search is performed


Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.