Home » Search

About Java EE

11-20 of 200Refresh
Tutorial
238

Java EE 6 JPA Tutorial - NetBeans Project

To open and run the Java EE 6 Web Application tutorial project in NetBeans: Download and extract the project zip file: Java EE 6 JPA Web App - Maven Project (6KB). Open the Maven project in NetBeans: Select File > Open Project.... Select the guestbook-jee6 directory and click Open Project. Run
JPA Doc
238

JPA Annotations for Java EE

The following JPA annotations are in use to integrate JPA into a Java EE application and are managed by the Java EE container:
FAQ
121

What is the Java Persistence API (JPA)?

The Java Persistence API (JPA) is a standard API for accessing databases from within Java applications. The main advantage of JPA over JDBC (the older Java API for interacting with databases ... . Using plain old Java objects (POJO) to represent persistent data can significantly simplify database
Tutorial
75

Step 1: Create a Java Project

IDE for Java EE Developers, you can see in the [New] menu a command for creating a [JPA Project]. We are not using that type of project in this tutorial but rather an ordinary Java Project. In the [New Project] dialog box: Select Java Project and click Next. Choose a Project Name (e.g. Tutorial
Tutorial
70

Step 3: Define an EJB Session Bean

node (in the [Projects] window), selecting New > Other... > Java EE (or Enterprise JavaBeans ... - for retrieving all the existing Guest objects from the database. EJB classes are only supported by Java EE ... class name. The Java package name should be guest. Click Finish to create the new session bean (EJB
Tutorial
64

Step 3: Define an EJB Session Bean

are only supported by Java EE application servers such as GlassFish and JBoss, and not by servlet ... that we will define in this step: Open the [New Java Class] dialog box by right clicking the guest package ... code: package guest; import java.util.List; import javax.ejb.Stateless; import javax
Tutorial
55

JPA Tutorials

WebLogic). The next tutorial shows how to use JPA in a full Model-View-Controller (MVC) Java EE 6 web application that should be deployed in a Java EE 6 container: Java EE 6 (J2EE) Web Tutorial Since this web application uses Java EE 6 EJB (session beans) it requires a full Java EE 6 application server
Tutorial
51

Step 4: Add a Servlet Class

... Enter GuestServlet as the class name - use exactly that case sensitive class name. The Java ... of the new source file with the following code: package guest; import java.io.IOException; import
Tutorial
51

Step 4: Add a Servlet Class

> Other... > Web > Servlet and clicking Next. The Java package name should be guest. Enter ... ; import java.io.IOException; import javax.ejb.EJB; import javax.servlet.ServletException
Tutorial
50

Step 5: Add a JSP Page

: <%@page contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <%@page import="java.util