Review and start again——First Period JAVA web Program hotelmanagement:7. The vo/DAO/factory codes.

The past three articals is the fundamental of this one.
Today I will finish the Model.

Section1:
Finish the development of the data background.
(1) compile the VO class. (Admin.java class)

New a new package cn.ylcto.vo in the src folder .
New a class Admin in this package and choose to add the serializable interface into the class.
在这里插入图片描述
Return the navicat and see the content in the table.

The JDBC setting https://blog.csdn.net/wangxixuan0008/article/details/96643129

There will be an error when code the mode of the “lastdate”—Date. You should import the package java.util.date.

(2)Generate the getter and setter method for the class Admin
right click and choose the “source - generate the getter() and setter()”在这里插入图片描述
select all and click the “Generate”

Section2.
Write a database link operation class.
(DatabaseConnection.java)
在这里插入图片描述在这里插入图片描述
Section3.
generate the public DAO interface.
eg. The IDAO.java

Section4.
generate the data interface.
eg.IAdminDAO.java
在这里插入图片描述
Section5.
compile the exact implementation subclass.
eg. AdminDAOImpl.java

Section6.
comile the data factory class
eg.DAOFactory.java
在这里插入图片描述

汇编,编写 compile
实现,履行 implementation
子类 subclass

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值