Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.webapp.clipboard
Interface ClipboardActions

All Known Implementing Classes:
ClipboardActionsBean

public interface ClipboardActions

Interface for clipboard template page action listener. Exposes methods for handling user actions related to the copy/paste buttons from clipboard.xhtml template.

Author:
Razvan Caraghin

Method Summary
 String clearWorkingList()
          Called when the "delete all" button is clicked on the clipboard.
 void copySelection(List<DocumentModel> docCopied)
          Called when the drag and drop is launched in the clipboard fragment.
 String exportAllBlobsFromWorkingListAsZip()
           
 String exportMainBlobFromWorkingListAsZip()
           
 String exportWorklistAsZip()
           
 String exportWorklistAsZip(List<DocumentModel> documents)
           
 String exportWorklistAsZip(List<DocumentModel> documents, boolean exportAllBlobs)
           
 boolean factoryForIsCurrentWorkListEmpty()
           
 List<Action> getActionsForCurrentList()
          Returns the list of available web actions for the currently selected DocumentList.
 List<Action> getActionsForSelection()
          Returns the list of available web actions for the currently selected Documents.
 List<String> getAvailableLists()
          Returns the list of available lists (ie: the lists from the CLIPBOARD Category).
 String getCacheKey()
           
 boolean getCanCopy()
          Checks if there are selected items that can be copied into the current worklist.
 boolean getCanEditListDocs(String listName)
          Checks if documents in the specified list are editable so the bulk editing action can be invoked later.
 boolean getCanEditSelectedDocs()
          Checks for documents bulk editing action.
 boolean getCanMoveFromClipboardInside(DocumentModel document)
          Checks if the documents from the clipboard can be moved into the given document
 boolean getCanMoveInside(String listName, DocumentModel document)
          Checks if the documents in a given worklist can be moved into the given document
 boolean getCanMoveWorkingList()
          Checks if there are documents in current worklist can be moved into the current folder.
 boolean getCanPaste(String listName)
          Checks if the content of a given workList can be pasted.
 boolean getCanPasteFromClipboard()
          Shortcut for getCanPaste on the clipboard.
 boolean getCanPasteFromClipboardInside(DocumentModel document)
           
 boolean getCanPasteInside(String listName, DocumentModel document)
           
 boolean getCanPasteWorkList()
          Shortcut for getCanPaste on the currently selected workList.
 List<DocumentModel> getCurrentSelectedList()
          Retries contents of current WorkList.
 String getCurrentSelectedListName()
          Returns the name of the current selected WorkList.
 String getCurrentSelectedListTitle()
           
 List<DocumentsListDescriptor> getDescriptorsForAvailableLists()
          Returns the list of Descriptors for available lists.
 boolean isCacheEnabled()
           
 boolean isCacheEnabledForSelection()
           
 boolean isInitialized()
           
 boolean isWorkListEmpty()
          Checks if the currently selected WorkList is empty.
 String moveClipboardInside(String docId)
           
 String moveWorkingList()
          Called when the "move all" button is clicked on the clipboard/selection
 String pasteClipboard()
           
 String pasteClipboardInside(String docId)
           
 String pasteDocumentList(List<DocumentModel> docPaste)
          Called when the drag and drop is launched in the body fragment.
 String pasteDocumentList(String listName)
          Pastes the content of the list listName into the current context document.
 String pasteDocumentListInside(List<DocumentModel> docPaste, String docId)
           
 String pasteDocumentListInside(String listName, String docId)
           
 String pasteWorkingList()
          Called when the "paste all" button is clicked on the clipboard.
 void putInClipboard(String docId)
           
 void putSelectionInClipboard()
           
 void putSelectionInDefaultWorkList()
           
 void putSelectionInWorkList()
          Copies the lists of selected documents into the current WorkList.
 void putSelectionInWorkList(Boolean forceAppend)
           
 void putSelectionInWorkList(List<DocumentModel> docsList)
          Copies docsList into the current WorkList.
 void putSelectionInWorkList(List<DocumentModel> docsList, Boolean forceAppend)
           
 void releaseClipboardableDocuments()
           
 String removeWorkListItem(DocumentRef ref)
          Called when the delete button is clicked on the clipboard.
 void selectList()
           
 void setCurrentSelectedList(String listId)
          Sets the current selected WorkList.
 

Method Detail

copySelection

void copySelection(List<DocumentModel> docCopied)
Called when the drag and drop is launched in the clipboard fragment. Copies the documents passed to the clipboard.

The selection is added to the clipboard and to the WorkingList.

Parameters:
docCopied - the list of documents we want to copy

removeWorkListItem

String removeWorkListItem(DocumentRef ref)
                          throws ClientException
Called when the delete button is clicked on the clipboard.

Throws:
ClientException

clearWorkingList

String clearWorkingList()
Called when the "delete all" button is clicked on the clipboard.


pasteWorkingList

String pasteWorkingList()
Called when the "paste all" button is clicked on the clipboard.


moveWorkingList

String moveWorkingList()
Called when the "move all" button is clicked on the clipboard/selection


pasteDocumentList

String pasteDocumentList(List<DocumentModel> docPaste)
                         throws ClientException
Called when the drag and drop is launched in the body fragment. Pastes the documents passed to the clipboard.

Parameters:
docPaste - the list of doc we want to paste
Throws:
ClientException

pasteDocumentListInside

String pasteDocumentListInside(List<DocumentModel> docPaste,
                               String docId)
                               throws ClientException
Throws:
ClientException

pasteDocumentList

String pasteDocumentList(String listName)
                         throws ClientException
Pastes the content of the list listName into the current context document.

Throws:
ClientException

pasteDocumentListInside

String pasteDocumentListInside(String listName,
                               String docId)
                               throws ClientException
Throws:
ClientException

pasteClipboard

String pasteClipboard()

pasteClipboardInside

String pasteClipboardInside(String docId)
                            throws ClientException
Throws:
ClientException

moveClipboardInside

String moveClipboardInside(String docId)
                           throws ClientException
Throws:
ClientException

exportWorklistAsZip

String exportWorklistAsZip()
                           throws ClientException
Throws:
ClientException

exportAllBlobsFromWorkingListAsZip

String exportAllBlobsFromWorkingListAsZip()
                                          throws ClientException
Throws:
ClientException

exportMainBlobFromWorkingListAsZip

String exportMainBlobFromWorkingListAsZip()
                                          throws ClientException
Throws:
ClientException

exportWorklistAsZip

String exportWorklistAsZip(List<DocumentModel> documents)
                           throws ClientException
Throws:
ClientException

exportWorklistAsZip

String exportWorklistAsZip(List<DocumentModel> documents,
                           boolean exportAllBlobs)
                           throws ClientException
Throws:
ClientException

releaseClipboardableDocuments

void releaseClipboardableDocuments()

isInitialized

boolean isInitialized()

isWorkListEmpty

boolean isWorkListEmpty()
Checks if the currently selected WorkList is empty.


getCanPasteWorkList

boolean getCanPasteWorkList()
                            throws ClientException
Shortcut for getCanPaste on the currently selected workList.

Throws:
ClientException

getCanPasteFromClipboard

boolean getCanPasteFromClipboard()
                                 throws ClientException
Shortcut for getCanPaste on the clipboard.

Throws:
ClientException

getCanPasteFromClipboardInside

boolean getCanPasteFromClipboardInside(DocumentModel document)
                                       throws ClientException
Throws:
ClientException

getCanMoveFromClipboardInside

boolean getCanMoveFromClipboardInside(DocumentModel document)
                                      throws ClientException
Checks if the documents from the clipboard can be moved into the given document

Throws:
ClientException

getCanPaste

boolean getCanPaste(String listName)
                    throws ClientException
Checks if the content of a given workList can be pasted.

- checks if the list is empty
- checks if the user has the needed rights in the current context

Throws:
ClientException

getCanPasteInside

boolean getCanPasteInside(String listName,
                          DocumentModel document)
                          throws ClientException
Throws:
ClientException

getCanCopy

boolean getCanCopy()
Checks if there are selected items that can be copied into the current worklist.


getCanMoveWorkingList

boolean getCanMoveWorkingList()
                              throws ClientException
Checks if there are documents in current worklist can be moved into the current folder.

Throws:
ClientException

getCanMoveInside

boolean getCanMoveInside(String listName,
                         DocumentModel document)
                         throws ClientException
Checks if the documents in a given worklist can be moved into the given document

Throws:
ClientException

putSelectionInWorkList

void putSelectionInWorkList(List<DocumentModel> docsList)
Copies docsList into the current WorkList.


putSelectionInWorkList

void putSelectionInWorkList(List<DocumentModel> docsList,
                            Boolean forceAppend)

putSelectionInWorkList

void putSelectionInWorkList()
Copies the lists of selected documents into the current WorkList.


putSelectionInWorkList

void putSelectionInWorkList(Boolean forceAppend)

putSelectionInClipboard

void putSelectionInClipboard()

putSelectionInDefaultWorkList

void putSelectionInDefaultWorkList()

putInClipboard

void putInClipboard(String docId)
                    throws ClientException
Throws:
ClientException

getCurrentSelectedList

List<DocumentModel> getCurrentSelectedList()
Retries contents of current WorkList.


getCurrentSelectedListName

String getCurrentSelectedListName()
Returns the name of the current selected WorkList.


getCurrentSelectedListTitle

String getCurrentSelectedListTitle()

setCurrentSelectedList

void setCurrentSelectedList(String listId)
Sets the current selected WorkList.


getAvailableLists

List<String> getAvailableLists()
Returns the list of available lists (ie: the lists from the CLIPBOARD Category).


getDescriptorsForAvailableLists

List<DocumentsListDescriptor> getDescriptorsForAvailableLists()
Returns the list of Descriptors for available lists.


getActionsForCurrentList

List<Action> getActionsForCurrentList()
Returns the list of available web actions for the currently selected DocumentList.

Returns:
the WebAction list

getActionsForSelection

List<Action> getActionsForSelection()
Returns the list of available web actions for the currently selected Documents.

Returns:
the WebAction list

selectList

void selectList()

getCanEditSelectedDocs

boolean getCanEditSelectedDocs()
                               throws ClientException
Checks for documents bulk editing action.

Returns:
true if the current selected docs (from clipboard) are editable by the current user
Throws:
ClientException

getCanEditListDocs

boolean getCanEditListDocs(String listName)
                           throws ClientException
Checks if documents in the specified list are editable so the bulk editing action can be invoked later.

Returns:
true if the docs from the specified working list are editable by the current user
Throws:
ClientException

factoryForIsCurrentWorkListEmpty

boolean factoryForIsCurrentWorkListEmpty()

isCacheEnabled

boolean isCacheEnabled()

getCacheKey

String getCacheKey()

isCacheEnabledForSelection

boolean isCacheEnabledForSelection()

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.