1 26 package org.objectweb.jonas_ws.deployment.xml; 27 28 import org.objectweb.jonas_lib.deployment.xml.AbsElement; 29 import org.objectweb.jonas_lib.deployment.xml.JLinkedList; 30 31 36 37 public class JonasWebserviceDescription extends AbsElement { 38 39 42 private String webserviceDescriptionName = null; 43 44 47 private String defaultEndpointURI = null; 48 49 52 private String wsdlPublishDirectory = null; 53 54 57 private JLinkedList jonasPortComponentList = null; 58 59 62 public JonasWebserviceDescription() { 63 super(); 64 jonasPortComponentList = new JLinkedList("jonas-port-component"); 65 } 66 67 70 public JLinkedList getJonasPortComponentList() { 71 return jonasPortComponentList; 72 } 73 74 78 public void addJonasPortComponent(JonasPortComponent jonasPortComponent) { 79 jonasPortComponentList.add(jonasPortComponent); 80 } 81 82 83 86 public String getDefaultEndpointURI() { 87 return defaultEndpointURI; 88 } 89 90 93 public void setDefaultEndpointURI(String defaultEndpointURI) { 94 this.defaultEndpointURI = defaultEndpointURI; 95 } 96 97 100 public String getWebserviceDescriptionName() { 101 return webserviceDescriptionName; 102 } 103 104 107 public void setWebserviceDescriptionName(String webserviceDescriptionName) { 108 this.webserviceDescriptionName = webserviceDescriptionName; 109 } 110 111 114 public String getWsdlPublishDirectory() { 115 return wsdlPublishDirectory; 116 } 117 118 121 public void setWsdlPublishDirectory(String wsdlPublishDirectory) { 122 this.wsdlPublishDirectory = wsdlPublishDirectory; 123 } 124 125 130 public String toXML(int indent) { 131 StringBuffer sb = new StringBuffer (); 132 sb.append(indent(indent)); 133 sb.append("<jonas-webservice-description>\n"); 134 135 indent += 2; 136 sb.append(xmlElement(webserviceDescriptionName, "webservice-description-name", indent)); 138 sb.append(xmlElement(defaultEndpointURI, "default-endpoint-uri", indent)); 140 sb.append(jonasPortComponentList.toXML(indent)); 142 sb.append(xmlElement(wsdlPublishDirectory, "wsdl-publish-directory", indent)); 144 indent -= 2; 145 146 sb.append(indent(indent)); 147 sb.append("</jonas-webservice-description>\n"); 148 149 return sb.toString(); 150 } 151 } 152 | Popular Tags |