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