use of org.eclipse.xtext.ui.editor.outline.IOutlineNode in project xtext-xtend by eclipse.
the class AbstractMultiModeOutlineTreeProvider method buildImportSectionNode.
@Override
public IXtendOutlineContext buildImportSectionNode(XtendFile xtendFile, IXtendOutlineContext context) {
EclipseXtendOutlineContext eclipseXtendOutlineContext = (EclipseXtendOutlineContext) context;
IOutlineNode parentNode = eclipseXtendOutlineContext.getParentNode();
EStructuralFeatureNode node = getOutlineNodeFactory().createEStructuralFeatureNode(parentNode, xtendFile.getImportSection(), XtypePackage.Literals.XIMPORT_SECTION__IMPORT_DECLARATIONS, images.forImportContainer(), "import declarations", false);
return eclipseXtendOutlineContext.withParentNode(node);
}
use of org.eclipse.xtext.ui.editor.outline.IOutlineNode in project xtext-xtend by eclipse.
the class AbstractMultiModeOutlineTreeProvider method buildFeatureNode.
@Override
public IXtendOutlineContext buildFeatureNode(JvmDeclaredType inferredType, EObject semanticFeature, IXtendOutlineContext context) {
EclipseXtendOutlineContext eclipseXtendOutlineContext = (EclipseXtendOutlineContext) context;
IOutlineNode parentNode = eclipseXtendOutlineContext.getParentNode();
int inheritanceDepth = eclipseXtendOutlineContext.getInheritanceDepth();
XtendFeatureNode featureNode = createNodeForFeature(parentNode, inferredType, semanticFeature, inheritanceDepth);
return eclipseXtendOutlineContext.withParentNode(featureNode);
}
use of org.eclipse.xtext.ui.editor.outline.IOutlineNode in project xtext-xtend by eclipse.
the class AbstractMultiModeOutlineTreeProvider method buildPackageNode.
@Override
public IXtendOutlineContext buildPackageNode(XtendFile xtendFile, IXtendOutlineContext context) {
EclipseXtendOutlineContext eclipseXtendOutlineContext = (EclipseXtendOutlineContext) context;
IOutlineNode parentNode = eclipseXtendOutlineContext.getParentNode();
String primaryPackage = xtendFile.getPackage();
EStructuralFeatureNode node = getOutlineNodeFactory().createEStructuralFeatureNode(parentNode, xtendFile, XtendPackage.Literals.XTEND_FILE__PACKAGE, images.forPackage(), primaryPackage, true);
return eclipseXtendOutlineContext.withParentNode(node);
}
use of org.eclipse.xtext.ui.editor.outline.IOutlineNode in project xtext-xtend by eclipse.
the class AbstractMultiModeOutlineTreeProvider method buildResolvedFeatureNode.
@Override
public IXtendOutlineContext buildResolvedFeatureNode(JvmDeclaredType inferredType, IResolvedFeature resolvedFeature, IXtendOutlineContext context) {
EclipseXtendOutlineContext eclipseXtendOutlineContext = (EclipseXtendOutlineContext) context;
IOutlineNode parentNode = eclipseXtendOutlineContext.getParentNode();
int inheritanceDepth = eclipseXtendOutlineContext.getInheritanceDepth();
XtendFeatureNode node = createNodeForResolvedFeature(parentNode, inferredType, resolvedFeature, inheritanceDepth);
return eclipseXtendOutlineContext.withParentNode(node);
}
use of org.eclipse.xtext.ui.editor.outline.IOutlineNode in project xtext-xtend by eclipse.
the class AbstractMultiModeOutlineTreeProvider method buildDispatcherNode.
@Override
public IXtendOutlineContext buildDispatcherNode(JvmDeclaredType baseType, JvmFeature dispatcher, List<JvmOperation> dispatchCases, IXtendOutlineContext context) {
EclipseXtendOutlineContext eclipseXtendOutlineContext = (EclipseXtendOutlineContext) context;
IOutlineNode parentNode = eclipseXtendOutlineContext.getParentNode();
int inheritanceDepth = eclipseXtendOutlineContext.getInheritanceDepth();
XtendFeatureNode dispatcherNode = createNodeForFeature(parentNode, baseType, dispatcher, inheritanceDepth);
dispatcherNode.setDispatch(true);
if (isInheritsDispatchCases(baseType, dispatchCases)) {
dispatcherNode.setImageDescriptor(images.forDispatcherFunction(dispatcher.getVisibility(), adornments.get(dispatcher) | JavaElementImageDescriptor.OVERRIDES));
}
return eclipseXtendOutlineContext.withParentNode(dispatcherNode);
}
Aggregations