本文整理了Java中org.vertexium.Graph.shutdown()
方法的一些代码示例,展示了Graph.shutdown()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Graph.shutdown()
方法的具体详情如下:
包路径:org.vertexium.Graph
类名称:Graph
方法名:shutdown
[英]Cleans up or disconnects from the underlying storage.
[中]清理或断开与基础存储的连接。
代码示例来源:origin: org.visallo/visallo-core
@Override
public void shutdown() {
this.graph.shutdown();
}
}
代码示例来源:origin: org.vertexium/vertexium-test
@After
public void after() throws Exception {
if (graph != null) {
graph.shutdown();
graph = null;
}
}
代码示例来源:origin: org.vertexium/vertexium-blueprints
@Override
public void shutdown() {
getGraph().shutdown();
}
代码示例来源:origin: visallo/vertexium
@After
public void after() throws Exception {
if (graph != null) {
graph.shutdown();
graph = null;
}
}
代码示例来源:origin: org.visallo/visallo-tools-migration-core
@Override
protected final int run() throws Exception {
graph = getGraph();
try {
Object visalloGraphVersionObj = graph.getMetadata(GRAPH_METADATA_VISALLO_GRAPH_VERSION_KEY);
if (visalloGraphVersionObj == null) {
throw new VisalloException("No graph metadata version set");
} else if (visalloGraphVersionObj instanceof Integer) {
Integer visalloGraphVersion = (Integer) visalloGraphVersionObj;
if (getFinalGraphVersion().equals(visalloGraphVersion)) {
throw new VisalloException("Migration has already completed. Graph version: " + visalloGraphVersion);
} else if (!getNeededGraphVersion().equals(visalloGraphVersion)) {
throw new VisalloException("Migration can only run from version " + getNeededGraphVersion() +
". Current graph version = " + visalloGraphVersion);
}
} else {
throw new VisalloException("Unexpected value for graph version: " + visalloGraphVersionObj);
}
if (migrate(graph)) {
graph.setMetadata(GRAPH_METADATA_VISALLO_GRAPH_VERSION_KEY, getFinalGraphVersion());
}
graph.flush();
afterMigrate(graph);
return 0;
} finally {
graph.shutdown();
}
}
内容来源于网络,如有侵权,请联系作者删除!