public class CompilerPool extends Object
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.
Modifier and Type | Method and Description |
---|---|
void |
execute(CompilerThread ct)
Execute a compiler thread.
|
Future<?> |
executeSubtask(CompilerThread t,
Runnable r)
Execute a minor task, for example generating bytecodes and writing them to disk,
that belong to a major compiler thread task.
|
JavacServer |
getJavacServer()
Return the javac server that this pool belongs to.
|
CompilerThread |
grabCompilerThread()
Acquire a compiler thread from the pool, or block until a thread is available.
|
long |
lastRequestFinished()
Return when the last request was finished.
|
int |
numActiveRequests()
Return how many threads are running at this very moment.
|
void |
returnCompilerThread(CompilerThread h)
Return the specified compiler thread to the pool.
|
void |
shutdown()
Shutdown the pool.
|
int |
startRequest()
Up the number of active requests.
|
long |
stopRequest()
Down the number of active requests.
|
public JavacServer getJavacServer()
public int numActiveRequests()
public long lastRequestFinished()
public int startRequest()
public long stopRequest()
public void execute(CompilerThread ct)
public Future<?> executeSubtask(CompilerThread t, Runnable r)
public void shutdown()
public CompilerThread grabCompilerThread() throws InterruptedException
InterruptedException
public void returnCompilerThread(CompilerThread h)
Copyright © 2017 earcam. All rights reserved.