Internally setting value of a property [message #614548] |
Thu, 17 August 2006 13:56 |
Eclipse User |
|
|
|
Hello,
Anyone who has an idea how to achieve this simple scenario with JVE.
My Project has a file named input.txt. My composite needs to display
the content of this input.txt file. My composite has a setter, but I
only want to set the relative path of this input.txt instead of the
absolute path. The reason for this is if the user copies this java file
to another project, and the project has input.txt, it will work without
having to change the path in the java file.
So here are the steps I this I need to do to get this scenario work:
1. Find out the current IProject location by looking at the current
editing editor and get the IFileEditorInput.
2. Pass this information to JVE's JVM that interpretes this composite
class (I am not sure how this can be done)...
class Composite
{
private void initialize()
{
MyComposite composite = new MyComposite(this,SWT.NONE);
composite.setInputFile("input.txt");
.......
}
}
|
|
|
Powered by
FUDForum. Page generated in 0.06438 seconds