Is there an Java API viewer on command line?
I have been using
man for C programming and
ri for Ruby programming. Both of them seems very convenient for me, and now I am looking for something alike for Java API.
I apologize if this question has been raised before. I did many Google searches but no result shows up. I think I might have been using the wrong terms.
As part of the JDK, you will also receive the javap utility that allows you to see method signatures in a java .class file.
For java API, you can use
If you are a vi fanatic, use this tweak to see the method signature on the class under cursor with the following addition to your ~/.vimrc.
map tt yy:tabnew ^R^W^M
map + tt:set ft=java^M!!javap -public `grep .*%$ $jre/lib/classlist`^M
- Characters preceeded by caret like ^M need to be typed using Ctrl+V then Ctrl+M
- javap needs to be in your system path
- Use your own jre location in place of this
- Finally, since this is tested using cygwin, you may need to do some touch ups
Another way is to use a text-based browser. See:
Look up javadoc Help file from Vim [Unix Only]