Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (102)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (322)
Collections:
Other Resources:
JDK 11 jdk.compiler.jmod - Compiler Tool
JDK 11 jdk.compiler.jmod is the JMOD file for JDK 11 Compiler tool,
which can be invoked by the "javac" command.
JDK 11 Compiler tool compiled class files are stored in \fyicenter\jdk-11.0.1\jmods\jdk.compiler.jmod.
JDK 11 Compiler tool compiled class files are also linked and stored in the \fyicenter\jdk-11.0.1\lib\modules JImage file.
JDK 11 Compiler source code files are stored in \fyicenter\jdk-11.0.1\lib\src.zip\jdk.compiler.
You can click and view the content of each source code file in the list below.
✍: FYIcenter
⏎ com/sun/tools/sjavac/comp/CompilationService.java
/* * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package com.sun.tools.sjavac.comp; import java.io.File; import java.io.IOException; import java.io.PrintWriter; import java.io.StringWriter; import java.net.URI; import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.Set; import javax.tools.JavaFileObject; import javax.tools.StandardJavaFileManager; import javax.tools.StandardLocation; import javax.tools.ToolProvider; import com.sun.tools.javac.api.JavacTaskImpl; import com.sun.tools.javac.api.JavacTool; import com.sun.tools.javac.main.Main; import com.sun.tools.javac.main.Main.Result; import com.sun.tools.javac.util.Context; import com.sun.tools.javac.util.Dependencies; import com.sun.tools.javac.util.ListBuffer; import com.sun.tools.sjavac.Log; import com.sun.tools.sjavac.Util; import com.sun.tools.sjavac.comp.dependencies.NewDependencyCollector; import com.sun.tools.sjavac.comp.dependencies.PublicApiCollector; import com.sun.tools.sjavac.server.CompilationSubResult; import com.sun.tools.sjavac.server.SysInfo; /** * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own risk. * This code and its internal interfaces are subject to change or * deletion without notice.</b> */ public class CompilationService { public SysInfo getSysInfo() { return new SysInfo(Runtime.getRuntime().availableProcessors(), Runtime.getRuntime().maxMemory()); } public CompilationSubResult compile(String protocolId, String invocationId, String[] args, List<File> explicitSources, Set<URI> sourcesToCompile, Set<URI> visibleSources) { JavacTool compiler = (JavacTool) ToolProvider.getSystemJavaCompiler(); try (StandardJavaFileManager fm = compiler.getStandardFileManager(null, null, null)) { SmartFileManager sfm = new SmartFileManager(fm); Context context = new Context(); Dependencies.GraphDependencies.preRegister(context); // Now setup the actual compilation CompilationSubResult compilationResult = new CompilationSubResult(Result.OK); // First deal with explicit source files on cmdline and in at file ListBuffer<JavaFileObject> explicitJFOs = new ListBuffer<>(); for (JavaFileObject jfo : fm.getJavaFileObjectsFromFiles(explicitSources)) { explicitJFOs.append(SmartFileManager.locWrap(jfo, StandardLocation.SOURCE_PATH)); } // Now deal with sources supplied as source_to_compile ListBuffer<File> sourcesToCompileFiles = new ListBuffer<>(); for (URI u : sourcesToCompile) sourcesToCompileFiles.append(new File(u)); for (JavaFileObject jfo : fm.getJavaFileObjectsFromFiles(sourcesToCompileFiles)) explicitJFOs.append(SmartFileManager.locWrap(jfo, StandardLocation.SOURCE_PATH)); // Create a log to capture compiler output StringWriter stderrLog = new StringWriter(); Result result; PublicApiCollector pubApiCollector = new PublicApiCollector(context, explicitJFOs); PathAndPackageVerifier papVerifier = new PathAndPackageVerifier(); NewDependencyCollector depsCollector = new NewDependencyCollector(context, explicitJFOs); try { if (explicitJFOs.size() > 0) { sfm.setVisibleSources(visibleSources); sfm.cleanArtifacts(); // Do the compilation! JavacTaskImpl task = (JavacTaskImpl) compiler.getTask(new PrintWriter(stderrLog), sfm, null, Arrays.asList(args), null, explicitJFOs, context); sfm.setSymbolFileEnabled(!com.sun.tools.javac.util.Options.instance(context).isSet("ignore.symbol.file")); task.addTaskListener(depsCollector); task.addTaskListener(pubApiCollector); task.addTaskListener(papVerifier); logJavacInvocation(args); result = task.doCall(); Log.debug("javac result: " + result); sfm.flush(); } else { result = Result.ERROR; } } catch (Exception e) { Log.error(Util.getStackTrace(e)); stderrLog.append(Util.getStackTrace(e)); result = Result.ERROR; } compilationResult.packageArtifacts = sfm.getPackageArtifacts(); if (papVerifier.errorsDiscovered()) { result = Result.ERROR; } compilationResult.packageDependencies = depsCollector.getDependencies(false); compilationResult.packageCpDependencies = depsCollector.getDependencies(true); compilationResult.packagePubapis = pubApiCollector.getPubApis(true); compilationResult.dependencyPubapis = pubApiCollector.getPubApis(false); compilationResult.stderr = stderrLog.toString(); compilationResult.result = result; return compilationResult; } catch (IOException e) { throw new Error(e); } } private void logJavacInvocation(String[] args) { Log.debug("Invoking javac with args"); Iterator<String> argIter = Arrays.asList(args).iterator(); while (argIter.hasNext()) { String arg = argIter.next(); String line = " " + arg; if (arg.matches("\\-(d|cp|classpath|sourcepath|source|target)") && argIter.hasNext()) { line += " " + argIter.next(); } Log.debug(line); } } }
⏎ com/sun/tools/sjavac/comp/CompilationService.java
Or download all of them as a single archive file:
File name: jdk.compiler-11.0.1-src.zip File size: 1347269 bytes Release date: 2018-11-04 Download
⇒ JDK 11 jdk.crypto.cryptoki.jmod - Crypto KI Module
2020-08-13, ≈137🔥, 0💬
Popular Posts:
iText is an ideal library for developers looking to enhance web- and other applications with dynamic...
JDK 1.1 source code directory contains Java source code for JDK 1.1 core classes: "C:\fyicenter\jdk-...
Apache Neethi provides general framework for the programmers to use WS Policy. It is compliant with ...
How to perform XML Schema validation with sax\Writer.java provided in the Apache Xerces package? You...
How to display types defined in an XML Schema file with the xs\QueryXS.java provided in the Apache X...