Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » editor connected to a DB
editor connected to a DB [message #79571] Fri, 20 June 2003 21:33 Go to next message
Eclipse UserFriend
Originally posted by: arturof.netomat.net

Hello,

I want to create an Editor that instead of being registered to edit a
particular file or extension, is registered to edit rows from a particular
table in a relational database.

Does it make sense to do this?

Particularly, what I want to do, is to provide a Multi-Page-Editor type of
interface that is displayed in the EditorArea and is tightly integrated with
the Workbench that allows the user to edit entries in a database.

"To open an editor, the user will typically invoke "Open" on an IFile. When
this action is performed the workbench registry is consulted to determine an
appropriate editor for the file type and then a new instance of the editor
type is created."

Is there such a thing as an RDBMS implementation of IFile? (I would not
expect it, instead, I would expect there to be some sort of RDBMS
implementation of IStorage... but I haven't found one... in any case, it
might not be sufficient, since the Workbench expects an IFile.)

If somebody knows of a plugin that does this already, I would appreciate it
very much if you could point me to it, otherwise, any ideas are appreciated.


Thanks in advance,


--
Arturo Falck
Re: editor connected to a DB [message #79586 is a reply to message #79571] Fri, 20 June 2003 21:35 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: arturof.netomat.net

My appologies... I did find some Database related plugins:
http://eclipse-plugins.2y.net/eclipse/plugins.jsp?category=D atabase

however, any advise is still appreciated.

Thanks

--
Arturo Falck
Re: editor connected to a DB [message #79680 is a reply to message #79586] Sat, 21 June 2003 02:35 Go to previous message
Eclipse UserFriend
Originally posted by: pdrolet.mac.com

Hi,

You need to create a new kind of editor. I am developping this kind of
app at this time. New to Java since dec. 2002 (VFP developper) and to
eclipse since feb. 2003... and working only part time on it - this is
my second job... But I think I am doing fine!


So I read the API and many docs, looked at examples and then created a
class EditorInput that implements IEditorInput and a class FmedxEditor
that extends EditorPart


I created a viewpart with a Tree that is hard coded with the names of
the tables that I want the user be able do modify or view. When he
double-clic an item, it calls EditorInput and this one calls the
appropriate Editor (in my case here FmedxEditor - but I will create
more).


The logic of creating, saving, printing, undoing is located in the
FmedxEditor when specific to the table, and in the EditorInput when
generic. You have to code the getText/setText, load, validation, save
yourself.


The code at this time is not cleaned at all and not generic. It cannot
really be shared and I guess it would be more a waste of time for
somebody that did not write it... And I must admit I do not have the
time to explain it more!


So this is possible.

Patrice Drolet
Previous Topic:ANT question
Next Topic:[ANN] Eclipse Checkstyle Plug-in v3.1.1 released
Goto Forum:
  


Current Time: Sat Oct 19 10:12:18 GMT 2024

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

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

Back to the top