Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "FAQ How do I find out the install location of a plug-in"

(New page: This took me far too many hours, so I thought I would share. In your activator, implement the following: String rootDirectory; public void start(BundleContext context) throws Ex...)
 
Line 1: Line 1:
 
This took me far too many hours, so I thought I would share. In your activator, implement the following:
 
This took me far too many hours, so I thought I would share. In your activator, implement the following:
 
+
<nowiki>
 
         String rootDirectory;
 
         String rootDirectory;
  
Line 9: Line 9:
 
rootDirectory = FileLocator.toFileURL(entry).getPath();  
 
rootDirectory = FileLocator.toFileURL(entry).getPath();  
 
}
 
}
 +
</nowiki>

Revision as of 23:24, 30 December 2008

This took me far too many hours, so I thought I would share. In your activator, implement the following: String rootDirectory; public void start(BundleContext context) throws Exception { super.start(context); //... URL entry = context.getBundle().getEntry("/"); rootDirectory = FileLocator.toFileURL(entry).getPath(); }

Back to the top