Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.webapp.bulkedit
Class BulkEditHelper

java.lang.Object
  extended by org.nuxeo.ecm.webapp.bulkedit.BulkEditHelper

public class BulkEditHelper
extends Object

Helper used for bulk edit actions

Author:
Thomas Roger

Field Summary
static String BULK_EDIT_PREFIX
           
 
Method Summary
static void copyMetadata(CoreSession session, DocumentModel sourceDoc, List<DocumentModel> targetDocs)
          Copy all the marked properties (stored in the ContextData of sourceDoc) from sourceDoc to all the targetDocs.
static List<String> getCommonLayouts(TypeManager typeManager, List<DocumentModel> docs)
          Returns the common layouts of the docs for the edit mode.
static List<String> getCommonLayouts(TypeManager typeManager, List<DocumentModel> docs, String mode)
          Returns the common layouts of the docs for the given layout mode.
static List<String> getCommonSchemas(List<DocumentModel> docs)
          Returns the common schemas of the docs.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BULK_EDIT_PREFIX

public static final String BULK_EDIT_PREFIX
See Also:
Constant Field Values
Method Detail

getCommonLayouts

public static List<String> getCommonLayouts(TypeManager typeManager,
                                            List<DocumentModel> docs)
Returns the common layouts of the docs for the edit mode.


getCommonLayouts

public static List<String> getCommonLayouts(TypeManager typeManager,
                                            List<DocumentModel> docs,
                                            String mode)
Returns the common layouts of the docs for the given layout mode.


getCommonSchemas

public static List<String> getCommonSchemas(List<DocumentModel> docs)
Returns the common schemas of the docs.


copyMetadata

public static void copyMetadata(CoreSession session,
                                DocumentModel sourceDoc,
                                List<DocumentModel> targetDocs)
                         throws ClientException
Copy all the marked properties (stored in the ContextData of sourceDoc) from sourceDoc to all the targetDocs.

Parameters:
session - the CoreSession to use
sourceDoc - the doc where to get the metadata to copy
targetDocs - the docs where to set the metadatas
Throws:
ClientException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.