Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » open editor with java objects
open editor with java objects [message #759874] Wed, 30 November 2011 12:31 Go to next message
M Dahlem is currently offline M DahlemFriend
Messages: 6
Registered: November 2011
Junior Member
Hi!

I try to set some fields of java objects (not Files) in existing editors and save them back in this data structure. Is there a way to do this?

The best I reached, was opening an editor with an extended IStorageEditorInput like shown in this post: hxxp://blog.eclipse-tips.com/2008/06/opening-editor-without-ifile.html. But there are two problems with this idea:



  1. When opening this EditorInput with an StructuredEditor (i.e. css editor), the outline, code hightlighting, adding comment from the context menu and so on do not work, but no error is shown in the command line.
  2. The other problem is the save-operation. How can I catch the editor-internal operation and override it with my own operation?


I hope you understand the problems and have an idea how to fix them.
Perhabs there exists another idea how to set and get fields of a java objects in an editor.
Re: open editor with java objects [message #759920 is a reply to message #759874] Wed, 30 November 2011 15:11 Go to previous message
M Dahlem is currently offline M DahlemFriend
Messages: 6
Registered: November 2011
Junior Member
I found out, that it should work with document providers. I can use a provider to open a document depending on the myEditorInput with a given editor and handle the partinioning of the blocks with the help of line counters and a modification listener.

But one thing don't work properply:

How can I set the contenttype (extensionpoint?) for objects, that are not files and therefore have no file extension?

[Updated on: Wed, 30 November 2011 15:40]

Report message to a moderator

Previous Topic:Is the proper way to structure / develop my RCP App?
Next Topic:JVM crashed sometimes on ubuntu 64bit
Goto Forum:
  


Current Time: Thu Apr 25 01:31:00 GMT 2024

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

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

Back to the top