1 27 package org.objectweb.jonas_rar.deployment.xml; 28 29 import org.objectweb.jonas_lib.deployment.xml.AbsElement; 30 import org.objectweb.jonas_lib.deployment.xml.JLinkedList; 31 36 37 public class Activationspec extends AbsElement { 38 39 42 private String activationspecClass = null; 43 44 47 private JLinkedList requiredConfigPropertyList = null; 48 49 50 53 public Activationspec() { 54 super(); 55 requiredConfigPropertyList = new JLinkedList("required-config-property"); 56 } 57 58 62 public String getActivationspecClass() { 63 return activationspecClass; 64 } 65 66 70 public void setActivationspecClass(String activationspecClass) { 71 this.activationspecClass = activationspecClass; 72 } 73 74 78 public JLinkedList getRequiredConfigPropertyList() { 79 return requiredConfigPropertyList; 80 } 81 82 86 public void setRequiredConfigPropertyList(JLinkedList requiredConfigPropertyList) { 87 this.requiredConfigPropertyList = requiredConfigPropertyList; 88 } 89 90 94 public void addRequiredConfigProperty(RequiredConfigProperty requiredConfigProperty) { 95 requiredConfigPropertyList.add(requiredConfigProperty); 96 } 97 98 103 public String toXML(int indent) { 104 StringBuffer sb = new StringBuffer (); 105 sb.append(indent(indent)); 106 sb.append("<activationspec>\n"); 107 108 indent += 2; 109 110 sb.append(xmlElement(activationspecClass, "activationspec-class", indent)); 112 sb.append(requiredConfigPropertyList.toXML(indent)); 114 indent -= 2; 115 sb.append(indent(indent)); 116 sb.append("</activationspec>\n"); 117 118 return sb.toString(); 119 } 120 } 121 | Popular Tags |