Package com.granule.calcdeps

Examples of com.granule.calcdeps.CalcDeps


        FragmentDescriptor fd = new ExternalFragment("js/closure/goog/base.js");
        fragments.add(fd);
        fd = new InternalFragment(testCode);
        fragments.add(fd);

        CalcDeps cd = new CalcDeps();
        try {
            String path = new java.io.File(".").getCanonicalPath();
            List<FragmentDescriptor> results = cd.calcDeps(fragments, new SimpleRequestProxy(path),
                    new ArrayList<String>());
            String exp = "js/closure/goog/base.js\n" +
                    "js/closure/goog/debug/error.js\n" +
                    "js/closure/goog/string/string.js\n" +
                    "js/closure/goog/asserts/asserts.js\n" +
View Full Code Here


    }

    public void compileScript(CompressorSettings settings, IRequestProxy request) throws JSCompileException {
        logger.debug("Start compile javascript");
        mimeType = JAVASCRIPT_MIME;
        CalcDeps cd = new CalcDeps();
        String text = "";
        List<FragmentDescriptor> list = cd.calcDeps(fragments, request, settings.getClosurePathes());
        boolean isGoogleClosurePresent = !list.equals(fragments);
        if (isGoogleClosurePresent)
            list.add(0, new InternalFragment("CLOSURE_NO_DEPS=true;\n"));
        if (settings.getJsCompressMethod().equals(CompressorSettings.CLOSURE_COMPILER_VALUE))
            text = Compressor.compile(list, request, settings);
View Full Code Here

TOP

Related Classes of com.granule.calcdeps.CalcDeps

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.