has been very tangled Linux under no similar jcreateor lightweight javaide,vim with Javacomplete although there are a lot of imperfections, but to some extent, to solve the problem of the completion of Java code. Installation process:
Download Javacomplete:omni completion for JAVA
Website download site
Inside is two folders, one autoload a doc
Copy the contents of the two folders to the corresponding folder in ~/.vim/* .
There is a Reflecttion.java file in AutoLoad, compile it with Javac.
Adding ~/.vim/autoload to the Java environment variable, I added it directly to the ~/.BASHRC , and can also be added to /etc/profile
# sun java8u45export JAVA_HOME=/usr/lib/jvm/java-8u45-sun export JRE_HOME=${JAVA_HOME}/jre export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib:~/.vim/autoloadexport PATH=${JAVA_HOME}/bin:$PATH
Need to update BASHRC after adding
source ~/.bashrc
- Modify VIMRC
Add the following sentence:
setlocal omnifunc= javacomplete #Complete autocmd FileType java Set omnifunc= javacomplete #Complete Autocmd FileType java set completefunc= Javacomplete #CompleteParamsInf Autocmd FileType java inoremap < buffer> < C-x >< c- O >< c-p >
Now it should be possible to complement the system's functions:
For more information:
Http://www.cnblogs.com/Nstd/archive/2012/04/14/2447828.html
http://blog.csdn.net/wangran51/article/details/7248945
http://blog.csdn.net/jixiuffff/article/details/5695806
Ubuntu Vim Installation Javacomplete