Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Netbeans

You're reading from  Mastering Netbeans

Product type Book
Published in Aug 2015
Publisher
ISBN-13 9781785282645
Pages 348 pages
Edition 1st Edition
Languages
Toc

Table of Contents (17) Chapters close

Mastering NetBeans
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
1. Getting Started with NetBeans 2. Editing Files and Projects 3. The NetBeans Developer's Life Cycle 4. Managing Services 5. Database Persistence 6. Desktop Development 7. Creating the Business Layer 8. Creating the Web Tier 9. Creating and Consuming Web Services 10. Extending NetBeans Index

Creating a session bean façade for entity classes


In the previous section, we saw how we can use NetBeans to help us create business methods within EJBs and easily invoke EJB from client applications.

In all but the most simple application, however, we usually have a database component and a graph of database objects modeled with the @Entity annotation within our application.

Since one of the benefits of EJBs is that they offer transactional support, EJBs make a good candidate for a session façade for entity classes. A session façade is a design pattern that abstracts the implementation of methods away from callers in order to decouple business objects from callers. In this instance, NetBeans can create a session façade that abstracts away all of the database functionality from clients, making the clients unaware of how business objects are persisted. This is only one use of a session façade though, and as a developer, we can add more methods into the façade to provide the exact services that...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}