001/* 002 * (C) Copyright 2009 Nuxeo SA (http://nuxeo.com/) and contributors. 003 * 004 * All rights reserved. This program and the accompanying materials 005 * are made available under the terms of the GNU Lesser General Public License 006 * (LGPL) version 2.1 which accompanies this distribution, and is available at 007 * http://www.gnu.org/licenses/lgpl.html 008 * 009 * This library is distributed in the hope that it will be useful, 010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 012 * Lesser General Public License for more details. 013 * 014 * Contributors: 015 * arussel 016 */ 017package org.nuxeo.ecm.platform.routing.api; 018 019/** 020 * @author arussel 021 */ 022public interface DocumentRoutingConstants { 023 024 // web 025 String SEARCH_ROUTE_BY_ATTACHED_DOC_QUERY = "SEARCH_ROUTE_BY_ATTACHED_DOC"; 026 027 /** 028 * @since 5.6 029 */ 030 String DOC_ROUTING_SEARCH_ALL_ROUTE_MODELS_PROVIDER_NAME = "DOC_ROUTING_SEARCH_ALL_ROUTE_MODELS"; 031 032 /** 033 * @since 7.4 034 */ 035 String DOC_ROUTING_SEARCH_ROUTE_MODELS_WITH_TITLE_PROVIDER_NAME = "DOC_ROUTING_SEARCH_ROUTE_MODELS_WITH_TITLE"; 036 037 String ROUTE_MANAGERS_GROUP_NAME = "routeManagers"; 038 039 // document constant 040 String DOCUMENT_ROUTE_INSTANCES_ROOT_DOCUMENT_TYPE = "DocumentRouteInstancesRoot"; 041 042 String DOCUMENT_ROUTE_MODELS_ROOT_DOCUMENT_TYPE = "DocumentRouteModelsRoot"; 043 044 String DOCUMENT_ROUTE_INSTANCES_ROOT_ID = "document-route-instances-root"; 045 046 String DOCUMENT_ROUTE_MODELS_ROOT_ID = "document-route-models-root"; 047 048 String DOCUMENT_ROUTE_DOCUMENT_TYPE = "DocumentRoute"; 049 050 String DOCUMENT_ROUTE_DOCUMENT_FACET = "DocumentRoute"; 051 052 String COMMENTS_INFO_HOLDER_FACET = "CommentsInfoHolder"; 053 054 String STEP_DOCUMENT_TYPE = "DocumentRouteStep"; 055 056 String STEP_FOLDER_DOCUMENT_TYPE = "StepFolder"; 057 058 String STEP_FOLDER_FACET = "StepFolder"; 059 060 // @deprecated since 5.9.2 - Use only routes of type 'graph' 061 @Deprecated 062 String CONDITIONAL_STEP_FACET = "ConditionalStepFolder"; 063 064 // @deprecated since 5.9.2 - Use only routes of type 'graph' 065 @Deprecated 066 String CONDITIONAL_STEP_DOCUMENT_TYPE = "ConditionalStepFolder"; 067 068 String TITLE_PROPERTY_NAME = "dc:title"; 069 070 String DESCRIPTION_PROPERTY_NAME = "dc:description"; 071 072 String EXECUTION_TYPE_PROPERTY_NAME = "stepf:execution"; 073 074 String INITIATOR = "docri:initiator"; 075 076 String ATTACHED_DOCUMENTS_PROPERTY_NAME = "docri:participatingDocuments"; 077 078 String COMMENTS_NO_PROPERTY_NAME = "info_comments:numberOfComments"; 079 080 // @deprecated since 5.9.2 - Use only routes of type 'graph' 081 @Deprecated 082 String STEP_TO_BE_EXECUTED_NEXT_PROPERTY_NAME = "condstepf:posOfChildStepToRunNext"; 083 084 // operation constant 085 String OPERATION_CATEGORY_ROUTING_NAME = "Routing"; 086 087 String OPERATION_STEP_DOCUMENT_KEY = "document.routing.step"; 088 089 String ROUTE_STEP_FACET = "RouteStep"; 090 091 String DOCUMENT_ROUTING_ACL = "routing"; 092 093 String DOCUMENT_ROUTING_DELEGATION_ACL = "delegation"; 094 095 String WORKFLOW_FORCE_RESUME = "_FORCE_RESUME_"; 096 097 /* 098 * @since 5.9.3 If this flag is set to Boolean.TRUE in the map of variables to be set on node or workflow, these 099 * variables will be decoded to JSON format 100 */ 101 String _MAP_VAR_FORMAT_JSON = "_MAP_VAR_FORMAT_JSON"; 102 103 /** 104 * @since 5.6 105 */ 106 String TASK_ASSIGNED_NOTIFICATION_TEMPLATE = "taskNotificationTemplate"; 107 108 enum ExecutionTypeValues { 109 /** Serial running of children nodes. */ 110 serial, 111 /** Parallel running of children nodes. */ 112 parallel, 113 /** Running of the nodes decided by the graph state. */ 114 graph 115 } 116 117 // event 118 enum Events { 119 /** 120 * before the route is validated, each part of the route is in "Draft" state. The session used is unrestricted. 121 * The element key is the route. 122 */ 123 beforeRouteValidated, 124 /** 125 * after the route is validated, each part of the route is in "Validated" state. The session used is 126 * unrestricted. The element key is the route. 127 */ 128 afterRouteValidated, 129 /** 130 * before the route is ready, each part of the route is in "Validated" state.The session used is unrestricted. 131 * The element key is the route. 132 */ 133 beforeRouteReady, 134 /** 135 * after the route is ready, each part of the route is in "Ready" state.The session used is unrestricted. The 136 * element key is the route. 137 */ 138 afterRouteReady, 139 /** 140 * before the route starts. The RouteDocument is in "Running" state, other parts of the route is either in 141 * Ready, Running or Done state.The session used is unrestricted. The element key is the route. 142 */ 143 beforeRouteStart, 144 /** 145 * after the route is finished. The route and each part of the route is in Done state.The session used is 146 * unrestricted. The element key is the route. 147 */ 148 afterRouteFinish, 149 /** 150 * before the operation chain for this step is called. The step is in "Running" state.The session used is 151 * unrestricted. The element key is the step. 152 */ 153 beforeStepRunning, 154 /** 155 * After the operation chain of this step ran and if the step is not done, ie: if we are in a waiting state.The 156 * session used is unrestricted. The element key is the step. 157 */ 158 stepWaiting, 159 /** 160 * after the operation chain for this step is called.The step is in "Done" state.The session used is 161 * unrestricted. The element key is the step. 162 */ 163 afterStepRunning, 164 /** 165 * before a step is put back to ready state. 166 */ 167 beforeStepBackToReady, 168 /** 169 * after a step was put back to ready state. 170 */ 171 afterStepBackToReady, 172 /** 173 * before the undo operation is run on the step. 174 */ 175 beforeUndoingStep, 176 /** 177 * after the undo operation is run on the step. 178 */ 179 afterUndoingStep, 180 /** 181 * @since 2.7.2 182 */ 183 workflowCanceled, 184 /** 185 * @since 7.4 186 */ 187 afterWorkflowFinish, 188 /** 189 * @since 7.4 190 */ 191 afterWorkflowStarted, 192 /** 193 * @since 7.4 194 */ 195 beforeWorkflowCanceled, 196 /** 197 * @since 7.4 198 */ 199 afterWorkflowTaskEnded, 200 /** 201 * @since 7.4 202 */ 203 afterWorkflowTaskCreated, 204 /** 205 * @since 7.4 206 */ 207 afterWorkflowTaskReassigned, 208 /** 209 * @since 7.4 210 */ 211 afterWorkflowTaskDelegated 212 } 213 214 String DOCUMENT_ELEMENT_EVENT_CONTEXT_KEY = "documentElementEventContextKey"; 215 216 String WORKFLOW_TASK_COMPLETION_ACTION_KEY = "workflowTaskCompletionAction"; 217 218 String INITIATOR_EVENT_CONTEXT_KEY = "initiator"; 219 220 String ROUTING_CATEGORY = "Routing"; 221 222 String ROUTING_INITIATOR_ID_KEY = "initiator"; 223 224 public static final String TASK_ROUTE_INSTANCE_DOCUMENT_ID_KEY = "routeInstanceDocId"; 225 226 public static final String TASK_NODE_ID_KEY = "nodeId"; 227 228 public static final String TASK_BUTTONS_KEY = "taskButtons"; 229 230 public static final String ROUTING_TASK_FACET_NAME = "RoutingTask"; 231 232 /** 233 * @since 7.1 234 */ 235 public static final String ROUTING_TASK_DOC_TYPE = "RoutingTask"; 236 237 public static final String ROUTE_TASK_LOCAL_ACL = "routingTask"; 238 239 /** 240 * @since 7.2 241 */ 242 public static final String DOCUMENT_ROUTE_MODEL_LIFECYCLESTATE = "validated"; 243 244 /** 245 * @since 7.2 246 */ 247 public static final String DOCUMENT_ROUTE_INSTANCE_MODEL_ID = "docri:modelId"; 248 249 /** 250 * @since 7.2 251 */ 252 public static final String GLOBAL_VAR_SCHEMA_PREFIX = "var_global_"; 253 254 /** 255 * @since 7.4 256 */ 257 public static final String CAN_DATA_VISU = "DataVisualization"; 258}