/** * File to incorporate as application.xml. * @param descr the descriptor file */ public void setAppxml(File descr) { deploymentDescriptor = descr; if (!deploymentDescriptor.exists()) { throw new BuildException( "Deployment descriptor: %s does not exist.", deploymentDescriptor); } // Create a ZipFileSet for this file, and pass it up. ZipFileSet fs = new ZipFileSet(); fs.setFile(deploymentDescriptor); fs.setFullpath(XML_DESCRIPTOR_PATH); super.addFileset(fs); }
/** * set the deployment descriptor to use (WEB-INF/web.xml); * required unless <tt>update=true</tt> * @param descr the deployment descriptor file */ public void setWebxml(File descr) { deploymentDescriptor = descr; if (!deploymentDescriptor.exists()) { throw new BuildException("Deployment descriptor: does not exist.", deploymentDescriptor); } // Create a ZipFileSet for this file, and pass it up. ZipFileSet fs = new ZipFileSet(); fs.setFile(deploymentDescriptor); fs.setFullpath(XML_DESCRIPTOR_PATH); super.addFileset(fs); }
private void processDescriptor(File xmlDtor, String xmlDtorName) { if (!xmlDtor.exists()) throw new BuildException("Deployment descriptor: " + xmlDtor + " does not exist."); // Add a new fileset for the DD. ZipFileSet fs = new ZipFileSet(); fs.setFile(xmlDtor); fs.setFullpath("META-INF/" + xmlDtorName); super.addFileset(fs); }
private void setServicexml(File [] servicexml) { this.servicexml = servicexml; for (int i = 0; i < servicexml.length; i++) { if (!servicexml[i].exists()) { throw new BuildException("Service deployment descriptor: " + servicexml[i] + " does not exist."); } } for (int i = 0; i < servicexml.length; i++) { ZipFileSet fs = new ZipFileSet(); fs.setFile(servicexml[i]); fs.setFullpath(servicexml[i].getName()); super.addFileset(fs); } // look for oc-service.xml extension dd if (extXmlStr != null) { File extXml = (metainfbase == null) ? new File(extXmlStr) : new File(metainfbase, extXmlStr); if (!extXml.exists()) { throw new BuildException("Service extension deployment descriptor: " + extXml + " does not exist."); } ZipFileSet fs = new ZipFileSet(); fs.setFile(extXml); fs.setFullpath("META-INF/oc-service.xml"); super.addFileset(fs); } }
fs.setFullpath(componentFile.getName()); super.addFileset(fs); fs.setFullpath("META-INF/deployable-unit.xml"); super.addFileset(fs); } catch (Exception e) {
z.setFullpath("/WEB-INF/plugins/"+hpi.getArtifactId()+".hpi"); rezip.addZipfileset(z);