Hopefully this is clearer: I wish to store a JavaDoc in the plugin and be able to access it from the Editor, like with a normal javadoc. Similar to the help in the plugin.
- Package the javadoc files inside your plugin jar - Somehow find or create the library with the classes described by the javadoc - Call PathUtil.getJarPathForClass() to find the plugin jar from the plugin code - Call JarFileSystem.getInstance().getJarRootForLocalFile(LocalFileSystem.findFileByPath(pluginJar)) to find the root of your plugin JAR in the IDEA VFS - Call jarRoot.findFileByRelativePath() to find the javadocs inside your plugin jar - Use Library.getModifiableModel().addRoot(javadocRoot, JavadocOrderRootType.getInstance() to attach the javadocs to the library - Call Library.ModifiableModel.commit() to save your changes
Sorry about that Dmitry.
Hopefully this is clearer:
I wish to store a JavaDoc in the plugin and be able to access it from the Editor, like with a normal javadoc.
Similar to the help in the plugin.
-- Dmitry Jemerov Development Lead JetBrains, Inc. http://www.jetbrains.com/ "Develop with Pleasure!"
Everything is coming along quite well. The javadoc and classes are loaded in the jar file. The classes are functioning correctly with the GUI. The javadoc is successfully found in the jar and can be utilised in the Library.
So now we are at the point where your assistance would be greatly appreciated. The library for adding the javadoc cannot be found. We are using LibraryUtil.findLibraryEntry and LibraryUtil.findLibrary to no avail.
Hello Mike,
I'm afraid I don't understand your question. Please clarify what exactly
you would like to achieve.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Sorry about that Dmitry.
Hopefully this is clearer:
I wish to store a JavaDoc in the plugin and be able to access it from the Editor, like with a normal javadoc.
Similar to the help in the plugin.
Regards,
Mike.
Hello Mike,
- Package the javadoc files inside your plugin jar
- Somehow find or create the library with the classes described by the javadoc
- Call PathUtil.getJarPathForClass() to find the plugin jar from the plugin
code
- Call JarFileSystem.getInstance().getJarRootForLocalFile(LocalFileSystem.findFileByPath(pluginJar))
to find the root of your plugin JAR in the IDEA VFS
- Call jarRoot.findFileByRelativePath() to find the javadocs inside your
plugin jar
- Use Library.getModifiableModel().addRoot(javadocRoot, JavadocOrderRootType.getInstance()
to attach the javadocs to the library
- Call Library.ModifiableModel.commit() to save your changes
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Thank you Dmitry for the detailed reply.
I see you are nearing 10000 posts.
When you get there, the community should have a celebration to honour your valued contribution.
Community, any ideas on how to celebrate that? (It could even be today the way Dmitry is firing away those posts)
Regards,
Mike.
Hi Dmitry,
Everything is coming along quite well.
The javadoc and classes are loaded in the jar file.
The classes are functioning correctly with the GUI.
The javadoc is successfully found in the jar and can be utilised in the Library.
So now we are at the point where your assistance would be greatly appreciated.
The library for adding the javadoc cannot be found.
We are using LibraryUtil.findLibraryEntry and LibraryUtil.findLibrary to no avail.
Dmitry, any ideas?
Regards,
Mike.
Ok Dmitry, this case is closed.
I created a new Library and added both the classes and the javadoc to it.
Works very well.
Thanks,
Mike.