← Revision 1 as of 2005-07-22 05:33:17 →
Size: 2439
Comment:
|
Size: 2771
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 1: | Line 1: |
'''How to set up Eclipse to develop Cytoscape plugins (draft)''' | ~+'''How to set up Eclipse to develop Cytoscape plugins (draft)'''+~ |
Line 3: | Line 3: |
''Márcio Rosa da Silva'' | ''Márcio Rosa da Silva'' (MarcioSilva) |
Line 9: | Line 9: |
Line 11: | Line 10: |
After some time trying to do this, I think I got [http://www.eclipse.org Eclipse] to work for me (instead of against me :-) ) so I think I should share this experience with others. This document assumes that you have [http://www.eclipse.org Eclipse] installed and running. |
This document is an introduction on how to set up [http://www.eclipse.org Eclipse] to develop Cytoscape plugins. It is assumed that you have Eclipse installed and running. |
Line 19: | Line 14: |
Line 21: | Line 15: |
[http://csresources.sourceforge.net/images/eclipse1.png] |
[http://csresources.sourceforge.net/docs/images/eclipse1.png] |
Line 29: | Line 18: |
* Then select {{{Java Build Path}}} on the left panel and {{{Libraries}}} in the tabs on the right panel, then choose {{{Add External JARs...}}} * Add {{{cytoscape.jar}}} from the main Cytoscape folder and all the {{{.jar}}} files from the {{{lib/}}} folder inside the main Cytoscape folder. (you need 2 steps to do this, one for cytoscape.jar and another for the other .jar's) [http://csresources.sourceforge.net/docs/images/eclipse2.png] |
|
Line 30: | Line 22: |
* Then select {{{Java Build Path}}} on the left panel and {{{Libraries}}} in the tabs on the right panel, then choose {{{Add External JARs...}}} * Add {{{cytoscape.jar}}} from the main Cytoscape folder and all the {{{.jar}}} files from the {{{lib/}}} folder inside the main Cytoscape folder. (you need 2 steps to do this, one for cytoscape.jar and another for the other .jar's) http://csresources.sourceforge.net/images/eclipse2.png ||[http://csresources.sourceforge.net/images/eclipse3.png]|| |
[http://csresources.sourceforge.net/docs/images/eclipse3.png] |
Line 49: | Line 25: |
* Now, create your plugin! You can find some help at the ["Developer Homepage"]. == Running the plugin == * To Run your plugin, select {{{Run->Open Run Dialog...}}} in Eclipse and click {{{New}}} (at the bottom-left part of the dialog) to create the settings to run your plugin . * Put a {{{Name}}} for the {{{Run Target}}} and choose {{{cytoscape.CyMain}}} as the {{{Main class}}}. [http://csresources.sourceforge.net/docs/images/eclipse4.png] |
|
Line 50: | Line 31: |
* Now, create your plugin! You can find some help at [http://cytoscape.org/developer.php this page] from [http://cytoscape.org Cytoscape] website. == Running the plugin == * To Run your plugin, select {{{Run->Run...}}} in Eclipse and click {{{New}}} (at the bottom-left part of the dialog) to create the settings to run your plugin . * Put a {{{Name}}} for the {{{Run Target}}} and choose {{{cytoscape.CyMain}}} as the {{{Main class}}}. ||[http://csresources.sourceforge.net/images/eclipse4.png]|| * On the next tab ({{{(x)= Arguments}}}) put the path to your Cytoscape's plugins folder as program arguments (you can add other arguments here, like preload your network, node/edge atributes, expression data, etc. See the Cytoscape's [http://cytoscape.org/manual/Cytoscape2_1Manual.pdf manual] for more information on the available command line options. ||[http://csresources.sourceforge.net/images/eclipse5.png]|| |
* On the next tab ({{{(x)= Arguments}}}) put the path to your Cytoscape's plugins folder as program arguments (you can add other arguments here, like preload your network, node/edge atributes, expression data, etc. See the Cytoscape's [http://cytoscape.org/manual/Cytoscape2_1Manual.pdf manual] for more information on the available command line options. [http://csresources.sourceforge.net/docs/images/eclipse5.png] |
Line 76: | Line 35: |
'''Note:''' Before running the plugin for the first time, you may need to put a {{{.jar}}} of the plugin in some place Cytoscape will search for plugins (e.g. the {{{plugins/}}} folder inside the Cytoscape installarion folder). Otherwise, Cytoscape will not find your plugin. You don't need to generate the {{{.jar}}} for every run, only the first time. Cytoscape only needs to know your plugin is there, but the actual code will be run from the files in your Eclipse project. | |
Line 77: | Line 37: |
---- Category: EclipseAndCytoscapeDevelopment |
How to set up Eclipse to develop Cytoscape plugins (draft)
Márcio Rosa da Silva (MarcioSilva)
June 2005
Introduction
This document is an introduction on how to set up [http://www.eclipse.org Eclipse] to develop Cytoscape plugins. It is assumed that you have Eclipse installed and running.
Creating the project
Go to File->New->Project... then select Java Project.
On the next dialog, put a name for your project and click Finish.
[http://csresources.sourceforge.net/docs/images/eclipse1.png]
Right click the new created project in the Package Explorer and select Properties
Then select Java Build Path on the left panel and Libraries in the tabs on the right panel, then choose Add External JARs...
Add cytoscape.jar from the main Cytoscape folder and all the .jar files from the lib/ folder inside the main Cytoscape folder. (you need 2 steps to do this, one for cytoscape.jar and another for the other .jar's)
[http://csresources.sourceforge.net/docs/images/eclipse2.png]
[http://csresources.sourceforge.net/docs/images/eclipse3.png]
Apply your changes
- Now, create your plugin! You can find some help at the ["Developer Homepage"].
Running the plugin
To Run your plugin, select Run->Open Run Dialog... in Eclipse and click New (at the bottom-left part of the dialog) to create the settings to run your plugin .
Put a Name for the Run Target and choose cytoscape.CyMain as the Main class.
[http://csresources.sourceforge.net/docs/images/eclipse4.png]
On the next tab ((x)= Arguments) put the path to your Cytoscape's plugins folder as program arguments (you can add other arguments here, like preload your network, node/edge atributes, expression data, etc. See the Cytoscape's [http://cytoscape.org/manual/Cytoscape2_1Manual.pdf manual] for more information on the available command line options.
[http://csresources.sourceforge.net/docs/images/eclipse5.png]
- Now you can run your plugin!
Note: Before running the plugin for the first time, you may need to put a .jar of the plugin in some place Cytoscape will search for plugins (e.g. the plugins/ folder inside the Cytoscape installarion folder). Otherwise, Cytoscape will not find your plugin. You don't need to generate the .jar for every run, only the first time. Cytoscape only needs to know your plugin is there, but the actual code will be run from the files in your Eclipse project.
Category: EclipseAndCytoscapeDevelopment