本文整理了Java中org.eclipse.viatra.query.runtime.api.ViatraQueryEngine.getCurrentMatchers()
方法的一些代码示例,展示了ViatraQueryEngine.getCurrentMatchers()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ViatraQueryEngine.getCurrentMatchers()
方法的具体详情如下:
包路径:org.eclipse.viatra.query.runtime.api.ViatraQueryEngine
类名称:ViatraQueryEngine
方法名:getCurrentMatchers
[英]Access a copy of available ViatraQueryMatcher pattern matchers.
[中]访问可用ViatraQueryMatcher模式匹配器的副本。
代码示例来源:origin: org.eclipse.viatra/org.eclipse.viatra.query.runtime
public Set<IQuerySpecification<? extends ViatraQueryMatcher<? extends IPatternMatch>>> getRegisteredQuerySpecifications() {
return getCurrentMatchers().stream().map(ViatraQueryMatcher::getSpecification).collect(Collectors.toSet());
}
代码示例来源:origin: org.eclipse.viatra/org.eclipse.viatra.query.patternlanguage.emf
/**
* Initializes a pattern-specification mapping with the contents of an existing {@link ViatraQueryEngine}. </p>
* <p>
* <strong>Warning</strong> It is assumed that each query specification in the engine has a unique fqn - if the
* assumption fails, the resulting map is unspecified.
*
* @param engine
*/
public NameToSpecificationMap(ViatraQueryEngine engine) {
this();
for (ViatraQueryMatcher<?> matcher : engine.getCurrentMatchers()) {
IQuerySpecification<?> specification = matcher.getSpecification();
map.put(specification.getFullyQualifiedName(), specification);
}
}
内容来源于网络,如有侵权,请联系作者删除!