FooPlugin.getDefault() returns null from code running inside the Foo plug-in [message #292715] |
Tue, 11 October 2005 11:22  |
Eclipse User |
|
|
|
I create in Eclipse 3.1 a plug-in called "Foo", and its AbstractUIPlugin class, called FooPlugin,
contains (as always) a method getDefault() to return the singleton instance of FooPlugin.
Somewhere else in the code of the Foo plug-in I call FooPlugin.getDefault() -- for example, to be
able to write to the log -- but the return value is null. Every time.
In most of my plug-ins this has never happened, not once. Why would it be happening in the Foo
plug-in? I.e., where should I look for the difference that is causing this?
thanks,
Paul
|
|
|
|
|
Re: FooPlugin.getDefault() returns null from code running inside the Foo plug-in [message #292731 is a reply to message #292720] |
Tue, 11 October 2005 15:13  |
Eclipse User |
|
|
|
Weird. We do have that line, and always have. As far as I can tell, the problem is some environmenmt
thing -- do fresh Eclipse 3.2M2 install, point at a suitable JRE (some of our code does not like
Java 1.5, alas), fresh checkout of all projects, and no problems.
Paul
Rich Kulp wrote:
> Check to see that the MANIFEST.MF has the following:
>
> Eclipse-AutoStart: true
>
> Without it, the FooPlugin won't be activated on the first reference to
> any class in Foo.
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.03332 seconds