KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > net > sf > uitags > tagutil > validation > RuntimeValidationException


1 /**
2  * Nov 28, 2004
3  *
4  * Copyright 2004 uitags
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */

18 package net.sf.uitags.tagutil.validation;
19
20
21 /**
22  * Thrown to indicate an invalid usage of tag that can only be detected
23  * during runtime.
24  *
25  * @see net.sf.uitags.tagutil.validation.TlvLeakageException
26  * @author hgani
27  * @version $Id$
28  */

29 public class RuntimeValidationException extends RuntimeException JavaDoc {
30
31   /**
32    * Serial Version UID.
33    */

34   private static final long serialVersionUID = 52L;
35
36   /**
37    * See {@link RuntimeException#RuntimeException()}.
38    */

39   public RuntimeValidationException() {
40     super();
41   }
42
43   /**
44    * See {@link RuntimeException#RuntimeException(java.lang.String)}.
45    *
46    * @param message the detail message
47    */

48   public RuntimeValidationException(String JavaDoc message) {
49     super(message);
50   }
51
52   /**
53    * Contructs the exception object specifying the name of the tag that
54    * has been misused.
55    *
56    * See {@link RuntimeException#RuntimeException(java.lang.String)}.
57    * @param message the detail message
58    * @param tagName the tag name
59    */

60   public RuntimeValidationException(String JavaDoc message, String JavaDoc tagName) {
61     super(tagName + ": " + message);
62   }
63
64   /**
65    * See
66    * {@link RuntimeException#RuntimeException(java.lang.String, java.lang.Throwable)}.
67    *
68    * @param message the detail message
69    * @param cause the cause
70    */

71   public RuntimeValidationException(String JavaDoc message, Throwable JavaDoc cause) {
72     super(message, cause);
73   }
74
75   /**
76    * See
77    * {@link RuntimeException#RuntimeException(java.lang.Throwable)}.
78    *
79    * @param cause the cause
80    */

81   public RuntimeValidationException(Throwable JavaDoc cause) {
82     super(cause);
83   }
84 }
85
Popular Tags