2362N/A * Copyright (c) 1999, 2006, Oracle and/or its affiliates. All rights reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 2362N/A * published by the Free Software Foundation. Oracle designates this 0N/A * particular file as subject to the "Classpath" exception as provided 2362N/A * by Oracle in the LICENSE file that accompanied this code. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2362N/A * or visit www.oracle.com if you need additional information or have any 0N/A * <p>The <CODE>MBeanNotificationInfo</CODE> class is used to describe the 0N/A * characteristics of the different notification instances 0N/A * emitted by an MBean, for a given Java class of notification. 0N/A * If an MBean emits notifications that can be instances of different Java classes, 0N/A * then the metadata for that MBean should provide an <CODE>MBeanNotificationInfo</CODE> 0N/A * object for each of these notification Java classes.</p> 0N/A * <p>Instances of this class are immutable. Subclasses may be 0N/A * mutable but this is not recommended.</p> 0N/A * <p>This class extends <CODE>javax.management.MBeanFeatureInfo</CODE> 0N/A * and thus provides <CODE>name</CODE> and <CODE>description</CODE> fields. 0N/A * The <CODE>name</CODE> field should be the fully qualified Java class name of 0N/A * the notification objects described by this class.</p> 0N/A * <p>The <CODE>getNotifTypes</CODE> method returns an array of 0N/A * strings containing the notification types that the MBean may 0N/A * emit. The notification type is a dot-notation string which 0N/A * describes what the emitted notification is about, not the Java 0N/A * class of the notification. A single generic notification class can 0N/A * be used to send notifications of several types. All of these types 0N/A * are returned in the string array result of the 0N/A * <CODE>getNotifTypes</CODE> method. 0N/A /* Serial version */ 0N/A * @serial The different types of the notification. 0N/A /** @see MBeanInfo#arrayGettersSafe */ 0N/A * Constructs an <CODE>MBeanNotificationInfo</CODE> object. 0N/A * @param notifTypes The array of strings (in dot notation) 0N/A * containing the notification types that the MBean may emit. 0N/A * This may be null with the same effect as a zero-length array. 0N/A * @param name The fully qualified Java class name of the 0N/A * described notifications. 0N/A * @param description A human readable description of the data. 0N/A * Constructs an <CODE>MBeanNotificationInfo</CODE> object. 0N/A * @param notifTypes The array of strings (in dot notation) 0N/A * containing the notification types that the MBean may emit. 0N/A * This may be null with the same effect as a zero-length array. 0N/A * @param name The fully qualified Java class name of the 0N/A * described notifications. 0N/A * @param description A human readable description of the data. 0N/A * @param descriptor The descriptor for the notifications. This may be null 0N/A * which is equivalent to an empty descriptor. 0N/A /* We do not validate the notifTypes, since the spec just says 0N/A they are dot-separated, not that they must look like Java 0N/A classes. E.g. the spec doesn't forbid "sun.prob.25" as a 0N/A notifType, though it doesn't explicitly allow it 0N/A * Returns a shallow clone of this instance. 0N/A * The clone is obtained by simply calling <tt>super.clone()</tt>, 0N/A * thus calling the default native shallow cloning mechanism 0N/A * implemented by <tt>Object.clone()</tt>. 0N/A * No deeper cloning of any internal field is made. 0N/A // should not happen as this class is cloneable 0N/A * Returns the array of strings (in dot notation) containing the 0N/A * notification types that the MBean may emit. 0N/A * @return the array of strings. Changing the returned array has no 0N/A * effect on this MBeanNotificationInfo. 0N/A * Compare this MBeanNotificationInfo to another. 0N/A * @param o the object to compare to. 0N/A * @return true if and only if <code>o</code> is an MBeanNotificationInfo 0N/A * such that its {@link #getName()}, {@link #getDescription()}, 0N/A * {@link #getDescriptor()}, 0N/A * and {@link #getNotifTypes()} values are equal (not necessarily 0N/A * identical) to those of this MBeanNotificationInfo. Two 0N/A * notification type arrays are equal if their corresponding 0N/A * elements are equal. They are not equal if they have the same 0N/A * elements but in a different order.