001/* 002 * (C) Copyright 2006-2016 Nuxeo SA (http://nuxeo.com/) and others. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 * 016 * Contributors: 017 * Nuxeo - initial API and implementation 018 * 019 * $Id: CoreEventConstants.java 29901 2008-02-05 17:01:22Z ogrisel $ 020 */ 021 022package org.nuxeo.ecm.core.api.event; 023 024/** 025 * Core event constants. 026 * 027 * @author <a href="mailto:ja@nuxeo.com">Julien Anguenot</a> 028 */ 029public final class CoreEventConstants { 030 031 public static final String DOC_LIFE_CYCLE = "documentLifeCycle"; 032 033 /** 034 * BBB for NXP-666: change events to manage DocumentModel instances instead of Document instances. 035 * <p> 036 * Document is passed as an option in event in case old listeners need it and cannot handle the document model. 037 */ 038 // public static final String DOCUMENT = "document"; 039 040 /** 041 * Path the of the container of the empty document model that is being created. 042 */ 043 public static final String PARENT_PATH = "parentPath"; 044 045 /** 046 * @deprecated since 7.1, use {@link CoreEventConstants#DESTINATION_NAME} instead. 047 */ 048 @Deprecated 049 public static final String DOCUMENT_MODEL_ID = "documentModelId"; 050 051 public static final String REPOSITORY_NAME = "repositoryName"; 052 053 /** @deprecated since 11.1 */ 054 @Deprecated 055 public static final String SESSION_ID = "sessionId"; 056 057 public static final String OLD_ACP = "oldACP"; 058 059 public static final String NEW_ACP = "newACP"; 060 061 /** 062 * @since 7.4 063 */ 064 public static final String OLD_ACE = "oldACE"; 065 066 /** 067 * @since 7.4 068 */ 069 public static final String NEW_ACE = "newACE"; 070 071 /** 072 * @since 7.4 073 */ 074 public static final String CHANGED_ACL_NAME = "changedACLName"; 075 076 public static final String REORDERED_CHILD = "reorderedChild"; 077 078 public static final String REPLACED_PROXY_IDS = "replacedProxyRefs"; 079 080 /** 081 * @since 7.4 082 */ 083 public static final String DOCUMENT_REFS = "documentRefs"; 084 085 /** 086 * Passed with beforeDocumentModification and documentModified events to hold the state that is about to be / has 087 * been overwritten by the saveDocument. 088 */ 089 public static final String PREVIOUS_DOCUMENT_MODEL = "previousDocumentModel"; 090 091 /** 092 * Passed with aboutToCopy, aboutToMove, documentCreatedbyCopy and documentMoved events to be able to change the 093 * destination name 094 * 095 * @since 5.7 096 */ 097 public static final String DESTINATION_NAME = "destinationName"; 098 099 public static final String DESTINATION_REF = "destinationRef"; 100 101 public static final String DESTINATION_PATH = "destinationPath"; 102 103 public static final String DESTINATION_EXISTS = "destinationExists"; 104 105 public static final String DOCUMENT_DIRTY = "documentIsDirty"; 106 107 public static final String SOURCE_REF = "sourceRef"; 108 109 /** 110 * Passed with documentMoved event, if the name has changed, to know the original name of the document. 111 * 112 * @since 7.3 113 */ 114 public static final String ORIGINAL_NAME = "originalName"; 115 116 /** 117 * Passed with documentCreatedbyCopy event to be able to reset the life cycle or not 118 * 119 * @since 5.7 120 */ 121 public static final String RESET_LIFECYCLE = "resetLifeCycle"; 122 123 /** 124 * Passed with documentCreatedByCopy event to be able to reset creator, creation date and last modification date or 125 * not 126 * 127 * @since 8.2 128 */ 129 public static final String RESET_CREATOR = "resetCreator"; 130 131 /** 132 * Passed with {@value DocumentEventTypes#BEFORE_SET_RETENTION},{@value DocumentEventTypes#BEFORE_EXTEND_RETENTION}, 133 * {@value DocumentEventTypes#AFTER_SET_RETENTION} and {@value DocumentEventTypes#AFTER_EXTEND_RETENTION} events, 134 * the retention datetime (a {@link java.util.Calendar} object). 135 * 136 * @since 11.1 137 */ 138 public static final String RETAIN_UNTIL = "retainUntil"; 139 140 /** 141 * Passed with retentionActiveChanged event, status of the retention (active or not, a Boolean). 142 * 143 * @since 9.3 144 * @deprecated since 11.1 145 */ 146 @Deprecated 147 public static final String RETENTION_ACTIVE = "retentionActive"; 148 149 // Constant utility class 150 private CoreEventConstants() { 151 } 152 153}