Methods Summary |
---|
public void | generate()Generate undeploy.wsdd. Only generate it if the emitter
is generating server-side mappings.
if (emitter.isServerSide()) {
super.generate();
}
|
protected java.lang.String | getFileName()Return the fully-qualified name of the undeploy.wsdd file
to be generated.
String dir =
emitter.getNamespaces().getAsDir(definition.getTargetNamespace());
return dir + "undeploy.wsdd";
|
protected java.io.PrintWriter | getPrintWriter(java.lang.String filename)Method getPrintWriter
File file = new File(filename);
File parent = new File(file.getParent());
parent.mkdirs();
FileOutputStream out = new FileOutputStream(file);
OutputStreamWriter writer = new OutputStreamWriter(out, "UTF-8");
return new PrintWriter(writer);
|
protected void | writeDeployPort(java.io.PrintWriter pw, javax.wsdl.Port port)Write out deployment and undeployment instructions for given WSDL port
String serviceName = port.getName();
pw.println(" <service name=\"" + serviceName + "\"/>");
|
protected void | writeDeployServices(java.io.PrintWriter pw)Write out deployment and undeployment instructions for each WSDL service
// deploy the ports on each service
Map serviceMap = definition.getServices();
for (Iterator mapIterator = serviceMap.values().iterator();
mapIterator.hasNext();) {
Service myService = (Service) mapIterator.next();
pw.println();
pw.println(
" <!-- "
+ Messages.getMessage(
"wsdlService00", myService.getQName().getLocalPart()) + " -->");
pw.println();
for (Iterator portIterator = myService.getPorts().values().iterator();
portIterator.hasNext();) {
Port myPort = (Port) portIterator.next();
writeDeployPort(pw, myPort);
}
}
|
protected void | writeFileBody(java.io.PrintWriter pw)Write the body of the deploy.wsdd file.
writeDeployServices(pw);
pw.println("</undeployment>");
|
protected void | writeFileHeader(java.io.PrintWriter pw)Replace the default file header with the deployment doc file header.
pw.println(Messages.getMessage("deploy01"));
pw.println(Messages.getMessage("deploy02"));
pw.println(Messages.getMessage("deploy04"));
pw.println(Messages.getMessage("deploy05"));
pw.println(Messages.getMessage("deploy06"));
pw.println(Messages.getMessage("deploy08"));
pw.println(Messages.getMessage("deploy09"));
pw.println();
pw.println("<undeployment");
pw.println(" xmlns=\"" + WSDDConstants.URI_WSDD + "\">");
|