Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Resource Change Listener via XML?
Resource Change Listener via XML? [message #333492] Mon, 15 December 2008 17:01 Go to next message
Adam Neal is currently offline Adam NealFriend
Messages: 7
Registered: July 2009
Junior Member
Hi,

I'm writing an IResourceChangeListener and I'm curious if there is an
extension point that I can use to register my listener? So far I haven't
found one and I'm forced to use:
ResourcesPlugin.getWorkspace().addResourceChangeListener(... )

Thanks,
Adam
Re: Resource Change Listener via XML? [message #333493 is a reply to message #333492] Mon, 15 December 2008 17:34 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33264
Registered: July 2009
Senior Member
Adam,

I don't think there is. Isn't it sufficient to do this only after your
plugin starts?


Adam Neal wrote:
> Hi,
>
> I'm writing an IResourceChangeListener and I'm curious if there is an
> extension point that I can use to register my listener? So far I haven't
> found one and I'm forced to use:
> ResourcesPlugin.getWorkspace().addResourceChangeListener(... )
>
> Thanks,
> Adam
>
>
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Resource Change Listener via XML? [message #333495 is a reply to message #333493] Mon, 15 December 2008 18:57 Go to previous messageGo to next message
Adam Neal is currently offline Adam NealFriend
Messages: 7
Registered: July 2009
Junior Member
Hi Ed, thanks for the quick reply.

You've metioned the exact problem I'm trying to get around :) The fact that
that my plugin isn't loaded yet. My resource listener has isolated
dependencies so I could put it into the exceptions list. But I'm looking
for a way to load my resource listener in the first place as my plugin could
remain unloaded for who knows how long...

-
Adam

"Ed Merks" <Ed.Merks@gmail.com> wrote in message
news:gi64g5$lpd$2@build.eclipse.org...
> Adam,
>
> I don't think there is. Isn't it sufficient to do this only after your
> plugin starts?
>
>
> Adam Neal wrote:
>> Hi,
>>
>> I'm writing an IResourceChangeListener and I'm curious if there is an
>> extension point that I can use to register my listener? So far I haven't
>> found one and I'm forced to use:
>> ResourcesPlugin.getWorkspace().addResourceChangeListener(... )
>>
>> Thanks,
>> Adam
>>
>>
>>
Re: Resource Change Listener via XML? [message #333496 is a reply to message #333495] Mon, 15 December 2008 19:07 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: eclipse-news.rizzoweb.com

On 12/15/2008 1:57 PM, Adam Neal wrote:
> Hi Ed, thanks for the quick reply.
>
> You've metioned the exact problem I'm trying to get around :) The fact that
> that my plugin isn't loaded yet. My resource listener has isolated
> dependencies so I could put it into the exceptions list. But I'm looking
> for a way to load my resource listener in the first place as my plugin could
> remain unloaded for who knows how long...

Have you read this, which talks about Save Participants to address this
problem:
http://www.eclipse.org/articles/Article-Resource-deltas/reso urce-deltas.html

Hope this helps,
Eric



> "Ed Merks"<Ed.Merks@gmail.com> wrote in message
> news:gi64g5$lpd$2@build.eclipse.org...
>> Adam,
>>
>> I don't think there is. Isn't it sufficient to do this only after your
>> plugin starts?
>>
>>
>> Adam Neal wrote:
>>> Hi,
>>>
>>> I'm writing an IResourceChangeListener and I'm curious if there is an
>>> extension point that I can use to register my listener? So far I haven't
>>> found one and I'm forced to use:
>>> ResourcesPlugin.getWorkspace().addResourceChangeListener(... )
>>>
>>> Thanks,
>>> Adam
>>>
>>>
>>>
>
>
Re: Resource Change Listener via XML? [message #333500 is a reply to message #333495] Mon, 15 December 2008 19:45 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33264
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------090800080805070505010404
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Adam,

I hate to tell people about early start plugins because those are
generally a nasty thing. Everyone likes to think their plugin is so
important it must start right away... Maybe it would be better to ask
what your listener is doing first...


Adam Neal wrote:
> Hi Ed, thanks for the quick reply.
>
> You've metioned the exact problem I'm trying to get around :) The fact that
> that my plugin isn't loaded yet. My resource listener has isolated
> dependencies so I could put it into the exceptions list. But I'm looking
> for a way to load my resource listener in the first place as my plugin could
> remain unloaded for who knows how long...
>
> -
> Adam
>
> "Ed Merks" <Ed.Merks@gmail.com> wrote in message
> news:gi64g5$lpd$2@build.eclipse.org...
>
>> Adam,
>>
>> I don't think there is. Isn't it sufficient to do this only after your
>> plugin starts?
>>
>>
>> Adam Neal wrote:
>>
>>> Hi,
>>>
>>> I'm writing an IResourceChangeListener and I'm curious if there is an
>>> extension point that I can use to register my listener? So far I haven't
>>> found one and I'm forced to use:
>>> ResourcesPlugin.getWorkspace().addResourceChangeListener(... )
>>>
>>> Thanks,
>>> Adam
>>>
>>>
>>>
>>>
>
>
>

--------------090800080805070505010404
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Adam,<br>
<br>
I hate to tell people about early start plugins because those are
generally a nasty thing.&nbsp; Everyone likes to think their plugin is so
important it must start right away...&nbsp; Maybe it would be better to ask
what your listener is doing first...<br>
<br>
<br>
Adam Neal wrote:
<blockquote cite="mid:gi69am$5c2$1@build.eclipse.org" type="cite">
<pre wrap="">Hi Ed, thanks for the quick reply.

You've metioned the exact problem I'm trying to get around :) The fact that
that my plugin isn't loaded yet. My resource listener has isolated
dependencies so I could put it into the exceptions list. But I'm looking
for a way to load my resource listener in the first place as my plugin could
remain unloaded for who knows how long...

-
Adam

"Ed Merks" <a class="moz-txt-link-rfc2396E" href="mailto:Ed.Merks@gmail.com">&lt;Ed.Merks@gmail.com&gt;</a> wrote in message
<a class="moz-txt-link-freetext" href="news:gi64g5$lpd$2@build.eclipse.org">news:gi64g5$lpd$2@build.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Adam,

I don't think there is. Isn't it sufficient to do this only after your
plugin starts?


Adam Neal wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi,

I'm writing an IResourceChangeListener and I'm curious if there is an
extension point that I can use to register my listener? So far I haven't
found one and I'm forced to use:
ResourcesPlugin.getWorkspace().addResourceChangeListener(... )

Thanks,
Adam



</pre>
</blockquote>
</blockquote>
<pre wrap=""><!---->

</pre>
</blockquote>
</body>
</html>

--------------090800080805070505010404--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Resource Change Listener via XML? [message #333517 is a reply to message #333500] Tue, 16 December 2008 13:17 Go to previous messageGo to next message
Adam Neal is currently offline Adam NealFriend
Messages: 7
Registered: July 2009
Junior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0034_01C95F56.CF504420
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi,

The part of my plugin that I want running right away is a combination =
of:
1) Document Listener
2) ResourceChangeListener

My code needs to listen to changes in generated source files within =
specific regions (using #1), and than copy those changes to their model =
once the user preforms a save on the file (#2).
Using the case where a source file is already open when the workspace is =
first started up, I need to register a document listener immediately =
incase they decide to change that file and save it before doing anything =
else.

Note: I looked into the ISaveParticipant, but if I remember correctly, =
my class didn't get instantiated until the actual first save occured. =
But this means that my document listener was not yet inplace to =
determine if meaningful regions of the code were affected.

That early start looks promising (I assume you're talking about the =
org.eclipse.ui.startup extension point) So as long as my listener =
classes exist in the exceptions list of the plugin, I should be able to =
start my listeners without force loading the rest of the plugin...

Thanks for your suggestions Ed and Eric,
Adam
"Ed Merks" <Ed.Merks@gmail.com> wrote in message =
news:gi6c49$8e4$3@build.eclipse.org...
Adam,

I hate to tell people about early start plugins because those are =
generally a nasty thing. Everyone likes to think their plugin is so =
important it must start right away... Maybe it would be better to ask =
what your listener is doing first...


Adam Neal wrote:=20
Hi Ed, thanks for the quick reply.

You've metioned the exact problem I'm trying to get around :) The fact =
that=20
that my plugin isn't loaded yet. My resource listener has isolated=20
dependencies so I could put it into the exceptions list. But I'm =
looking=20
for a way to load my resource listener in the first place as my plugin =
could=20
remain unloaded for who knows how long...

-
Adam

"Ed Merks" <Ed.Merks@gmail.com> wrote in message=20
news:gi64g5$lpd$2@build.eclipse.org...
Adam,

I don't think there is. Isn't it sufficient to do this only after your =

plugin starts?


Adam Neal wrote:
Hi,

I'm writing an IResourceChangeListener and I'm curious if there is an=20
extension point that I can use to register my listener? So far I =
haven't=20
found one and I'm forced to use:
ResourcesPlugin.getWorkspace().addResourceChangeListener(... )

Thanks,
Adam



=20


------=_NextPart_000_0034_01C95F56.CF504420
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type =
content=3Dtext/html;charset=3DISO-8859-1>
<META content=3D"MSHTML 6.00.6000.16735" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY text=3D#000000 bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hi,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>The part of my plugin that I want =
running right=20
away is a combination of:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>1) Document Listener</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>2) ResourceChangeListener</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My code needs to listen to changes in =
generated=20
source files within specific regions (using #1), and than copy those =
changes to=20
their model once the user preforms a save on the file (#2).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Using the case where a source file is =
already open=20
when the workspace is first started up, I need to register a document =
listener=20
immediately incase they decide to change that file and save it before =
doing=20
anything else.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Note: I looked into the =
ISaveParticipant,=20
but&nbsp;if I remember correctly,&nbsp;my class didn't get instantiated =
until=20
the actual first save occured.&nbsp; But this means that my document =
listener=20
was not yet inplace to determine if meaningful regions of the code were=20
affected.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>That early start looks promising&nbsp; =
(I assume=20
you're talking about the&nbsp;<FONT face=3D"Times New Roman"=20
size=3D3>org.eclipse.ui.startup extension point)</FONT> So as long as my =
listener=20
classes exist in the exceptions list of the plugin, I should be able=20
to&nbsp;start my listeners without force loading the rest of the=20
plugin...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thanks for your suggestions Ed and=20
Eric,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Adam</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A=20
href=3D"mailto:Ed.Merks@gmail.com">Ed.Merks@gmail.com</A>&gt; wrote in =
message=20
<A=20
=
href=3D"news:gi6c49$8e4$3@build.eclipse.org">news:gi6c49$8e4$3@build.ecli=
pse.org</A>...</DIV>Adam,<BR><BR>I=20
hate to tell people about early start plugins because those are =
generally a=20
nasty thing.&nbsp; Everyone likes to think their plugin is so =
important it=20
must start right away...&nbsp; Maybe it would be better to ask what =
your=20
listener is doing first...<BR><BR><BR>Adam Neal wrote:=20
<BLOCKQUOTE cite=3Dmid:gi69am$5c2$1@build.eclipse.org =
type=3D"cite"><PRE wrap=3D"">Hi Ed, thanks for the quick reply.

You've metioned the exact problem I'm trying to get around :) The fact =
that=20
that my plugin isn't loaded yet. My resource listener has isolated=20
dependencies so I could put it into the exceptions list. But I'm =
looking=20
for a way to load my resource listener in the first place as my plugin =
could=20
remain unloaded for who knows how long...

-
Adam

"Ed Merks" <A class=3Dmoz-txt-link-rfc2396E =
href=3D"mailto:Ed.Merks@gmail.com">&lt;Ed.Merks@gmail.com&gt;</A> wrote =
in message=20
<A class=3Dmoz-txt-link-freetext =
href=3D"news:gi64g5$lpd$2@build.eclipse.org">news:gi64g5$lpd$2@build.ecli=
pse.org</A>...
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Adam,

I don't think there is. Isn't it sufficient to do this only after your =

plugin starts?


Adam Neal wrote:
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi,

I'm writing an IResourceChangeListener and I'm curious if there is an=20
extension point that I can use to register my listener? So far I =
haven't=20
found one and I'm forced to use:
ResourcesPlugin.getWorkspace().addResourceChangeListener(... )

Thanks,
Adam



</PRE></BLOCKQUOTE></BLOCKQUOTE><PRE wrap=3D""><!---->

</PRE></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0034_01C95F56.CF504420--
Re: Resource Change Listener via XML? [message #333520 is a reply to message #333517] Tue, 16 December 2008 14:00 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33264
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------020407070004050008010104
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Adam,

Comments below.

Adam Neal wrote:
> Hi,
>
> The part of my plugin that I want running right away is a combination of:
> 1) Document Listener
> 2) ResourceChangeListener
>
> My code needs to listen to changes in generated source files within
> specific regions (using #1), and than copy those changes to their
> model once the user preforms a save on the file (#2).
It sounds more like a builder.
> Using the case where a source file is already open when the workspace
> is first started up, I need to register a document listener
> immediately incase they decide to change that file and save it before
> doing anything else.
>
> Note: I looked into the ISaveParticipant, but if I remember
> correctly, my class didn't get instantiated until the actual first
> save occured. But this means that my document listener was not yet
> inplace to determine if meaningful regions of the code were affected.
What you're describing sounds extremely invasive and I can't imagine
this type of approach scaling well if many people decide to take this
kind of approach.

Are you assuming that no one will ever change a file direct in the file
system and then refresh the workspace?
>
> That early start looks promising (I assume you're talking about
> the org.eclipse.ui.startup extension point) So as long as my listener
> classes exist in the exceptions list of the plugin, I should be able
> to start my listeners without force loading the rest of the plugin...
I feel like you have a loaded gun though. I highly recommend you ask
around internally for design advice...
>
> Thanks for your suggestions Ed and Eric,
> Adam
>
> "Ed Merks" <Ed.Merks@gmail.com <mailto:Ed.Merks@gmail.com>> wrote
> in message news:gi6c49$8e4$3@build.eclipse.org...
> Adam,
>
> I hate to tell people about early start plugins because those are
> generally a nasty thing. Everyone likes to think their plugin is
> so important it must start right away... Maybe it would be better
> to ask what your listener is doing first...
>
>
> Adam Neal wrote:
>> Hi Ed, thanks for the quick reply.
>>
>> You've metioned the exact problem I'm trying to get around :) The fact that
>> that my plugin isn't loaded yet. My resource listener has isolated
>> dependencies so I could put it into the exceptions list. But I'm looking
>> for a way to load my resource listener in the first place as my plugin could
>> remain unloaded for who knows how long...
>>
>> -
>> Adam
>>
>> "Ed Merks" <Ed.Merks@gmail.com> wrote in message
>> news:gi64g5$lpd$2@build.eclipse.org...
>>
>>> Adam,
>>>
>>> I don't think there is. Isn't it sufficient to do this only after your
>>> plugin starts?
>>>
>>>
>>> Adam Neal wrote:
>>>
>>>> Hi,
>>>>
>>>> I'm writing an IResourceChangeListener and I'm curious if there is an
>>>> extension point that I can use to register my listener? So far I haven't
>>>> found one and I'm forced to use:
>>>> ResourcesPlugin.getWorkspace().addResourceChangeListener(... )
>>>>
>>>> Thanks,
>>>> Adam
>>>>
>>>>
>>>>
>>>>
>>
>>
>>
>

--------------020407070004050008010104
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Adam,<br>
<br>
Comments below.<br>
<br>
Adam Neal wrote:
<blockquote cite="mid:gi89q9$m67$1@build.eclipse.org" type="cite">
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
<meta content="MSHTML 6.00.6000.16735" name="GENERATOR">
<style></style>
<div><font face="Arial" size="2">Hi,</font></div>
<div>&nbsp;</div>
<div><font face="Arial" size="2">The part of my plugin that I want
running right away is a combination of:</font></div>
<div><font face="Arial" size="2">1) Document Listener</font></div>
<div><font face="Arial" size="2">2) ResourceChangeListener</font></div>
<div>&nbsp;</div>
<div><font face="Arial" size="2">My code needs to listen to changes
in generated source files within specific regions (using #1), and than
copy those changes to their model once the user preforms a save on the
file (#2).</font></div>
</blockquote>
It sounds more like a builder.<br>
<blockquote cite="mid:gi89q9$m67$1@build.eclipse.org" type="cite">
<div><font face="Arial" size="2">Using the case where a source file
is already open when the workspace is first started up, I need to
register a document listener immediately incase they decide to change
that file and save it before doing anything else.</font></div>
<div>&nbsp;</div>
<div><font face="Arial" size="2">Note: I looked into the
ISaveParticipant, but&nbsp;if I remember correctly,&nbsp;my class didn't get
instantiated until the actual first save occured.&nbsp; But this means that
my document listener was not yet inplace to determine if meaningful
regions of the code were affected.</font></div>
</blockquote>
What you're describing sounds extremely invasive and I can't imagine
this type of approach scaling well if many people decide to take this
kind of approach.<br>
<br>
Are you assuming that no one will ever change a file direct in the file
system and then refresh the workspace?&nbsp; <br>
<blockquote cite="mid:gi89q9$m67$1@build.eclipse.org" type="cite">
<div>&nbsp;</div>
<div><font face="Arial" size="2">That early start looks promising&nbsp; (I
assume you're talking about the&nbsp;<font face="Times New Roman" size="3">org.eclipse.ui.startup
extension point)</font> So as long as my listener classes exist in the
exceptions list of the plugin, I should be able to&nbsp;start my listeners
without force loading the rest of the plugin...</font></div>
</blockquote>
I feel like you have a loaded gun though.&nbsp; I highly recommend you ask
around internally for design advice...<br>
<blockquote cite="mid:gi89q9$m67$1@build.eclipse.org" type="cite">
<div>&nbsp;</div>
<div><font face="Arial" size="2">Thanks for your suggestions Ed and
Eric,</font></div>
<div><font face="Arial" size="2">Adam</font></div>
<blockquote dir="ltr"
style="border-left: 2px solid rgb(0, 0, 0); padding-right: 0px; padding-left: 5px; margin-left: 5px; margin-right: 0px;">
<div>"Ed Merks" &lt;<a moz-do-not-send="true"
href="mailto:Ed.Merks@gmail.com">Ed.Merks@gmail.com</a>&gt; wrote in
message <a moz-do-not-send="true"
href="news:gi6c49$8e4$3@build.eclipse.org">news:gi6c49$8e4$3@build.eclipse.org</a>...</div>
Adam,<br>
<br>
I hate to tell people about early start plugins because those are
generally a nasty thing.&nbsp; Everyone likes to think their plugin is so
important it must start right away...&nbsp; Maybe it would be better to ask
what your listener is doing first...<br>
<br>
<br>
Adam Neal wrote:
<blockquote cite="mid:gi69am$5c2$1@build.eclipse.org" type="cite">
<pre wrap="">Hi Ed, thanks for the quick reply.

You've metioned the exact problem I'm trying to get around :) The fact that
that my plugin isn't loaded yet. My resource listener has isolated
dependencies so I could put it into the exceptions list. But I'm looking
for a way to load my resource listener in the first place as my plugin could
remain unloaded for who knows how long...

-
Adam

"Ed Merks" <a moz-do-not-send="true" class="moz-txt-link-rfc2396E"
href="mailto:Ed.Merks@gmail.com">&lt;Ed.Merks@gmail.com&gt;</a> wrote in message
<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="news:gi64g5$lpd$2@build.eclipse.org">news:gi64g5$lpd$2@build.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Adam,

I don't think there is. Isn't it sufficient to do this only after your
plugin starts?


Adam Neal wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi,

I'm writing an IResourceChangeListener and I'm curious if there is an
extension point that I can use to register my listener? So far I haven't
found one and I'm forced to use:
ResourcesPlugin.getWorkspace().addResourceChangeListener(... )

Thanks,
Adam



</pre>
</blockquote>
</blockquote>
<pre wrap=""><!---->

</pre>
</blockquote>
</blockquote>
</blockquote>
</body>
</html>

--------------020407070004050008010104--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Resource Change Listener via XML? [message #333728 is a reply to message #333520] Mon, 29 December 2008 16:53 Go to previous message
Adam Neal is currently offline Adam NealFriend
Messages: 40
Registered: July 2009
Member
Hi again,

Upon further investigation, I've decided to move away from the documentation
listener. I will now only use a resource listener. However, I'm still faced
with the same problem of delayed starting.

The documented way I've found to do this is to create an ISaveParticipant as
well and to basically get the resource delta's of the workspace when my
plug-in actually loads.

(As Eric Rizzo point out to me:
http://www.eclipse.org/articles/Article-Resource-deltas/reso urce-deltas.html
- Thanks Eric)

Please correct me if I'm wrong, but how does this help if the user has not
done the 'special' action that will actually load my plug-in?
Meaning, currently, my plug-in is only being loaded when a user 'opens' a
specific element. If the user does not open this element type then the
plug-in may never be loaded.

If my plug-in is never loaded, then there is no chance for me to add my
ISaveParticipant, or my ResourceChangeListener. I must be missing
something. As far as I see, the user could potentially open the workbench,
make changes to a resource, save it, and close down the workbench, and I
would never be notified, and I doubt I would ever see those notifications
again even if I was able to load my ISaveParticipant during the next
session...

I looked into the EarlyStartup, but ideally I would avoid this as it would
cause many dependent plugins to be loaded unnecessarily. I just want to be
loaded in time to handle a resource save.

Any ideas? Or do I need become a non-lazy loaded plug-in?

Thanks,

Adam
Previous Topic:how to read my plugin dependency libraries
Next Topic:Memory consumption of virtual TableViewers
Goto Forum:
  


Current Time: Sun Dec 22 06:19:52 GMT 2024

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

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

Back to the top