001    /*
002     * Copyright 2011 The Kuali Foundation.
003     * 
004     * Licensed under the Educational Community 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.opensource.org/licenses/ecl2.php
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    package org.kuali.kfs.module.purap.document.service;
017    
018    import org.kuali.kfs.module.purap.PurapWorkflowConstants.NodeDetails;
019    import org.kuali.kfs.module.purap.document.PurchasingAccountsPayableDocument;
020    
021    import org.kuali.rice.kew.routeheader.DocumentRouteHeaderValue;
022    import org.kuali.rice.kim.bo.Person;
023    import org.kuali.rice.kns.document.Document;
024    
025    public interface PurApWorkflowIntegrationService {
026    
027        /**
028         * Take all actions on the given document based on the given criteria
029         * 
030         * @param document
031         * @param potentialAnnotation
032         * @param nodeName
033         * @param user
034         * @param networkIdToImpersonate
035         * @return
036         */
037        public boolean takeAllActionsForGivenCriteria(Document document, String potentialAnnotation, String nodeName, Person user, String superUserNetworkId);
038    
039        /**
040         * Determine if the document will stop at the given node in the future routing process
041         * 
042         * @param document
043         * @param givenNodeDetail
044         * @return boolean indicating if document is going to stop at the given node
045         */
046        public boolean willDocumentStopAtGivenFutureRouteNode(PurchasingAccountsPayableDocument document, NodeDetails givenNodeDetail);
047    }
048