Package org.gradle.api.tasks.compile

Examples of org.gradle.api.tasks.compile.ForkOptions


    }

    public static String tryGetCompilerVersion(JavaCompile compileTask) {
        CompileOptions options = compileTask.getOptions();
        if (options.isFork()) {
            ForkOptions forkOptions = options.getForkOptions();
            return tryGetCompilerVersion(forkOptions);
        }
        else {
            return System.getProperty("java.version");
        }
View Full Code Here


    protected DaemonForkOptions toDaemonOptions(ScalaJavaJointCompileSpec spec) {
        return createJavaForkOptions(spec).mergeWith(createScalaForkOptions(spec));
    }

    private DaemonForkOptions createJavaForkOptions(ScalaJavaJointCompileSpec spec) {
        ForkOptions options = spec.getCompileOptions().getForkOptions();
        return new DaemonForkOptions(options.getMemoryInitialSize(), options.getMemoryMaximumSize(), options.getJvmArgs());
    }
View Full Code Here

    protected DaemonForkOptions toDaemonOptions(GroovyJavaJointCompileSpec spec) {
        return createJavaForkOptions(spec).mergeWith(createGroovyForkOptions(spec));
    }
   
    private DaemonForkOptions createJavaForkOptions(GroovyJavaJointCompileSpec spec) {
        ForkOptions options = spec.getCompileOptions().getForkOptions();
        return new DaemonForkOptions(options.getMemoryInitialSize(), options.getMemoryMaximumSize(), options.getJvmArgs());
    }
View Full Code Here

    }

    private void addLauncherOptions() {
        if (!includeLauncherOptions) { return; }

        ForkOptions forkOptions = spec.getCompileOptions().getForkOptions();
        if (forkOptions.getMemoryInitialSize() != null) {
            args.add("-J-Xms" + forkOptions.getMemoryInitialSize().trim());
        }
        if (forkOptions.getMemoryMaximumSize() != null) {
            args.add("-J-Xmx" + forkOptions.getMemoryMaximumSize().trim());
        }
        if (forkOptions.getJvmArgs() != null) {
            args.addAll(forkOptions.getJvmArgs());
        }
    }
View Full Code Here

        super(daemonWorkingDir, delegate, compilerDaemonFactory);
    }

    @Override
    protected DaemonForkOptions toDaemonOptions(JavaCompileSpec spec) {
        ForkOptions forkOptions = spec.getCompileOptions().getForkOptions();
        return new DaemonForkOptions(
                forkOptions.getMemoryInitialSize(), forkOptions.getMemoryMaximumSize(), forkOptions.getJvmArgs(),
                Collections.<File>emptyList(), Collections.singleton("com.sun.tools.javac"));
    }
View Full Code Here

TOP

Related Classes of org.gradle.api.tasks.compile.ForkOptions

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.