BAD_OPERATION.java revision 862:bd32b2b28de5
1138568Ssam/*
2178354Ssam * Copyright (c) 1995, 2017, Oracle and/or its affiliates. All rights reserved.
3138568Ssam * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4138568Ssam *
5138568Ssam * This code is free software; you can redistribute it and/or modify it
6138568Ssam * under the terms of the GNU General Public License version 2 only, as
7138568Ssam * published by the Free Software Foundation.  Oracle designates this
8138568Ssam * particular file as subject to the "Classpath" exception as provided
9138568Ssam * by Oracle in the LICENSE file that accompanied this code.
10138568Ssam *
11138568Ssam * This code is distributed in the hope that it will be useful, but WITHOUT
12138568Ssam * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13138568Ssam * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
14138568Ssam * version 2 for more details (a copy is included in the LICENSE file that
15138568Ssam * accompanied this code).
16138568Ssam *
17138568Ssam * You should have received a copy of the GNU General Public License version
18138568Ssam * 2 along with this work; if not, write to the Free Software Foundation,
19138568Ssam * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20138568Ssam *
21138568Ssam * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22138568Ssam * or visit www.oracle.com if you need additional information or have any
23138568Ssam * questions.
24138568Ssam */
25138568Ssam
26138568Ssampackage org.omg.CORBA;
27138568Ssam
28138568Ssam/**
29138568Ssam * Exception thrown when an object reference denotes an existing object,
30138568Ssam * but that the object does not support the operation that was invoked.<P>
31138568Ssam * It contains a minor code, which gives more detailed information about
32138568Ssam * what caused the exception, and a completion status. It may also contain
33138568Ssam * a string describing the exception.
34138568Ssam *
35138568Ssam * <p>See also {@extLink jidlexception documentation on Java&nbsp;IDL exceptions}.
36178354Ssam * </p>
37178354Ssam * @since       JDK1.2
38138568Ssam */
39138568Ssam
40138568Ssampublic final class BAD_OPERATION extends SystemException {
41138568Ssam
42138568Ssam    /**
43138568Ssam     * Constructs a <code>BAD_OPERATION</code> exception with a default
44138568Ssam     * minor code of 0 and a completion state of COMPLETED_NO.
45138568Ssam     */
46138568Ssam    public BAD_OPERATION() {
47138568Ssam        this("");
48138568Ssam    }
49138568Ssam
50138568Ssam    /**
51138568Ssam     * Constructs a <code>BAD_OPERATION</code> exception with the specified detail
52138568Ssam     * message, a minor code of 0, and a completion state of COMPLETED_NO.
53138568Ssam     * @param s the String containing a detail message
54138568Ssam     */
55138568Ssam    public BAD_OPERATION(String s) {
56138568Ssam        this(s, 0, CompletionStatus.COMPLETED_NO);
57138568Ssam    }
58178354Ssam
59178354Ssam    /**
60138568Ssam     * Constructs a <code>BAD_OPERATION</code> exception with the specified
61138568Ssam     * minor code and completion status.
62138568Ssam     * @param minor the minor code
63178354Ssam     * @param completed an instance of <code>CompletionStatus</code> indicating
64138568Ssam     *                  the completion status
65138568Ssam     */
66170530Ssam    public BAD_OPERATION(int minor, CompletionStatus completed) {
67147252Ssam        this("", minor, completed);
68147045Ssam    }
69147045Ssam
70138568Ssam    /**
71138568Ssam     * Constructs a <code>BAD_OPERATION</code> exception with the specified detail
72138568Ssam     * message, minor code, and completion status.
73138568Ssam     * A detail message is a String that describes this particular exception.
74138568Ssam     * @param s the String containing a detail message
75138568Ssam     * @param minor the minor code
76138568Ssam     * @param completed an instance of <code>CompletionStatus</code> indicating
77138568Ssam     *                  the completion status
78138568Ssam     */
79138568Ssam    public BAD_OPERATION(String s, int minor, CompletionStatus completed) {
80138568Ssam        super(s, minor, completed);
81138568Ssam    }
82138568Ssam}
83138568Ssam