jaroslav@68: /* jaroslav@68: * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. jaroslav@68: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. jaroslav@68: * jaroslav@68: * This code is free software; you can redistribute it and/or modify it jaroslav@68: * under the terms of the GNU General Public License version 2 only, as jaroslav@68: * published by the Free Software Foundation. Oracle designates this jaroslav@68: * particular file as subject to the "Classpath" exception as provided jaroslav@68: * by Oracle in the LICENSE file that accompanied this code. jaroslav@68: * jaroslav@68: * This code is distributed in the hope that it will be useful, but WITHOUT jaroslav@68: * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or jaroslav@68: * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License jaroslav@68: * version 2 for more details (a copy is included in the LICENSE file that jaroslav@68: * accompanied this code). jaroslav@68: * jaroslav@68: * You should have received a copy of the GNU General Public License version jaroslav@68: * 2 along with this work; if not, write to the Free Software Foundation, jaroslav@68: * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. jaroslav@68: * jaroslav@68: * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA jaroslav@68: * or visit www.oracle.com if you need additional information or have any jaroslav@68: * questions. jaroslav@68: */ jaroslav@68: jaroslav@68: package java.lang; jaroslav@68: jaroslav@68: /** jaroslav@68: * Common superclass of exceptions thrown by reflective operations in jaroslav@68: * core reflection. jaroslav@68: * jaroslav@68: * @see LinkageError jaroslav@68: * @since 1.7 jaroslav@68: */ jaroslav@68: public class ReflectiveOperationException extends Exception { jaroslav@68: static final long serialVersionUID = 123456789L; jaroslav@68: jaroslav@68: /** jaroslav@68: * Constructs a new exception with {@code null} as its detail jaroslav@68: * message. The cause is not initialized, and may subsequently be jaroslav@68: * initialized by a call to {@link #initCause}. jaroslav@68: */ jaroslav@68: public ReflectiveOperationException() { jaroslav@68: super(); jaroslav@68: } jaroslav@68: jaroslav@68: /** jaroslav@68: * Constructs a new exception with the specified detail message. jaroslav@68: * The cause is not initialized, and may subsequently be jaroslav@68: * initialized by a call to {@link #initCause}. jaroslav@68: * jaroslav@68: * @param message the detail message. The detail message is saved for jaroslav@68: * later retrieval by the {@link #getMessage()} method. jaroslav@68: */ jaroslav@68: public ReflectiveOperationException(String message) { jaroslav@68: super(message); jaroslav@68: } jaroslav@68: jaroslav@68: /** jaroslav@68: * Constructs a new exception with the specified detail message jaroslav@68: * and cause. jaroslav@68: * jaroslav@68: *

Note that the detail message associated with jaroslav@68: * {@code cause} is not automatically incorporated in jaroslav@68: * this exception's detail message. jaroslav@68: * jaroslav@68: * @param message the detail message (which is saved for later retrieval jaroslav@68: * by the {@link #getMessage()} method). jaroslav@68: * @param cause the cause (which is saved for later retrieval by the jaroslav@68: * {@link #getCause()} method). (A {@code null} value is jaroslav@68: * permitted, and indicates that the cause is nonexistent or jaroslav@68: * unknown.) jaroslav@68: */ jaroslav@68: public ReflectiveOperationException(String message, Throwable cause) { jaroslav@68: super(message, cause); jaroslav@68: } jaroslav@68: jaroslav@68: /** jaroslav@68: * Constructs a new exception with the specified cause and a detail jaroslav@68: * message of {@code (cause==null ? null : cause.toString())} (which jaroslav@68: * typically contains the class and detail message of {@code cause}). jaroslav@68: * jaroslav@68: * @param cause the cause (which is saved for later retrieval by the jaroslav@68: * {@link #getCause()} method). (A {@code null} value is jaroslav@68: * permitted, and indicates that the cause is nonexistent or jaroslav@68: * unknown.) jaroslav@68: */ jaroslav@68: public ReflectiveOperationException(Throwable cause) { jaroslav@68: super(cause); jaroslav@68: } jaroslav@68: }