KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > de > webman > wminstaller > install > InstallationException


1 package de.webman.wminstaller.install;
2
3
4
5 public class InstallationException
6     extends Exception JavaDoc
7 {
8     public static final int OK = 0;
9     public static final int WARNING = 1;
10     public static final int FAILED = 2;
11     public static final int FATAL = 3;
12
13     int severity = OK;
14     String JavaDoc msg = "";
15
16     public InstallationException(int _severity, String JavaDoc _msg) {
17         msg = _msg;
18         severity = _severity;
19     }
20
21     public String JavaDoc getMessage() {
22         return msg;
23     }
24
25     public int getSeverity() {
26         return severity;
27     }
28     
29     public String JavaDoc toString() {
30         return getClass().getName() + ": " + msg + " (" + severity + ")";
31     }
32 }
33
Popular Tags