I am writing Eclipse plugins for Java, and have the following problem:
Given an IEditorPart, I need to check if it is a java editor.
I could do (IEditor instanceof JavaEditor), but JavaEditor is an org.eclipse.jdt.internal.ui.javaeditor.JavaEditor, which falls under the JDT's "internal" classes.
Is there a smarter and safer way to do this? I'm not sure why there is no non-internal interface for this.