1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kns.rule.event;
17
18 import org.apache.log4j.Logger;
19 import org.kuali.rice.kns.rule.PromptBeforeValidation;
20 import org.kuali.rice.krad.document.Document;
21 import org.kuali.rice.krad.rules.rule.BusinessRule;
22 import org.kuali.rice.krad.rules.rule.event.KualiDocumentEventBase;
23
24
25
26
27
28
29 public class PromptBeforeValidationEvent extends KualiDocumentEventBase {
30 private static final Logger LOG = Logger.getLogger(PromptBeforeValidationEvent.class);
31
32 boolean performQuestion;
33 String actionForwardName;
34 String questionId;
35 String questionText;
36 String questionType;
37 String questionCaller;
38 String questionContext;
39
40
41
42
43
44
45
46 public PromptBeforeValidationEvent(String description, String errorPathPrefix, Document document) {
47
48 super(description, errorPathPrefix);
49 this.document = document;
50
51 LOG.debug(description);
52
53 performQuestion = false;
54 }
55
56
57
58
59
60 public String getActionForwardName() {
61 return actionForwardName;
62 }
63
64
65
66
67 public void setActionForwardName(String actionForwardName) {
68 this.actionForwardName = actionForwardName;
69 }
70
71
72
73
74 public boolean isPerformQuestion() {
75 return performQuestion;
76 }
77
78
79
80
81 public void setPerformQuestion(boolean performQuestion) {
82 this.performQuestion = performQuestion;
83 }
84
85
86
87
88 public String getQuestionCaller() {
89 return questionCaller;
90 }
91
92
93
94
95 public void setQuestionCaller(String questionCaller) {
96 this.questionCaller = questionCaller;
97 }
98
99
100
101
102 public String getQuestionContext() {
103 return questionContext;
104 }
105
106
107
108
109 public void setQuestionContext(String questionContext) {
110 this.questionContext = questionContext;
111 }
112
113
114
115
116 public String getQuestionId() {
117 return questionId;
118 }
119
120
121
122
123 public void setQuestionId(String questionId) {
124 this.questionId = questionId;
125 }
126
127
128
129
130 public String getQuestionText() {
131 return questionText;
132 }
133
134
135
136
137 public void setQuestionText(String questionText) {
138 this.questionText = questionText;
139 }
140
141
142
143
144 public String getQuestionType() {
145 return questionType;
146 }
147
148
149
150
151 public void setQuestionType(String questionType) {
152 this.questionType = questionType;
153 }
154
155
156
157
158 public Class<? extends BusinessRule> getRuleInterfaceClass() {
159 return PromptBeforeValidation.class;
160 }
161
162
163
164
165
166 public boolean invokeRuleMethod(BusinessRule rule) {
167 return true;
168 }
169 }