Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.webapp.bulkedit
Class BulkEditHelper

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

public class BulkEditHelper
extends java.lang.Object

Helper used for bulk edit actions

Author:
Thomas Roger

Field Summary
static java.lang.String BULK_EDIT_PREFIX
           
 
Method Summary
static void copyMetadata(CoreSession session, DocumentModel sourceDoc, java.util.List<DocumentModel> targetDocs)
          Copy all the marked properties (stored in the ContextData of sourceDoc) from sourceDoc to all the targetDocs.
static java.util.List<java.lang.String> getCommonLayouts(TypeManager typeManager, java.util.List<DocumentModel> docs)
          Returns the common layouts of the docs for the edit mode.
static java.util.List<java.lang.String> getCommonLayouts(TypeManager typeManager, java.util.List<DocumentModel> docs, java.lang.String mode)
          Returns the common layouts of the docs for the given layout mode.
static java.util.List<java.lang.String> getCommonSchemas(java.util.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 java.lang.String BULK_EDIT_PREFIX
See Also:
Constant Field Values
Method Detail

getCommonLayouts

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


getCommonLayouts

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


getCommonSchemas

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


copyMetadata

public static void copyMetadata(CoreSession session,
                                DocumentModel sourceDoc,
                                java.util.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 Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.