I'm new to plug-in development. I have a new project which I think lends itself to being a plug-in rather than a stand-alone tool. I'd appreciate input from anyone who can comment on the viability of what I propose to do. So, here goes....
I'm working on an abstract approach to modelling certain types of software. The model is stored in an .xml file and is visualised in a graphical UML-like way. (The visualization is similar to a UML class diagram but I am NOT implementing yet another UML visualization tool!.)
Capability 1: Associate a particular .XML file (extension can be specific) with a visual renderer which can parse the file and provide an interactive view of it as a Tab in IntelliJ.
What is important here is the association. I'm already working on the visualization component itself but currently as a stand-alone Swing application and not a plug-in.
Editing the model via the visualization results in changes to code generated from the model.
Capability 2: Have the component which is visualizing the model .xml file write code to files which are part of the IntelliJ source tree, which might or might not already be open in IntelliJ.
The generated files are not intended to be hand-edited, so overwriting changes is fine. I can write the code generation, but I need to get a handle to a FileOutputStream corresponding to, say, "com/robin/Employee.java". This might be interesting where there are a number of source paths defined in the IntelliJ project, and where a new file must be created and an appropriate source path chosen, etc. etc.
Some elements of the model represent "placeholders" for custom coding (the hand-written stuff) which takes place in subclasses of the generated classes.
Capability 3: When specific UI gestures are given to the visualization component, ask IntelliJ to go to (or open) the Editor tab for a class (e.g. com.robin.EmployeeImpl) and go to the line at which a specified method is declared.
This is essentially for ease of navigation - select a behavioural item in the visual model and have the code editor go to the corresponding method declaration, etc. etc.
So, those are the 3 capabilities I think I will need. The visualization itself is going well and the code-generation is old-hat. If I can do these three, then I can stop writing File->Open actions and concentrate on the visualization component itself.
Thanks in advance, Robin.