MCPcopy Index your code
hub / github.com/processing/processing / shutdown

Method shutdown

app/src/processing/app/Console.java:170–182  ·  view source on GitHub ↗

Close the streams so that the temporary files can be deleted. File.deleteOnExit() cannot be used because the stdout and stderr files are inside a folder, and have to be deleted before the folder itself is deleted, which can't be guaranteed when using the deleteOnExit() method.

()

Source from the content-addressed store, hash-verified

168 * the deleteOnExit() method.
169 */
170 static public void shutdown() {
171 // replace original streams to remove references to console's streams
172 System.setOut(systemOut);
173 System.setErr(systemErr);
174
175 cleanup(consoleOut);
176 cleanup(consoleErr);
177
178 // also have to close the original FileOutputStream
179 // otherwise it won't be shut down completely
180 cleanup(stdoutFile);
181 cleanup(stderrFile);
182 }
183
184
185 static private void cleanup(OutputStream output) {

Callers 3

handleQuitMethod · 0.95
disposeMethod · 0.45
setColumnTypesMethod · 0.45

Calls 1

cleanupMethod · 0.95

Tested by

no test coverage detected