2013-05-01 Created By BaoXinjian


在本教程中,您将使用甲骨文的JDeveloper 11 g版本11.1.2.0.0来构建一个web应用程序。

建立数据模型,您可以使用EJB图,EJB 3.0和Java Persistence API(JPA)。

web客户端使用JavaServer Faces(JSF)。

创建一个主从复合结构主页查询和编辑功能的用户界面。

一个任务流,搜索功能,也作为一个地区添加到页面中。

Building a Web Application Using EJB, JPA, and JavaServer Faces

Part 1: Building the Data Model with EJB 3.0 Using the EJB Diagrammer

Step 1: Create a New Application and Projects

Step 2: Create the Persistence Model

Step 3: Create an EJB Diagram and a Session Bean

Step 4: Create a Facade Bean to Expose for the Client Application

Step 5: Create ADF Data Controls from EJB Session Beansclose

Part 2: Building the View Projectclose

Step 1: Create a Master-Detail JavaServer Faces Page

Step 2: Bind Data Control Components to the Page

Step 3: Run and Test the Page

Step 4: Add Create and Delete Functionalities to the Page

Part 3: Adding and Exposing a New Method to the UIclose

Step 1: Add a New Method to the Entity and Expose it

Step 2: Build a Bounded Task Flow with Two JSF Pages

Step 3: Use the Task Flow as aRegion in the mainHR pageStep 4: Run the mainHR Page

Part 4: Testing the Facade Inside and Outside the Java EE Container

Step 1: Add a New Method to the Entity and Expose it

Step 2: Run the Java Service outside Java EE container


1. 创建ADF Facelets页面

2. 添加组件后,最终显示效果如下

3. 测试运行,结果如下


1. 绑定Department数据到页面

2.  绑定Employee Master数据到页面

3.  绑定Employee Detail数据到页面

4.  绑定Employee信息到表

案例3 - Run and Test the Page


1. 运行测试,Master-Detail结构

2. 运行测试图标

3. 修改Salary后,查看图标的显示

4. 图标更新如下

案例4 - Add Create and Delete Functionalities to the Page


1.  新增Create和Delete按钮

2.  建立持久化层

3. 添加持久化按钮

4. 运行测试,Create的department

5.  创建数据后,进行持久化

6. 查看数据库的资料

Thanks and Regards

ADF_Starting系列7_使用EJB/JPA/JSF通过ADF构建Web应用程序之创建UI View的更多相关文章

  1. ADF_Starting系列8_使用EJB/JPA/JSF通过ADF构建Web应用程序之扩展UI Method

    2013-05-01 Created By BaoXinjian

  2. ADF_Starting系列9_使用EJB/JPA/JSF通过ADF构建Web应用程序之测试J2EE Container

    2013-05-01 Created By BaoXinjian

  3. IDEA 2017.3 新版本中创建 JSF Web 应用程序缺少 web.xml 的解决办法

    IDEA 2017.3 新版本中默认创建一个 Web 应用程序很可能不会自动创建 web.xml 文件.虽然说从 JavaEE 6.0 开始 Servlet 3.0 规范中就新增了一些注解可以免去传统 ...

  4. JSF+EJB+JPA总体思路

    前言: JSF+EJB+JPA 其实我并没有想象中的难,只是想做好,建立在正确的地方应用,真正的困难. 良好的技术,在错误的地方做应用,这是唯一能够被垃圾. 用. 重量级企业应用能够使用这个主要的3层 ...

  5. Problems found loading plugins: Plugin "GlassFish Integration" was not loaded: required plugin "Java EE: EJB, JPA, Servlets" is disabled.

    idea启动报错:并且无法部署web项目 Problems found loading plugins: Plugin "GlassFish Integration" was no ...

  6. SpringBoot系列之Spring Data Jpa集成教程

    SpringBoot系列之Spring Data Jpa集成教程 Spring Data Jpa是属于Spring Data的一个子项目,Spring data项目是一款集成了很多数据操作的项目,其下 ...

  7. IDEA报错Plugin "XXX" was not loaded: required plugin "Java EE: EJB, JPA, Servlets" is disabled.

    Java项目转Web项目 把java项目转成web项目时,发现Facets点击+号没有出现web选项. 经查询发现是插件没有正常加载导致的. 解决方案 1.没找到其他原因,重启即可. 2.我的是插件没 ...

  8. Spring全家桶系列–SpringBoot之入门JPA

    //本文作者:cuifuan 什么是JPA? 一种规范,并非ORM框架,也就是ORM上统一的规范 用了之后可以做什么,为什么要用? 代码解释: 实体类 package com.example.spri ...

  9. [转载][翻译] 利用JSF、SpringFramework和Hibernate构建Web应用的实例讲述

    [原作者] Derek Yang Shen[原文链接] http://www.javaworld.com/javaworld/jw-07-2004/jw-0719-jsf.html[源码链接] htt ...

随机推荐

  1. Queue的push和front操作

    #include <queue> #include <cstdlib> using namespace std; int main(){ queue<int> qu ...

  2. DIV设置overflow无效的原因

    因为项目需求需要在一个div中添加多个checked 添加的时候使用了 <label><input type="checkbox" value="123 ...

  3. mysql 二进制日志

      1.日志类型   二进制日志记录了所有对mysql数据库的修改事件,包括增删改事件和对表结构的修改事件.   2.配置使用二进制日志 在my.ini 配置 log-bin=mysql-bin   ...

  4. iOS开发网络篇—发送json数据给服务器以及多值参数

    iOS开发网络篇—发送json数据给服务器以及多值参数 一.发送JSON数据给服务器 发送JSON数据给服务器的步骤: (1)一定要使用POST请求 (2)设置请求头 (3)设置JSON数据为请求体 ...

  5. require.js基本认识

    基本API require会定义三个变量:define,require,requirejs,其中require === requirejs,一般使用require更简短 define 从名字就可以看出 ...

  6. EXE捆绑器

    释放的方法真没想到  太神奇了 // 文件捆绑器Dlg.cpp : 实现文件 // #include "stdafx.h" #include "文件捆绑器.h" ...

  7. linux下用phpize给PHP动态添加扩展

    使用php的常见问题是编译php时忘记添加某扩展,后来想添加扩展,但是因为安装php后又装了一些东西如PEAR等,不想删除目录重装,这里就需要用到phpize了. 如我想增加bcmath扩展的支持,这 ...

  8. bzoj1211: prufer序列 | [HNOI2004]树的计数

    题目大意: 告诉你树上每个节点的度数,让你构建出这样一棵树,问能够构建出树的种树 这里注意数量为0的情况,就是 当 n=1时,节点度数>0 n>1时,所有节点度数相加-n!=n-2 可以通 ...

  9. powershell脚本闪电输入神器

    如图所示: 用autohotkey,把下列常用按键互唤.来达到快速输入目的.并且只对powershell ise,power gui,visual studio code,powershell stu ...

  10. excel列递增方法技巧

    最近处理世界买家网100多万的数据,需要用到excel来对数据进行处理,其中有一项是对数据做一个排序,以方便数据导入时来对应唯一的id编号,之前都是 几万,最多也是30来万的数据,所以列递增就直接用鼠 ...