本文整理汇总了Java中org.apache.tinkerpop.gremlin.GraphManager类的典型用法代码示例。如果您正苦于以下问题:Java GraphManager类的具体用法?Java GraphManager怎么用?Java GraphManager使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
GraphManager类属于org.apache.tinkerpop.gremlin包,在下文中一共展示了GraphManager类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setupTest
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
@Before
public void setupTest() {
assumeTrue(graphMeetsTestRequirements());
try {
// ignore tests that aren't supported by a specific TraversalEngine
final String testName = name.getMethodName();
// tests that are parameterized have a square bracket with parameterized name appended to the actual
// test method name. have to strip that off so that reflection can find it
final String methodName = testName.contains("[") ? testName.substring(0, testName.indexOf('[')) : testName;
final IgnoreEngine ignoreEngine = this.getClass().getMethod(methodName).getAnnotation(IgnoreEngine.class);
if (ignoreEngine != null)
assumeTrue(String.format("This test is ignored for %s", ignoreEngine.value()), !ignoreEngine.value().equals(GraphManager.getTraversalEngineType()));
} catch (NoSuchMethodException nsme) {
// some tests are parameterized
throw new RuntimeException(String.format("Could not find test method %s in test case %s", name.getMethodName(), this.getClass().getName()));
}
}
示例2: unloadSugar
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
private void unloadSugar() {
try {
SugarTestHelper.clearRegistry(GraphManager.getGraphProvider());
} catch (Exception ex) {
throw new RuntimeException(ex);
}
}
示例3: hasGraphComputerRequirement
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
/**
* Determines if this test suite has "computer" requirements.
*/
protected boolean hasGraphComputerRequirement() {
// do the negation of STANDARD as we expect a future type of REASONING that would infer COMPUTER support
return !GraphManager.getTraversalEngineType().equals(TraversalEngine.Type.STANDARD);
}
示例4: TemporaryTests
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
public TemporaryTests() throws Exception {
GraphManager.setGraphProvider(new RestGraphProvider());
}
示例5: Misc
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
public Misc() throws Exception {
GraphManager.setGraphProvider(new IntegrationGraphProvider());
}
示例6: MultiFieldTests
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
public MultiFieldTests() throws Exception {
GraphManager.setGraphProvider(new ElasticGraphProvider());
}
示例7: TempTests
import org.apache.tinkerpop.gremlin.GraphManager; //导入依赖的package包/类
public TempTests() throws SQLException, ClassNotFoundException {
GraphManager.setGraphProvider(new JdbcGraphProvider());
}