01: package org.griphyn.cPlanner.transfer.sls;
02:
03: /*
04: * This file or a portion of this file is licensed under the terms of
05: * the Globus Toolkit Public License, found in file GTPL, or at
06: * http://www.globus.org/toolkit/download/license.html. This notice must
07: * appear in redistributions of this file, with or without modification.
08: *
09: * Redistributions of this Software, with or without modification, must
10: * reproduce the GTPL in: (1) the Software, or (2) the Documentation or
11: * some other similar material which is provided with the Software (if
12: * any).
13: *
14: * Copyright 1999-2004 University of Chicago and The University of
15: * Southern California. All rights reserved.
16: */
17:
18: import org.griphyn.common.util.FactoryException;
19:
20: /**
21: * Class to notify of failures while instantiating SLS implementations.
22: *
23: * @author Karan Vahi
24: * @version $Revision: 414 $
25: */
26:
27: public class SLSFactoryException extends FactoryException {
28:
29: /**
30: * The default classname that is associated with the exception.
31: */
32: public static final String DEFAULT_NAME = "Second Level Staging Implementor";
33:
34: /**
35: * Constructs a <code>SLSFactoryException</code> with no detail
36: * message. The associated classname is set to value specified by
37: * <code>DEFAULT_NAME</code>.
38: *
39: * @param msg the detailed message.
40: *
41: * @see #DEFAULT_NAME
42: */
43: public SLSFactoryException(String msg) {
44: super (msg);
45: mClassname = this .DEFAULT_NAME;
46: }
47:
48: /**
49: * Constructs a <code>SLSFactoryException</code> with the specified detailed
50: * message.
51: *
52: * @param msg is the detailed message.
53: * @param classname the name of class that was trying to be instantiated or
54: * some other signifier like module name.
55: */
56: public SLSFactoryException(String msg, String classname) {
57: super (msg, classname);
58: }
59:
60: /**
61: * Constructs a <code>SLSFactoryException</code> with the
62: * specified detailed message and a cause. The associated classname is set
63: * to value specified by <code>DEFAULT_NAME</code>.
64: *
65: * @param msg is the detailed message that is to be logged.
66: * @param cause is the cause (which is saved for later retrieval by the
67: * {@link java.lang.Throwable#getCause()} method). A <code>null</code>
68: * value is permitted, and indicates that the cause is nonexistent or
69: * unknown.
70: *
71: * @see #DEFAULT_NAME
72: */
73: public SLSFactoryException(String msg, Throwable cause) {
74: super (msg, cause);
75: mClassname = this .DEFAULT_NAME;
76: }
77:
78: /**
79: * Constructs a <code>SLSFactoryException</code> with the
80: * specified detailed message and a cause.
81: *
82: * @param msg is the detailed message that is to be logged.
83: * @param classname the name of class that was trying to be instantiated.
84: * @param cause is the cause (which is saved for later retrieval by the
85: * {@link java.lang.Throwable#getCause()} method). A <code>null</code>
86: * value is permitted, and indicates that the cause is nonexistent or
87: * unknown.
88: */
89: public SLSFactoryException(String msg, String classname,
90: Throwable cause) {
91: super(msg, cause);
92: mClassname = classname;
93: }
94:
95: }
|