Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Java EE 7 Development with NetBeans 8
  • Table Of Contents Toc
  • Feedback & Rating feedback
Java EE 7 Development with NetBeans 8

Java EE 7 Development with NetBeans 8 - Third Edition

By : David R Heffelfinger
4.8 (5)
close
close
Java EE 7 Development with NetBeans 8

Java EE 7 Development with NetBeans 8

4.8 (5)
By: David R Heffelfinger

Overview of this book

The book is aimed at Java developers who wish to develop Java EE applications while taking advantage of NetBeans functionality to automate repetitive tasks. Familiarity with NetBeans or Java EE is not assumed.
Table of Contents (13 chapters)
close
close
12
Index

Accessing the bean from a client


Now, it's time to focus our attention on the client. For remote clients, the client project needs to use the Java Class Library project containing the remote interface; this is the reason we created a Java Class Library project earlier in the chapter and added it to the client project.

After adding the client library containing the remote interface for our session bean, we are ready to invoke our EJB method. The client code needs to obtain a reference to an instance of a class implementing the remote interface for our bean. When using NetBeans, this is very easy. We simply need to right-click on the client code (com.ensode.sessionbeanintro.Main in the application client project in our example) and go to Insert Code... | Call Enterprise Bean.

At this point, we are shown a list of all open projects that have EJBs in them; we need to select the bean we wish to access from one of these projects.

If our bean had both a local and remote interface, we would have been...

Visually different images
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Java EE 7 Development with NetBeans 8
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist download Download options font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon