KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > management > BadBinaryOpValueExpException


1 /*
2  * @(#)BadBinaryOpValueExpException.java 4.18 03/12/19
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7
8 package javax.management;
9
10
11 /**
12  * Thrown when an invalid expression is passed to a method for
13  * constructing a query. This exception is used internally by JMX
14  * during the evaluation of a query. User code does not usually see
15  * it.
16  *
17  * @since 1.5
18  */

19 public class BadBinaryOpValueExpException extends Exception JavaDoc {
20
21     
22     /* Serial version */
23     private static final long serialVersionUID = 5068475589449021227L;
24
25     /**
26      * @serial the {@link ValueExp} that originated this exception
27      */

28     private ValueExp JavaDoc exp;
29
30
31     /**
32      * Constructs a <CODE>BadBinaryOpValueExpException</CODE> with the specified <CODE>ValueExp</CODE>.
33      *
34      * @param exp the expression whose value was inappropriate.
35      */

36     public BadBinaryOpValueExpException(ValueExp JavaDoc exp) {
37     this.exp = exp;
38     }
39     
40
41     /**
42      * Returns the <CODE>ValueExp</CODE> that originated the exception.
43      *
44      * @return the problematic {@link ValueExp}.
45      */

46     public ValueExp JavaDoc getExp() {
47     return exp;
48     }
49
50     /**
51      * Returns the string representing the object.
52      */

53     public String JavaDoc toString() {
54     return "BadBinaryOpValueExpException: " + exp;
55     }
56
57  }
58
Popular Tags