/** * Compiles the SWC. * * @param commandLine The command line. */ protected void compileSwc(List<String> commandLine) throws IOException, EnunciateException { ProcessBuilder processBuilder = new ProcessBuilder(commandLine.toArray(new String[commandLine.size()])); getSwcCompileDir().mkdirs(); processBuilder.directory(getSwcCompileDir()); processBuilder.redirectErrorStream(true); Process process = processBuilder.start(); BufferedReader procReader = new BufferedReader(new InputStreamReader(process.getInputStream())); String line = procReader.readLine(); while (line != null) { info(line); line = procReader.readLine(); } int procCode; try { procCode = process.waitFor(); } catch (InterruptedException e1) { throw new EnunciateException("Unexpected inturruption of the Flex compile process."); } if (procCode != 0) { throw new EnunciateException("SWC compile failed."); } }
/** * Compiles the SWC. * * @param commandLine The command line. */ protected void compileSwc(List<String> commandLine) throws IOException, EnunciateException { getSwcCompileDir().mkdirs(); Process process = new ProcessBuilder(commandLine).directory(getSwcCompileDir()).redirectErrorStream(true).start(); BufferedReader procReader = new BufferedReader(new InputStreamReader(process.getInputStream())); String line = procReader.readLine(); while (line != null) { info(line); line = procReader.readLine(); } int procCode; try { procCode = process.waitFor(); } catch (InterruptedException e1) { throw new EnunciateException("Unexpected inturruption of the Flex compile process."); } if (procCode != 0) { throw new EnunciateException("SWC compile failed."); } }
commandLine.set(compileCommandIndex, compilerConfig.getSwcCompileCommand()); commandLine.set(outputFileIndex, as3Bundle.getAbsolutePath()); info("Compiling %s for the client-side ActionScript classes...", as3Bundle.getAbsolutePath()); if (enunciate.isDebug()) { StringBuilder command = new StringBuilder(); info("Skipping compilation of %s as everything appears up-to-date...", as3Bundle.getAbsolutePath()); commandLine.set(sourcePathIndex, appSrcDir.getAbsolutePath()); info("Compiling %s ...", swfFilePath); if (enunciate.isDebug()) { StringBuilder command = new StringBuilder(); String line = procReader.readLine(); while (line != null) { info(line); line = procReader.readLine(); info("Skipping compilation of %s as everything appears up-to-date...", swfFilePath);
info("Generating the AMF externalizable types and their associated mappers..."); model.put("classnameFor", new AMFClassnameForMethod(amfTypePackageConversions)); for (SchemaInfo schemaInfo : model.getNamespacesToSchemas().values()) { info("Generating the AMF endpoint beans..."); for (WsdlInfo wsdlInfo : model.getNamespacesToWSDLs().values()) { for (EndpointInterface ei : wsdlInfo.getEndpointInterfaces()) { model.put("as3Aliases", as3Aliases); info("Generating the ActionScript types..."); for (SchemaInfo schemaInfo : model.getNamespacesToSchemas().values()) { for (TypeDefinition typeDefinition : schemaInfo.getTypeDefinitions()) { info("Generating the configuration files."); processTemplate(servicesConfigTemplate, model); info("Skipping generation of AMF support as everything appears up-to-date...");
info("Skipping generation of AMF support as everything appears up-to-date...");