org.eclipse.xtext.ui.editor.hover.IEObjectHoverProvider的实例源码

项目:dsl-devkit    文件AbstractHoverTest.java   
/**
 * Build a directory of node hovers indexed by the {@link EObject}.
 *
 * @param model
 *          the model for which to build the hover map,must not be {@code null}
 */
private void buildHoverMap(final EObject model) {
  // All contained features
  List<EStructuralFeature> features = model.eClass().geteallStructuralFeatures();
  for (EStructuralFeature feature : features) {
    if (feature instanceof EReference && model.eIsSet(feature)) {
      EList<EObject> children = getFeatureValues(model,feature);
      boolean referenceAdded = false;
      IEObjectHoverProvider hoverProvider = getHoverProvider();
      for (EObject childModelElement : children) {
        if (!childModelElement.eIsProxy()) {
          buildHoverMap(childModelElement);
          Object element = childModelElement.eClass();
          Object hover = hoverProvider.getHoverInfo(childModelElement,null,null).getInfo();
          if (element != null && hover != null) {
            addToHoverMap(element,hover.toString());
            // also add the hover using the reference feature as key
            if (!referenceAdded) {
              addToHoverMap(feature,hover.toString());
              referenceAdded = true;
            }
          }
        }
      }
    }
  }
}
项目:n4js    文件N4JSUiModule.java   
/**
 * Bind custom IEObjectHoverProvider.
 */
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return N4JSHoverProvider.class;
}
项目:z80editor    文件Z80UiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return z80EObjectHoverProvider.class;
}
项目:bts    文件EgyDslUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return BTSEObjectHover.class;
}
项目:statecharts    文件SGenUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return HelpHoverProvider.class;
}
项目:statecharts    文件STextUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return CustomCSSHelpHoverProvider.class;
}
项目:plan    文件PlanUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
       return PlanHoverProvider.class;
}
项目:PHDL    文件PhdlUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return PhdlEObjectHoverProvider.class;
}
项目:openhab-hdl    文件RulesUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return ActionEObjectHoverProvider.class;
}
项目:openhab-hdl    文件ScriptUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return ActionEObjectHoverProvider.class;
}
项目:gama    文件GamlUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return GamlHoverProvider.class;
}
项目:yang-design-studio    文件YangUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return yangHoverProvider.class;
}
项目:antlr4ide    文件Antlr4UiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
  return Antlr4HoverProvider.class;
}
项目:jkind-xtext    文件JKindUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return JKindEObjectHoverProvider.class;
}
项目:packtpub-xtext-book-examples    文件ExpressionsUiModule.java   
public Class<? extends IEObjectHoverProvider> bindIEObjectHoverProvider() {
    return ExpressionSEObjectHoverProvider.class;
}
项目:dsl-devkit    文件AbstractHoverTest.java   
/**
 * Returns {@link IEObjectHoverProvider} for hover functionality of the editor.
 *
 * @return the {@link IEObjectHoverProvider} class for hover functionality,never {@code null}
 */
protected IEObjectHoverProvider getHoverProvider() {
  return getXtextTestUtil().get(IEObjectHoverProvider.class);
}

相关文章

买水果
比较全面的redis工具类
gson 反序列化到多态子类
java 版本的 mb_strwidth
JAVA 反转字符串的最快方法,大概比StringBuffer.reverse()性...
com.google.gson.internal.bind.ArrayTypeAdapter的实例源码...