1 22 package org.jboss.test.xml.mbeanserver; 23 24 import java.util.ArrayList ; 25 import java.util.List ; 26 import java.util.Map ; 27 import java.util.HashMap ; 28 29 35 public class MBeanData 36 { 37 38 private String name; 39 40 private String code; 41 42 private ArrayList attributes = new ArrayList (); 43 44 private ArrayList depends = new ArrayList (); 45 46 public String getName() 47 { 48 49 return name; 50 } 51 52 public void setName(String name) 53 { 54 this.name = name; 55 } 56 57 public String getCode() 58 { 59 return code; 60 } 61 62 public void setCode(String code) 63 { 64 this.code = code; 65 } 66 67 public List getAttributes() 68 { 69 return attributes; 70 } 71 72 public void setAttributes(List attributes) 73 { 74 this.attributes.clear(); 75 this.attributes.addAll(attributes); 76 } 77 78 public List getDepends() 79 { 80 return depends; 81 } 82 public void setDepends(List depends) 83 { 84 this.depends.clear(); 85 this.depends.addAll(depends); 86 } 87 88 public Map getAttributeMap() 89 { 90 HashMap map = new HashMap (); 91 for(int n = 0; n < attributes.size(); n ++) 92 { 93 MBeanAttribute attr = (MBeanAttribute) attributes.get(n); 94 map.put(attr.getName(), attr); 95 } 96 return map; 97 } 98 } 99 | Popular Tags |