KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > enhydra > shark > api > client > wfbase > BaseException


1 package org.enhydra.shark.api.client.wfbase;
2
3
4 import org.enhydra.shark.api.*;
5
6
7
8
9 /**
10  * Java implementation of OMG defined exception. This is how OMG defines it:
11  * <p>
12  * BaseException is an exception that holds a sequence of BaseError structures -
13  * essentially a sequence of exceptions. The sequence is a push-down list so that the most
14  * recently occurring exception is first. This allows multiple exceptions to be returned so
15  * that multiple problems may be addressed, as where a user has a number of data entry
16  * errors or where consequential errors are recorded as a result of a low-level exception.
17  * The BaseException is returned by all operations defined in this specification to
18  * support implementations of the WfM Facility to raise implementation specific
19  * exceptions.
20  * <p>
21  * Our implementation is adapted for Java. Although we implemented possibility
22  * to be used as defined, we extended this exception from our RootException class,
23  * which allows us chaining exceptions, and in shark we use it only that way.
24  */

25 public final class BaseException extends RootException
26 {
27   public BaseError errors[] = null;
28
29   public BaseException ()
30   {
31     super();
32   } // ctor
33

34   public BaseException (BaseError[] _errors)
35   {
36     super();
37     errors = _errors;
38   } // ctor
39

40
41   public BaseException (String JavaDoc $reason, BaseError[] _errors)
42   {
43     super($reason);
44     errors = _errors;
45   } // ctor
46
public BaseException(String JavaDoc message) {
47      super(message);
48   }
49   public BaseException(Throwable JavaDoc cause) {
50      super(cause);
51   }
52   public BaseException(String JavaDoc message, Throwable JavaDoc cause) {
53      super(message, cause);
54   }
55 } // class BaseException
56
Popular Tags