- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中org.uberfire.java.nio.file.WatchService.close()
方法的一些代码示例,展示了WatchService.close()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WatchService.close()
方法的具体详情如下:
包路径:org.uberfire.java.nio.file.WatchService
类名称:WatchService
方法名:close
暂无
代码示例来源:origin: kiegroup/appformer
@PreDestroy
private void shutdown() {
executorService.shutdown();
active = false;
if (ws != null) {
ws.close();
}
}
代码示例来源:origin: org.uberfire/uberfire-metadata-commons-io
@Override
public void dispose() {
watchServicesByFS.values()
.forEach(ws -> ws.close());
activeIndexerDispatchers.forEach(d -> d.dispose());
super.dispose();
}
代码示例来源:origin: kiegroup/appformer
@Override
public void dispose() {
watchServicesByFS.values()
.forEach(ws -> ws.close());
activeIndexerDispatchers.forEach(d -> d.dispose());
super.dispose();
}
代码示例来源:origin: kiegroup/appformer
@PreDestroy
protected void dispose() {
isDisposed = true;
for (final WatchService watchService : watchServices) {
watchService.close();
}
for (final Future<?> job : jobs) {
if (!job.isCancelled() && !job.isDone()) {
job.cancel(true);
}
}
executorService.shutdown(); // Disable new tasks from being submitted
try {
// Wait a while for existing tasks to terminate
if (!executorService.awaitTermination(AWAIT_TERMINATION_TIMEOUT,
TimeUnit.SECONDS)) {
executorService.shutdownNow(); // Cancel currently executing tasks
// Wait a while for tasks to respond to being cancelled
if (!executorService.awaitTermination(AWAIT_TERMINATION_TIMEOUT,
TimeUnit.SECONDS)) {
LOG.error("Thread pool did not terminate");
}
}
} catch (InterruptedException ie) {
// (Re-)Cancel if current thread also interrupted
executorService.shutdownNow();
// Preserve interrupt status
Thread.currentThread().interrupt();
}
}
代码示例来源:origin: org.guvnor/guvnor-structure-backend
watchService.close();
代码示例来源:origin: kiegroup/appformer
watchService.close();
代码示例来源:origin: org.uberfire/uberfire-metadata-commons-io
private void cleanupDeletedFS(FileSystem fs) {
WatchService ws = watchServicesByFS.remove(fs.getName());
if (ws != null && !ws.isClose()) {
ws.close();
}
fs.getRootDirectories().forEach(rootPath -> indexEngine.delete(KObjectUtil.toKCluster(rootPath)));
}
代码示例来源:origin: kiegroup/appformer
private void cleanupDeletedFS(FileSystem fs) {
WatchService ws = watchServicesByFS.remove(fs.getName());
if (ws != null && !ws.isClose()) {
ws.close();
}
fs.getRootDirectories().forEach(rootPath -> indexEngine.delete(KObjectUtil.toKCluster(rootPath)));
}
代码示例来源:origin: org.uberfire/uberfire-metadata-commons-io
@Test
public void recreatingFileSystemMakesNewWatchService() throws Exception {
URI uri = new URI("test:///some/path");
Map<String, ?> env = Collections.emptyMap();
FileSystem fs1 = ioService.newFileSystem(uri, env);
verify(fs1).newWatchService();
FSPath fsPath = mock(FSPath.class);
when(fsPath.getFileSystem()).thenReturn(fs1);
ioService.delete(fsPath);
verify(fs1.newWatchService()).close();
FileSystem fs2 = ioService.newFileSystem(uri, env);
// Stubs are reused so this will have been invoked one above in IOService, and once in this test in a verify method.
verify(fs2, times(3)).newWatchService();
}
代码示例来源:origin: kiegroup/appformer
@Test
public void recreatingFileSystemMakesNewWatchService() throws Exception {
URI uri = new URI("test:///some/path");
Map<String, ?> env = Collections.emptyMap();
FileSystem fs1 = ioService.newFileSystem(uri, env);
verify(fs1).newWatchService();
FSPath fsPath = mock(FSPath.class);
when(fsPath.getFileSystem()).thenReturn(fs1);
ioService.delete(fsPath);
verify(fs1.newWatchService()).close();
FileSystem fs2 = ioService.newFileSystem(uri, env);
// Stubs are reused so this will have been invoked one above in IOService, and once in this test in a verify method.
verify(fs2, times(3)).newWatchService();
}
本文整理了Java中org.uberfire.java.nio.file.WatchService类的一些代码示例,展示了WatchService类的具体用法。这些代码示例主要来源于Github/St
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter类的一些代码示例,展示了WorkbenchPartPresente
本文整理了Java中org.uberfire.java.nio.file.WatchKey类的一些代码示例,展示了WatchKey类的具体用法。这些代码示例主要来源于Github/Stackoverf
本文整理了Java中org.uberfire.java.nio.file.WatchService.close()方法的一些代码示例,展示了WatchService.close()的具体用法。这些代码
本文整理了Java中org.uberfire.java.nio.file.WatchService.poll()方法的一些代码示例,展示了WatchService.poll()的具体用法。这些代码示例
本文整理了Java中org.uberfire.java.nio.file.WatchService.take()方法的一些代码示例,展示了WatchService.take()的具体用法。这些代码示例
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setWrappedWidget()方法的一些代码示例,展示了W
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.getTitle()方法的一些代码示例,展示了Workbench
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.getDefinition()方法的一些代码示例,展示了Work
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.getMenus()方法的一些代码示例,展示了Workbench
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.getTitleDecoration()方法的一些代码示例,展示
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setTitle()方法的一些代码示例,展示了Workbench
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setContextId()方法的一些代码示例,展示了Workb
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setDefinition()方法的一些代码示例,展示了Work
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setTitleDecoration()方法的一些代码示例,展示
本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.setMenus()方法的一些代码示例,展示了Workbench
本文整理了Java中org.uberfire.java.nio.file.WatchKey.reset()方法的一些代码示例,展示了WatchKey.reset()的具体用法。这些代码示例主要来源于G
本文整理了Java中org.uberfire.java.nio.file.WatchKey.pollEvents()方法的一些代码示例,展示了WatchKey.pollEvents()的具体用法。这些
本文整理了Java中org.uberfire.ext.widgets.common.client.common.popups.YesNoCancelPopup类的一些代码示例,展示了YesNoCanc
本文整理了Java中org.uberfire.ext.widgets.common.client.common.popups.YesNoCancelPopup.show()方法的一些代码示例,展示了Y
我是一名优秀的程序员,十分优秀!