Java EE 6 Development with NetBeans 7


Java EE 6 Development with NetBeans 7
eBook: $29.99
Formats: PDF, PacktLib, ePub and Mobi formats
$25.50
save 15%!
Print + free eBook + free PacktLib access to the book: $79.98    Print cover: $49.99
$75.49
save 6%!
Packt
Anytime, Anywhere
Unlimited eBook downloads and up to 50% off the print version!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Use features of the popular NetBeans IDE to accelerate development of Java EE applications
  • Develop JavaServer Pages (JSPs) to display both static and dynamic content in a web browser
  • Covers the latest versions of major Java EE APIs such as JSF 2.0, EJB 3.1, and JPA 2.0, and new additions to Java EE such as CDI and JAX-RS
  • Learn development with the popular PrimeFaces JSF 2.0 component library

Book Details

Language : English
Paperback : 392 pages [ 235mm x 191mm ]
Release Date : June 2011
ISBN : 1849512701
ISBN 13 : 9781849512701
Author(s) : David R. Heffelfinger
Topics and Technologies : All Books, Application Development, Open Source, Web Development

Table of Contents

Preface
Chapter 1: Getting Started with NetBeans
Chapter 2: Developing Web Applications with Servlets and JSPs
Chapter 3: Enhancing JSP Functionality with JSTL and Custom Tags
Chapter 4: Developing Web Applications using JavaServer Faces 2.0
Chapter 5: Elegant Web Applications with PrimeFaces
Chapter 6: Interacting with Databases through the Java Persistence API
Chapter 7: Implementing the Business Tier with Session Beans
Chapter 8: Contexts and Dependency Injection (CDI)
Chapter 9: Messaging with JMS and Message Driven Beans
Chapter 10: SOAP Web Services with JAX-WS
Chapter 11: RESTful Web Services with JAX-RS
Appendix A: Debugging Enterprise Applications with the NetBeans Debugger
Appendix B: Identifying Performance Issues with the NetBeans Profiler
Index
  • Chapter 1: Getting Started with NetBeans
    • Introduction
    • Obtaining NetBeans
    • Installing NetBeans
      • Microsoft Windows
      • Mac OS X
      • Linux and Solaris
      • Other platforms
      • Installation procedure
    • Starting NetBeans for the first time
    • Configuring NetBeans for Java EE development
      • Integrating NetBeans with a third party application server
      • Integrating NetBeans with a third party RDBMS
        • Adding a JDBC driver to NetBeans
        • Connecting to a third party RDBMS
    • Deploying our first application
    • NetBeans tips for effective development
      • Code completion
      • Code templates
      • Keyboard shortcuts
      • Understanding NetBeans visual cues
    • Summary
    • Chapter 2: Developing Web Applications with Servlets and JSPs
      • Creating our first web application
        • Modifying NetBeans' generated code
          • Developing the input page
          • Developing the output page
      • Servlet development
        • Adding a Servlet to our Application
      • Securing web applications
        • Implementing form-based authentication
          • Implementing the login page
          • Implementing a login error page
          • Configuring our application for form-based authentication
      • JSP fragments
        • Creating a JSP fragment in NetBeans
      • Summary
      • Chapter 3: Enhancing JSP Functionality with JSTL and Custom Tags
        • Core JSTL tags
          • Conditionally displaying part of a page with the <c:if> tag
          • Displaying mutually exclusive markup with the <c:choose> tag
          • Iterating through arrays or collections with the <c:forEach> tag
        • SQL JSTL tags
          • Retrieving database data with the <sql:query> tag
        • Modifying database data with the <sql:update> tag
          • Inserting database data
          • Updating database data
          • Deleting database data
        • Closing remarks about JSTL
        • Custom JSP tags
        • Summary
        • Chapter 4: Developing Web Applications using JavaServer Faces 2.0
          • Introduction to JavaServer faces
          • Developing our first JSF application
            • Creating a new JSF project
              • Modifying our page to capture user data
              • Creating our managed bean
              • Implementing the confirmation page
              • Executing our application
              • JSF validation
          • Facelets templating
            • Adding a Facelets template to our project
            • Using the template
          • Composite components
          • Summary
              • Chapter 7: Implementing the Business Tier with Session Beans
                • Introducing Session Beans
                • Creating a session bean in NetBeans
                • Accessing the bean from a client
                  • Executing the client
                • Session bean transaction management
                • Implementing aspect oriented programming with interceptors
                  • Implementing the interceptor class
                  • Decorating the EJB with the @Interceptors annotation
                • EJB timer service
                • Generating session beans from JPA entities
                • Summary
                    • Chapter 10: SOAP Web Services with JAX-WS
                      • Introduction to web services
                      • Creating a simple web service
                        • Testing our web service
                        • Developing a client for our web service
                      • Exposing EJBs as web services
                        • Implementing new web services as EJBs
                        • Exposing existing EJBs as web services
                        • Creating a web service from an existing WSDL
                      • Summary

                            David R. Heffelfinger

                            David Heffelfinger is the Chief Technology Officer of Ensode Technology, LLC, a software consulting firm based in the greater Washington DC area. He has been architecting, designing and developing software professionally since 1995 and has been using Java as his primary programming language since 1996. He has worked on many large scale projects for several clients including the US Department of Homeland Security, Freddie Mac, Fannie Mae, and the US Department of Defense. He has a Masters degree in Software Engineering from Southern Methodist University. David is editor in chief of Ensode.net (http://www.ensode.net), a website about Java, Linux, and other technology topics.
                            Sorry, we don't have any reviews for this title yet.

                            Code Downloads

                            Download the code and support files for this book.


                            Submit Errata

                            Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


                            Errata

                            - 7 submitted: last submission 29 Apr 2013

                            Errata type: Typo | Page numbers: 94

                            The groups our user belongs to must match one of the group names we used in the application's sun-web.xml deployment descriptor.
                            Should be :
                            The groups our user belongs to must match one of the group names we used in the application's glassfish-web.xml deployment descriptor

                             

                            Errata type: Others | Page number: 157 | Errata date: 8 Aug 2012

                            In the custom validator illustrated example code there is a error in the book: public void validate(FacesContext facesContext, UIComponent uIComponent, Object value) t <-- SHOULD BE THROWS ValidatorException { .....

                             

                            Errata type: Others | Occurence: .zip file at Chapter 4 > jsfapp > src/java/com/ensode/jsf/validators > EmailValidator.java | Errata date: 2-11-2012

                            The annotation @FacesValidator("emailValidator") preliminary to the class signature is missing (it's described correctly in the book though)

                             

                            Errata type: Others | Page number: 27 | Errata date:29-11-2012

                            First of all you need to go inside the directory where hsqldb is installed;for example, C:\hsqldb-2.0.0\hsqldb\bin
                            When you are inside, double-click on runServer.bat to start the hsqldb server. When the server is running now, you can follow the procedure on page 27
                            Connect using, username
                            now you are able to set up jdbc:hsqldb:hsql://localhost:9001 inside the JDBC URL input form.


                             

                            Errata type: Others | Page number: 164 | Errata date: 18-1-2013

                            On page 164 the URL(uniform resource locator)shown on the image inside the browser address bar is not: http://localhost:8080/faceletstemplating/faces/page1.xhtml ; but it would be: http://localhost:8080/faceletstemplating/faces/template.xhtml . Therefore the URL: http://localhost:8080/faceletstemplating/faces/page1.xhtml would be the URL of the image at the page:166


                            Errata type: Code | Page number: 102 | Errata date: 18 Dec 08

                             

                            If you see an error similar to:
                            
                            "${param.displayConditionalText == 'true'} contains invalid expression(s):
                            javax.el.ELException: Unable to find ExpressionFactory of type:
                            org.apache.el.ExpressionFactoryImpl.
                            
                            while excuting the following line of code:

                            <c:if test="${param.displayConditionalText == 'true'}" var="textDisplayed" scope="session">

                            and entering the URL as: http://localhost:8080/jstlif/index.jsp?displayConditionalText=='true' Please not that this URL is incorrect; it has an extra "=" next to "displayConditionalText") The correct URL is: http://localhost:8080/jstlif/index.jsp?displayConditionalText=true

                             

                             

                            Errata type: Code| Page number: 18 | Errata date: 25-4-2013

                             

                            <jsp:useBean id="surveyData" scope="request"
                                    class="com.ensode.nbbook.model.SurveyData" />
                            with scope="session" seems to work

                             

                             

                            Sample chapters

                            You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

                            Frequently bought together

                            Java EE 6 Development with NetBeans 7 +    HP Network Node Manager 9: Getting Started =
                            50% Off
                            the second eBook
                            Price for both: $50.70

                            Buy both these recommended eBooks together and get 50% off the cheapest eBook.

                            What you will learn from this book

                            • Develop Java web applications by leveraging NetBeans functionality
                            • Build standard JSF applications by taking advantage of NetBeans features
                            • Integrate NetBeans with third-party RDBMS
                            • Develop JavaServer Pages (JSPs) to display both static and dynamic content in a web browser
                            • Develop aesthetically pleasing JSF web applications by leveraging the PrimeFaces JSF 2.0 component library
                            • Quickly and easily develop applications taking advantage of the Java Persistence API
                            • Implement the Model-View-Controller design pattern by using JavaBeans as the model component
                            • Take advantage of NetBeans functionality to easily develop Enterprise JavaBeans, including configuring transaction management via annotations
                            • Use static and dynamic navigation to define navigation between pages
                            • Utilize NetBeans to easily add messaging functionality to enterprise applications, through the Java Messaging Service API and through message-driven EJBs
                            • Develop SOAP-based and RESTful web services using NetBeans, including exposing EJB functionality as web services

                            In Detail

                            NetBeans has several features that greatly simplify Java EE development, but with many features and great flexibility, Java developers can become overwhelmed by the options available in NetBeans. This book provides step-by-step recipes that show you how to take control of the environment and make use of these features to make your enterprise Java application development more efficient and productive than ever before, so that you can concentrate on the important parts of your application.

                            Java EE 6 Development with NetBeans 7 takes you through the most important parts of Java EE programming and shows you how to use the features of NetBeans that will improve your development experience with clear, careful instructions and screenshots. It will show you how to use NetBeans functionality to automate many of the tedious or repetitive tasks frequently encountered when developing enterprise Java applications, freeing you up to focus on the business logic specific parts of the application. As well as showing you time-saving tricks, keyboard shortcuts, and other productivity enhancements possible with NetBeans, it will take you through the major Java EE APIs and how to get them working in the NetBeans environment.

                            While focusing on NetBeans features, you will learn about developing applications using the servlet API and JSPs, including taking advantage of JSTL and developing custom JSP tags. Developing applications that take advantage of JavaServer Faces is also covered in detail, including how to generate standard JSF applications from an existing database schema. The book also covers how to easily develop elegant JSF applications by taking advantage of the PrimeFaces JSF 2.0 component library that is bundled with NetBeans.

                            A practical guide covering how to leverage NetBeans 7 functionality to develop enterprise applications compliant with the Java EE 6 standard

                            Approach

                            The book is a practical guide explaining the various features of the NetBeans IDE related to enterprise application development.

                            Who this book is for

                            The book is aimed at Java developers who wish to develop Java EE applications while taking advantage of NetBeans functionality to automate repetitive tasks and to ease their software development efforts. Familiarity with NetBeans or Java EE is not assumed.

                            Code Download and Errata
                            Packt Anytime, Anywhere
                            Register Books
                            Print Upgrades
                            eBook Downloads
                            Video Support
                            Contact Us
                            Awards Voting Nominations Previous Winners
                            Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
                            Resources
                            Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software