use of com.intellij.debugger.ui.impl.watch.ArrayElementDescriptorImpl in project intellij-community by JetBrains.
the class ArrayRenderer method getChildValueExpression.
public PsiExpression getChildValueExpression(DebuggerTreeNode node, DebuggerContext context) {
LOG.assertTrue(node.getDescriptor() instanceof ArrayElementDescriptorImpl, node.getDescriptor().getClass().getName());
ArrayElementDescriptorImpl descriptor = (ArrayElementDescriptorImpl) node.getDescriptor();
PsiElementFactory elementFactory = JavaPsiFacade.getInstance(node.getProject()).getElementFactory();
try {
LanguageLevel languageLevel = LanguageLevelProjectExtension.getInstance(node.getProject()).getLanguageLevel();
return elementFactory.createExpressionFromText("this[" + descriptor.getIndex() + "]", elementFactory.getArrayClass(languageLevel));
} catch (IncorrectOperationException e) {
LOG.error(e);
return null;
}
}
Aggregations