开发者

How to call Bean classes not in default package

Netbeans IDE supports beansbinding and we can call easily a bean in the default package (without instantiating beans can be seen in the Inspector).

But if our UI components (swing) is in another package, and beans are in another package, we have to instantiate those beans in o开发者_开发知识库ur components (JFrame or JPanel) with getters (and setters). I want to know that, is there a way to call beans without instantiating in our components in NetBeans(Just select the source from the bind property box). (Then we can see those beans in the Inspector of the relevant component (JFrame or JPanel).) In other words, is there a way to place our beans classes in the Inspector.(if our JFrame is in default package and bean is also in Default package, then we can click the bean icon from the pallet and give the relavant bean class,Then we can see that bean class in the Inspector)


You can just drag the class on the Projects window to the JPanel you want to put in. It will appear in Inspector.

(If I understand the question :)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜