Home » Eclipse Projects » Eclipse Platform » Re: How about a Virtual Resource tree?
Re: How about a Virtual Resource tree? [message #14090] |
Thu, 24 April 2003 11:34  |
Eclipse User |
|
|
|
Originally posted by: b.b.com
I am currently attempting to customize the ResourceNavigator right now and
running into a lot of issues. Mainly these deal with the inconsistant use
(or non-use) of the IAdaptable interface to convert the Objects in the
TreeViewer into IResource objects. I use an object which implements
IAdaptable for the input to my TreeViewer. I also register an
IAdapterFactory with the IAdapterManager that can produce IResources from my
objects. Half of the time the eclipse code just does a instanceof or cast
to an IResource and the other half of the time it checks to see if its an
IAdaptable and tries to get the IResource via getAdapter. Its very
frustrating. For instance, right now I'm having to basically rewrite the
code for some of the ActionGroups, like GotoActionGroup, because its
fillContextMenu uses ResourceSelectionUtil. ResourceSelectionUtil has 2
main methods used for verifying that a selection is a set of IResource
objects. One of these methods checks for IAdaptable, and the other one
doesn't. Typically I would subclass this group and override the
fillContextMenu method, however, all of the Actions in the group are
declared private, and there are no getters/setters for them.
If you are looking for people to help in the process of making the
ResourceNavigator more easily customized by developers, I'd like to be
involved.
Thanks,
Bruce
"Knut Radloff" <knut_radloff@oti.com> wrote in message
news:b7p69k$4kn$1@rogue.oti.com...
> It sounds like you would want to define your own view to represent your
catalog(s). Much like JDT provides a package view to show a
> Java specific representation of the file system.
> You can base your view on the Resource Navigator and provide different
content and label providers, menus, sorting etc. Currently
> the only way to do this is by subclassing from the Navigator.
> I'd be interested in hearing what you end up doing and what aspects of the
Navigator you customized if you go down that route. We
> are investigating making the Navigator more customizable by plug-in
developers.
>
> Knut
> "Colin Kingsbury" <cwkingsbury@earthlink.net> wrote in message
news:b7nkse$679$1@rogue.oti.com...
> > Is there any more dynamic way to work with the resource tree than simply
a
> > static hierarchy of files and directories?
> >
> > Let's say I have ten XML files, each of which represents an item of
> > clothing. XML tag structures within each file will define the type
> > (pants|shirt), gender (male|female), and size (s|m|l) of that item. All
will
> > be stored inside a single directory which can be thought of as a
"catalog."
> >
> > Now when the user opens this catalog up, he ought to be able to see
these
> > data organized in any way he wishes: by gender, then type, then size, or
by
> > type, size, gender, etc etc.
> >
> > Is there a way to build the resource tree view "virtually" based on
> > organizing principles other than simple file hierarchies?
> >
> > Thanks in advance,
> > -cwk.
> >
> >
>
>
|
|
|
Re: How about a Virtual Resource tree? [message #14158 is a reply to message #14090] |
Thu, 24 April 2003 19:01  |
Eclipse User |
|
|
|
Originally posted by: bduncan.visualmining.com
sorry..i had my news client misconfigured, so my name and email
didn't come through on this post.
"b" <b@b.com> wrote in message news:b89hqc$o57$1@rogue.oti.com...
> I am currently attempting to customize the ResourceNavigator right now and
> running into a lot of issues. Mainly these deal with the inconsistant use
> (or non-use) of the IAdaptable interface to convert the Objects in the
> TreeViewer into IResource objects. I use an object which implements
> IAdaptable for the input to my TreeViewer. I also register an
> IAdapterFactory with the IAdapterManager that can produce IResources from
my
> objects. Half of the time the eclipse code just does a instanceof or cast
> to an IResource and the other half of the time it checks to see if its an
> IAdaptable and tries to get the IResource via getAdapter. Its very
> frustrating. For instance, right now I'm having to basically rewrite the
> code for some of the ActionGroups, like GotoActionGroup, because its
> fillContextMenu uses ResourceSelectionUtil. ResourceSelectionUtil has 2
> main methods used for verifying that a selection is a set of IResource
> objects. One of these methods checks for IAdaptable, and the other one
> doesn't. Typically I would subclass this group and override the
> fillContextMenu method, however, all of the Actions in the group are
> declared private, and there are no getters/setters for them.
>
> If you are looking for people to help in the process of making the
> ResourceNavigator more easily customized by developers, I'd like to be
> involved.
>
> Thanks,
> Bruce
>
>
> "Knut Radloff" <knut_radloff@oti.com> wrote in message
> news:b7p69k$4kn$1@rogue.oti.com...
> > It sounds like you would want to define your own view to represent your
> catalog(s). Much like JDT provides a package view to show a
> > Java specific representation of the file system.
> > You can base your view on the Resource Navigator and provide different
> content and label providers, menus, sorting etc. Currently
> > the only way to do this is by subclassing from the Navigator.
> > I'd be interested in hearing what you end up doing and what aspects of
the
> Navigator you customized if you go down that route. We
> > are investigating making the Navigator more customizable by plug-in
> developers.
> >
> > Knut
> > "Colin Kingsbury" <cwkingsbury@earthlink.net> wrote in message
> news:b7nkse$679$1@rogue.oti.com...
> > > Is there any more dynamic way to work with the resource tree than
simply
> a
> > > static hierarchy of files and directories?
> > >
> > > Let's say I have ten XML files, each of which represents an item of
> > > clothing. XML tag structures within each file will define the type
> > > (pants|shirt), gender (male|female), and size (s|m|l) of that item.
All
> will
> > > be stored inside a single directory which can be thought of as a
> "catalog."
> > >
> > > Now when the user opens this catalog up, he ought to be able to see
> these
> > > data organized in any way he wishes: by gender, then type, then size,
or
> by
> > > type, size, gender, etc etc.
> > >
> > > Is there a way to build the resource tree view "virtually" based on
> > > organizing principles other than simple file hierarchies?
> > >
> > > Thanks in advance,
> > > -cwk.
> > >
> > >
> >
> >
>
>
|
|
|
Goto Forum:
Current Time: Fri Apr 25 00:00:37 EDT 2025
Powered by FUDForum. Page generated in 0.02377 seconds
|