1 7 8 package javax.management; 9 10 11 18 public class MBeanParameterInfo extends MBeanFeatureInfo implements java.io.Serializable , Cloneable { 19 20 21 static final long serialVersionUID = 7432616882776782338L; 22 23 24 static final MBeanParameterInfo [] NO_PARAMS = new MBeanParameterInfo [0]; 25 26 29 private final String type; 30 31 32 39 public MBeanParameterInfo(String name, 40 String type, 41 String description) 42 throws IllegalArgumentException { 43 44 super(name, description); 45 46 this.type = type; 47 } 48 49 50 60 public Object clone () { 61 try { 62 return super.clone() ; 63 } catch (CloneNotSupportedException e) { 64 return null; 66 } 67 } 68 69 74 public String getType() { 75 return type; 76 } 77 78 88 public boolean equals(Object o) { 89 if (o == this) 90 return true; 91 if (!(o instanceof MBeanParameterInfo )) 92 return false; 93 MBeanParameterInfo p = (MBeanParameterInfo ) o; 94 return (p.getName().equals(getName()) && 95 p.getType().equals(getType()) && 96 p.getDescription().equals(getDescription())); 97 } 98 99 public int hashCode() { 100 return getName().hashCode() ^ getType().hashCode(); 101 } 102 } 103 | Popular Tags |