Package org.apache.tools.ant.taskdefs

Examples of org.apache.tools.ant.taskdefs.XSLTProcess$Param


    }

    private void genreport(ResolutionCacheManager cache, String organisation, String module)
            throws IOException {
        // first process the report with xslt
        XSLTProcess xslt = new XSLTProcess();
        xslt.setTaskName(getTaskName());
        xslt.setProject(getProject());
        xslt.init();

        String resolveId = ResolveOptions.getDefaultResolveId(new ModuleId(organisation, module));
        xslt.setIn(cache.getConfigurationResolveReportInCache(resolveId, "default"));
        xslt.setOut(new File(todir, outputname + "." + xslext));

        xslt.setStyle(xslFile);

        XSLTProcess.Param param = xslt.createParam();
        param.setName("extension");
        param.setExpression(xslext);

        // add the provided XSLT parameters
        for (Iterator it = params.iterator(); it.hasNext();) {
            param = (XSLTProcess.Param) it.next();
            XSLTProcess.Param realParam = xslt.createParam();
            realParam.setName(param.getName());
            realParam.setExpression(param.getExpression());
        }

        xslt.execute();
    }
View Full Code Here


        return style.getAbsolutePath();
    }

    private void gen(ResolutionCacheManager cache, String organisation, String module, String style,
            String ext) throws IOException {
        XSLTProcess xslt = new XSLTProcess();
        xslt.setTaskName(getTaskName());
        xslt.setProject(getProject());
        xslt.init();

        String resolveId = ResolveOptions.getDefaultResolveId(new ModuleId(organisation, module));
        xslt.setIn(cache.getConfigurationResolveReportInCache(resolveId, "default"));
        xslt.setOut(new File(todir, outputname + "." + ext));
        xslt.setBasedir(cache.getResolutionCacheRoot());
        xslt.setStyle(style);
        xslt.execute();
    }
View Full Code Here

        FileTasks.assertFile(xslt);
        FileTasks.assertFile(input);

        FileTasks.assertFileExtension(xslt, ".xsl");

        XSLTProcess transform = new XSLTProcess();
        transform.setStyle(xslt.toString());
        transform.setIn(input.toFile());
        transform.setOut(output.toFile());

        transform.setTaskName("xslt");
        transform.setProject(AntUtil.builder().getProject());

        transform.execute();
    }
View Full Code Here

TOP

Related Classes of org.apache.tools.ant.taskdefs.XSLTProcess$Param

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.