01: /*
02: * @(#)IllegalStateException.java 1.7 02/04/09
03: *
04: * Copyright 1997-2002 Sun Microsystems, Inc. All Rights Reserved.
05: *
06: * SUN PROPRIETARY/CONFIDENTIAL.
07: * This software is the proprietary information of Sun Microsystems, Inc.
08: * Use is subject to license terms.
09: *
10: */
11:
12: package javax.jms;
13:
14: /**
15: * <P> This exception is thrown when a method is
16: * invoked at an illegal or inappropriate time or if the provider is
17: * not in an appropriate state for the requested operation. For example,
18: * this exception must be thrown if <CODE>Session.commit</CODE> is
19: * called on a non-transacted session. This exception is also called when
20: * a domain inappropriate method is called, such as calling
21: * <CODE>TopicSession.CreateQueueBrowser</CODE>.
22: *
23: * @version April 9, 2002
24: * @author Rahul Sharma
25: * @author Kate Stout
26: **/
27:
28: public class IllegalStateException extends JMSException {
29:
30: /** Constructs an <CODE>IllegalStateException</CODE> with the specified reason
31: * and error code.
32: *
33: * @param reason a description of the exception
34: * @param errorCode a string specifying the vendor-specific
35: * error code
36: *
37: **/
38: public IllegalStateException(String reason, String errorCode) {
39: super (reason, errorCode);
40: }
41:
42: /** Constructs an <CODE>IllegalStateException</CODE> with the specified
43: * reason. The error code defaults to null.
44: *
45: * @param reason a description of the exception
46: **/
47: public IllegalStateException(String reason) {
48: super(reason);
49: }
50:
51: }
|