001/*
002 * (C) Copyright 2009 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 *     arussel
018 */
019package org.nuxeo.ecm.platform.routing.api;
020
021import java.util.List;
022
023import org.nuxeo.ecm.core.api.CoreSession;
024
025/**
026 * A DocumentRoute model or instance. A route is a set of step that processes documents. If a method is called that
027 * change the state of this object, the {@link #save(CoreSession)} method should be called to persist its state.
028 *
029 * @author arussel
030 */
031public interface DocumentRoute extends DocumentRouteStepsContainer {
032
033    /**
034     * Set the list of id of documents attached to this instance of RouteModel replacing the previous list if any.
035     */
036    void setAttachedDocuments(List<String> documentIds);
037
038    /**
039     * The list of documents processed by this route.
040     */
041    List<String> getAttachedDocuments();
042
043
044    /**
045     * Get the username of the initiator.
046     *
047     * @since 7.2
048     */
049    String getInitiator();
050
051    /**
052     * @since 7.2
053     */
054    String getModelId();
055
056    /**
057     * @since 7.2
058     */
059    String getModelName();
060
061}