使用类库 [英] Using class libraries

查看:70
本文介绍了使用类库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在NETBEANS中使用类库?我在项目库文件夹中添加了一个.jar文件,并且可以构建该程序.但是,如何使用库中的方法?
谢谢

How do you use a class library in NETBEANS? I added a .jar file to the project library folder and can build the program. However, How do I used the methods in the library?
Thanks

推荐答案

与在其他任何库中使用该方法的方式相同.将相关的import语句(类或包)添加到源中,并调用要使用的方法.
The same way you use the method in any other library. Add the relevant import statement (class or package) to your source and call the methods you wish to use.


这篇关于使用类库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆