View Javadoc

1   /*
2    * Copyright 2006-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.ole.module.cg.document.validation.impl;
17  
18  /**
19   * KRA Audit Error class.
20   */
21  public class AuditError {
22  
23      private String errorKey;
24      private String messageKey;
25      private String link;
26      private String[] params;
27  
28      public AuditError(String errorKey, String messageKey, String link) {
29          this.setErrorKey(errorKey);
30          this.setMessageKey(messageKey);
31          this.setLink(link);
32          this.params = new String[5]; // bean:message takes up to 5 tokenized parameters
33      }
34  
35      public AuditError(String errorKey, String messageKey, String link, String[] params) {
36          this(errorKey, messageKey, link);
37          this.setParams(params);
38      }
39  
40      /**
41       * Gets the errorKey attribute.
42       * 
43       * @return Returns the errorKey.
44       */
45      public String getErrorKey() {
46          return errorKey;
47      }
48  
49      /**
50       * Sets the errorKey attribute value.
51       * 
52       * @param errorKey The errorKey to set.
53       */
54      public void setErrorKey(String errorKey) {
55          this.errorKey = errorKey;
56      }
57  
58      /**
59       * Gets the link attribute.
60       * 
61       * @return Returns the link.
62       */
63      public String getLink() {
64          return link;
65      }
66  
67      /**
68       * Sets the link attribute value.
69       * 
70       * @param link The link to set.
71       */
72      public void setLink(String link) {
73          this.link = link;
74      }
75  
76      /**
77       * Gets the key attribute.
78       * 
79       * @return Returns the key.
80       */
81      public String getMessageKey() {
82          return messageKey;
83      }
84  
85      /**
86       * Sets the key attribute value.
87       * 
88       * @param key The key to set.
89       */
90      public void setMessageKey(String messageKey) {
91          this.messageKey = messageKey;
92      }
93  
94      /**
95       * Gets the params attribute.
96       * 
97       * @return Returns the params.
98       */
99      public String[] getParams() {
100         return params;
101     }
102 
103     /**
104      * Sets the params attribute value.
105      * 
106      * @param params The params to set.
107      */
108     public void setParams(String[] params) {
109         this.params = params;
110     }
111 }