Methods Summary |
---|
public java.lang.Object | clone()Returns a shallow clone of this instance. The clone is
obtained by simply calling super.clone(), thus calling
the default native shallow cloning mechanism implemented by
Object.clone(). No deeper cloning of any internal
field is made.
Since this class is immutable, cloning is chiefly of
interest to subclasses.
try {
return super.clone() ;
} catch (CloneNotSupportedException e) {
// should not happen as this class is cloneable
return null;
}
|
private static javax.management.MBeanParameterInfo[] | constructorSignature(java.lang.reflect.Constructor cn)
final Class[] classes = cn.getParameterTypes();
final MBeanParameterInfo[] params =
new MBeanParameterInfo[classes.length];
for (int i = 0; i < classes.length; i++) {
final String pn = "p" + (i + 1);
params[i] = new MBeanParameterInfo(pn, classes[i].getName(), "");
}
return params;
|
public boolean | equals(java.lang.Object o)Compare this MBeanConstructorInfo to another.
if (o == this)
return true;
if (!(o instanceof MBeanConstructorInfo))
return false;
MBeanConstructorInfo p = (MBeanConstructorInfo) o;
return (p.getName().equals(getName()) &&
p.getDescription().equals(getDescription()) &&
Arrays.equals(p.fastGetSignature(), fastGetSignature()));
|
private javax.management.MBeanParameterInfo[] | fastGetSignature()
if (immutable)
return signature;
else
return getSignature();
|
public javax.management.MBeanParameterInfo[] | getSignature()Returns the list of parameters for this constructor. Each
parameter is described by an MBeanParameterInfo
object.
The returned array is a shallow copy of the internal array,
which means that it is a copy of the internal array of
references to the MBeanParameterInfo objects but
that each referenced MBeanParameterInfo object is
not copied.
if (signature.length == 0)
return signature;
else
return (MBeanParameterInfo[]) signature.clone();
|
public int | hashCode()
int hash = getName().hashCode();
MBeanParameterInfo[] sig = fastGetSignature();
for (int i = 0; i < sig.length; i++)
hash ^= sig[i].hashCode();
return hash;
|