sharonfeldman / workspacemechanic

Automatically exported from code.google.com/p/workspacemechanic
0 stars 0 forks source link

Allow extensions to extend PreferenceFileTaskScanner #115

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Writing a custom TaskScanner to read Preferences

Attached patch:

- Removes 'final' from PreferenceFileTaskScanner to allow subclassing
- Exports the PreferenceFileTaskScanner package at the OSGi level
- Uses the (public) interface of IResourceTaskProvider instead of impl in 
IResourceTaskReference

Original issue reported on code.google.com by markus.k...@gmail.com on 3 Apr 2014 at 6:00

Attachments:

GoogleCodeExporter commented 8 years ago
What feature does this provide?

Also, I prefer to accept patches via git: see 
https://code.google.com/a/eclipselabs.org/p/workspacemechanic/wiki/DeveloperGuid
e, but don't bother yet. Let's discuss the need, first.

Original comment by konigsb...@gmail.com on 3 Apr 2014 at 12:02

GoogleCodeExporter commented 8 years ago
A custom task scanner (for which neither URI nor File/Directory) works, wants 
to provide additional tasks. Technically it is basically an in-memory archive 
of a bunch of task files. Thus, PreferenceFileTaskScanner is a perfect fit in 
terms of functionality.

Original comment by markus.k...@gmail.com on 3 Apr 2014 at 4:41

GoogleCodeExporter commented 8 years ago
So how do we do this without exposing the internal package and extending 
something which  isn't designed to be extended?

Original comment by konigsb...@gmail.com on 4 Apr 2014 at 11:48

GoogleCodeExporter commented 8 years ago
What about splitting PreferenceFileTaskScanner into two classes? An Impl in the 
current private package and a abstract base in a public one.

Original comment by markus.k...@gmail.com on 5 Apr 2014 at 6:30

GoogleCodeExporter commented 8 years ago
Seems reasonable, but since I still don't know what parts you care about I 
can't be sure. Do you have an example of the extension that you can share?

Original comment by konigsb...@gmail.com on 5 Apr 2014 at 1:27

GoogleCodeExporter commented 8 years ago
In my derived class I just override scan(TaskCollector) and re-use everything 
else from PreferenceFileTaskScanner. 

Original comment by markus.k...@gmail.com on 7 Apr 2014 at 7:00

GoogleCodeExporter commented 8 years ago
Could you possibly give me more information? Can you share the code? I want to 
help you, but I need more information.

Original comment by konigsb...@gmail.com on 7 Apr 2014 at 3:04

GoogleCodeExporter commented 8 years ago
Unfortunately I cannot share the code at this point. What information - besides 
code - exactly do you need?

Original comment by markus.k...@gmail.com on 10 Apr 2014 at 5:10

GoogleCodeExporter commented 8 years ago
This conversation is suffering from too many days-long lags. Would you like to 
set up a video conference by skype or hangouts? I'll drop you an email.

Original comment by konigsb...@gmail.com on 11 Apr 2014 at 11:17

GoogleCodeExporter commented 8 years ago
For anyone else listening in, I've proposed a change that produces a new 
extension point. It should work for Markus' use case. Version 0.3.7, in the 
testing repository, contains the proposed extension point.

Original comment by konigsb...@gmail.com on 13 Apr 2014 at 4:15

GoogleCodeExporter commented 8 years ago
resourcetaskproviders extension point is published.

Original comment by konigsb...@gmail.com on 22 Apr 2014 at 2:15