What would be the equivalent of a library in C++ for Java? I have some classes I’d like to reuse as a library in multiple projects.
Thanks
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Basically you build a jar file with the classes in, and then add a reference to that jar file on the classpath for both compilation and execution.
See the Oracle Jar File Tutorial for more information.