1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kew.framework.postprocessor;
17
18 import org.kuali.rice.kew.framework.postprocessor.IDocumentEvent;
19
20
21
22
23
24
25
26
27 public class DocumentRouteLevelChange implements IDocumentEvent {
28
29
30
31
32 private static final long serialVersionUID = 785552701611174468L;
33
34 private String documentId;
35 private String appDocId;
36 private Integer oldRouteLevel;
37 private Integer newRouteLevel;
38 private String oldNodeName;
39 private String newNodeName;
40 private String oldNodeInstanceId;
41 private String newNodeInstanceId;
42
43
44 public DocumentRouteLevelChange(String documentId, String appDocId, Integer oldRouteLevel, Integer newRouteLevel) {
45 this(documentId, appDocId, oldRouteLevel, newRouteLevel, null, null, null, null);
46 }
47
48 public DocumentRouteLevelChange(String documentId, String appDocId, Integer oldRouteLevel,
49 Integer newRouteLevel, String oldNodeName, String newNodeName, String oldNodeInstanceId, String newNodeInstanceId) {
50 this.documentId = documentId;
51 this.oldRouteLevel = oldRouteLevel;
52 this.newRouteLevel = newRouteLevel;
53 this.oldNodeName = oldNodeName;
54 this.newNodeName = newNodeName;
55 this.oldNodeInstanceId = oldNodeInstanceId;
56 this.newNodeInstanceId = newNodeInstanceId;
57 this.appDocId = appDocId;
58 }
59
60 public String getDocumentEventCode() {
61 return ROUTE_LEVEL_CHANGE;
62 }
63
64 public String getDocumentId() {
65 return documentId;
66 }
67
68 public Integer getOldRouteLevel() {
69 return oldRouteLevel;
70 }
71
72 public Integer getNewRouteLevel() {
73 return newRouteLevel;
74 }
75
76 public String getNewNodeInstanceId() {
77 return newNodeInstanceId;
78 }
79
80 public String getNewNodeName() {
81 return newNodeName;
82 }
83
84 public String getOldNodeInstanceId() {
85 return oldNodeInstanceId;
86 }
87
88 public String getOldNodeName() {
89 return oldNodeName;
90 }
91
92 public String toString() {
93 StringBuffer buffer = new StringBuffer();
94 buffer.append("DocumentId ").append(documentId);
95 buffer.append(" changing from routeLevel ").append(oldRouteLevel);
96 buffer.append(" to routeLevel ").append(newRouteLevel);
97
98 return buffer.toString();
99 }
100
101
102
103
104 public String getAppDocId() {
105 return appDocId;
106 }
107 }