Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Re: Can I customize when the plug-in be loaded?
Re: Can I customize when the plug-in be loaded? [message #327367] Wed, 16 April 2008 16:16 Go to next message
Walter Harley is currently offline Walter HarleyFriend
Messages: 847
Registered: July 2009
Senior Member
"dazh" <reg.zhuce@163.com> wrote in message
news:fu52aa$5v8$1@build.eclipse.org...
> For example,can I make it loaded when the editor is activated?
> I need to make some configuration before it's used.

I'm adding eclipse.platform to the newsgroups list for this message, because
what you're asking about is a Platform question, unrelated to JDT.

In general, a plug-in will be loaded as soon as a resource within it is
accessed, for instance, as soon as a class is loaded. The Eclipse-LazyStart
option affects this. You didn't say what the relationship is between the
editor you're talking about and the plug-in you're talking about, so it's
hard to say more: for instance, are you talking about the plug-in that
implements the editor, or some other plug-in?

It is also possible to extend the org.eclipse.ui.startup extension point, to
force your plug-in to be loaded during Eclipse startup. This is generally a
bad idea and almost always unnecessary, and probably not the solution for
your problem.

Can you say more about the problem you are trying to solve? For instance,
what kind of "configuration" are you talking about; does it require UI? Is
it a one-time action or does it need to happen every time the plug-in's
functionality is used? What kind of functionality does the plug-in provide?
Re: Can I customize when the plug-in be loaded? [message #327371 is a reply to message #327367] Wed, 16 April 2008 16:44 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: reg.zhuce.163.com

Walter Harley 写道:
> "dazh" <reg.zhuce@163.com> wrote in message
> news:fu52aa$5v8$1@build.eclipse.org...
>> For example,can I make it loaded when the editor is activated?
>> I need to make some configuration before it's used.
>
> I'm adding eclipse.platform to the newsgroups list for this message, because
> what you're asking about is a Platform question, unrelated to JDT.
>
> In general, a plug-in will be loaded as soon as a resource within it is
> accessed, for instance, as soon as a class is loaded. The Eclipse-LazyStart
> option affects this. You didn't say what the relationship is between the
> editor you're talking about and the plug-in you're talking about, so it's
> hard to say more: for instance, are you talking about the plug-in that
> implements the editor, or some other plug-in?
>
> It is also possible to extend the org.eclipse.ui.startup extension point, to
> force your plug-in to be loaded during Eclipse startup. This is generally a
> bad idea and almost always unnecessary, and probably not the solution for
> your problem.
>
> Can you say more about the problem you are trying to solve? For instance,
> what kind of "configuration" are you talking about; does it require UI? Is
> it a one-time action or does it need to happen every time the plug-in's
> functionality is used? What kind of functionality does the plug-in provide?
>
>
Thank you very much.

I am just developing a plug-in only for java editor, which is some thing
like content assistant.
That's to say ,when the java editor is typed some special characters
such as '#',it popups some proposals.
So I need to register the auto-activation-character for such '#' before
the editor is used.
It's a one-time action.
By the way,I override the method:
public char[] getCompletionProposalAutoActivationCharacters().
But it cannot be loaded when I need it.I hava to use a key sequence to
trigger it now.I think it's terrible.
So I want it launched when the java editor is activated.That's the problem.
Thanks again.
Re: Can I customize when the plug-in be loaded? [message #327416 is a reply to message #327371] Fri, 18 April 2008 07:05 Go to previous message
Dani Megert is currently offline Dani MegertFriend
Messages: 3802
Registered: July 2009
Senior Member
dazh wrote:
> Walter Harley 写道:
>> "dazh" <reg.zhuce@163.com> wrote in message
>> news:fu52aa$5v8$1@build.eclipse.org...
>>> For example,can I make it loaded when the editor is activated?
>>> I need to make some configuration before it's used.
>>
>> I'm adding eclipse.platform to the newsgroups list for this message,
>> because what you're asking about is a Platform question, unrelated to
>> JDT.
>>
>> In general, a plug-in will be loaded as soon as a resource within it
>> is accessed, for instance, as soon as a class is loaded. The
>> Eclipse-LazyStart option affects this. You didn't say what the
>> relationship is between the editor you're talking about and the
>> plug-in you're talking about, so it's hard to say more: for instance,
>> are you talking about the plug-in that implements the editor, or some
>> other plug-in?
>>
>> It is also possible to extend the org.eclipse.ui.startup extension
>> point, to force your plug-in to be loaded during Eclipse startup.
>> This is generally a bad idea and almost always unnecessary, and
>> probably not the solution for your problem.
>>
>> Can you say more about the problem you are trying to solve? For
>> instance, what kind of "configuration" are you talking about; does it
>> require UI? Is it a one-time action or does it need to happen every
>> time the plug-in's functionality is used? What kind of functionality
>> does the plug-in provide?
>>
> Thank you very much.
>
> I am just developing a plug-in only for java editor, which is some
> thing like content assistant.
> That's to say ,when the java editor is typed some special characters
> such as '#',it popups some proposals.
> So I need to register the auto-activation-character for such '#'
> before the editor is used.
> It's a one-time action.
> By the way,I override the method:
> public char[] getCompletionProposalAutoActivationCharacters().
Where? And how did you install your processor? The activation characters
are a user preference and hence you should not modify it behind their back.

Dani
> But it cannot be loaded when I need it.I hava to use a key sequence to
> trigger it now.I think it's terrible.
> So I want it launched when the java editor is activated.That's the
> problem.
> Thanks again.
Previous Topic:How to make my editor support resources opened outside of the workspace?
Next Topic:File search & replace programatically?
Goto Forum:
  


Current Time: Sat Jul 27 16:37:37 GMT 2024

Powered by FUDForum. Page generated in 0.03384 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top