Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
DocumentRouteStatusChange |
|
| 1.0;1 |
1 | /** | |
2 | * Copyright 2005-2011 The Kuali Foundation | |
3 | * | |
4 | * Licensed under the Educational Community License, Version 2.0 (the "License"); | |
5 | * you may not use this file except in compliance with the License. | |
6 | * You may obtain a copy of the License at | |
7 | * | |
8 | * http://www.opensource.org/licenses/ecl2.php | |
9 | * | |
10 | * Unless required by applicable law or agreed to in writing, software | |
11 | * distributed under the License is distributed on an "AS IS" BASIS, | |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
13 | * See the License for the specific language governing permissions and | |
14 | * limitations under the License. | |
15 | */ | |
16 | package org.kuali.rice.kew.framework.postprocessor; | |
17 | ||
18 | import org.kuali.rice.kew.framework.postprocessor.IDocumentEvent; | |
19 | ||
20 | /** | |
21 | * <p> | |
22 | * <Title> | |
23 | * </p> | |
24 | * <p> | |
25 | * <Description> | |
26 | * </p> | |
27 | * <p> | |
28 | * <p> | |
29 | * <p> | |
30 | * Copyright: Copyright (c) 2002 | |
31 | * </p> | |
32 | * <p> | |
33 | * <p> | |
34 | * Company: UIS - Indiana University | |
35 | * </p> | |
36 | * | |
37 | * @author Kuali Rice Team (rice.collab@kuali.org) | |
38 | */ | |
39 | public class DocumentRouteStatusChange implements IDocumentEvent { | |
40 | ||
41 | private static final long serialVersionUID = -5170568498563302803L; | |
42 | private String appDocId; | |
43 | private String documentId; | |
44 | private String newRouteStatus; | |
45 | private String oldRouteStatus; | |
46 | ||
47 | 0 | public DocumentRouteStatusChange(String documentId, String appDocId, String oldStatus, String newStatus) { |
48 | 0 | this.documentId = documentId; |
49 | 0 | this.appDocId = appDocId; |
50 | 0 | this.newRouteStatus = newStatus; |
51 | 0 | this.oldRouteStatus = oldStatus; |
52 | 0 | } |
53 | ||
54 | public String getDocumentEventCode() { | |
55 | 0 | return ROUTE_STATUS_CHANGE; |
56 | } | |
57 | ||
58 | public String getDocumentId() { | |
59 | 0 | return documentId; |
60 | } | |
61 | ||
62 | public String getNewRouteStatus() { | |
63 | 0 | return newRouteStatus; |
64 | } | |
65 | ||
66 | public String getOldRouteStatus() { | |
67 | 0 | return oldRouteStatus; |
68 | } | |
69 | ||
70 | public String toString() { | |
71 | 0 | StringBuffer buffer = new StringBuffer(); |
72 | 0 | buffer.append("DocumentId ").append(documentId); |
73 | 0 | buffer.append(" changing from routeStatus ").append(oldRouteStatus); |
74 | 0 | buffer.append(" to routeStatus ").append(newRouteStatus); |
75 | ||
76 | 0 | return buffer.toString(); |
77 | } | |
78 | ||
79 | /* | |
80 | * (non-Javadoc) | |
81 | * | |
82 | * @see org.kuali.rice.kew.IDocumentEvent#getAppDocId() | |
83 | */ | |
84 | public String getAppDocId() { | |
85 | 0 | return this.appDocId; |
86 | } | |
87 | } |