Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[pde-dev] Help navigate to a method implementation by code

Hello

I am developing a plugin.

I need your help. I have a Table with methods' names . I need go to the method's' implementation in the editor when I click on the method name. The table has the path of the file where method is implemented and the method's header.

I will thank you if you could help me with code so as to do it.

By now I have the code to open a file. But I need to open the method's implementantion in a file.

File fileToOpen = new File(file);
if (fileToOpen.exists() && fileToOpen.isFile()) {
IFileStore fileStore = EFS.getLocalFileSystem().getStore(fileToOpen.toURI());
IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
try {
IEditorPart editor =IDE.openEditorOnFileStore(page, fileStore);
 
} catch (PartInitException exf) {
// Put your exception handler here if you wish to
}
}

Regards


Atentamente,


Andrés Fernando Wilches Riaño
Ingeniero de Sistemas y Computación
Estudiante de Maestría en Ingeniería de Sistemas y Computación
Universidad Nacional de Colombia

Back to the top