- 授权协议: 未知
- 开发语言: Java
- 操作系统: 跨平台
- 软件首页: http://gee.cs.oswego.edu/dl/classes/EDU/oswego/cs/dl/util/concurrent/intro.html
- 软件文档: http://gee.cs.oswego.edu/dl/classes/index.html
软件介绍
util.concurrent 是一个 Java 语言的并发开发包,示例代码:
public class Executor
{
private static Logger logger = Logger.getLogger(Executor.class);
private static PooledExecutor executor = new PooledExecutor(5);
static {
executor.setMinimumPoolSize(2);
executor.setMaximumPoolSize(10);
executor.setKeepAliveTime(1000 * 60 * 10);
}
public static void execute(Runnable runnable) {
try {
executor.execute(runnable);
}
catch (Exception e) {
logger.error("Exception while running task: " + e, e);
}
}
}
