?? usermgr.java
字號:
package com.shopping.business;
import java.sql.*;
import java.util.*;
import com.comm.*;
import com.comm.vo.*;
import com.shopping.dao.*;
public class UserMgr {
public int registerUser(GenericVO gvo) throws AppException {
try {
return new UserDao().add(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void modifyUser(GenericVO gvo) throws AppException {
try {
new UserDao().modify(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public ListVO searchUser(GenericVO gvo) throws AppException {
try {
return new UserDao().search(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public GenericVO getUserDetail(int userId) throws AppException {
try {
return new UserDao().getDetail(userId);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void updateUserDot(int userId, int dot) throws AppException {
try {
new UserDao().updateUserDot(userId, dot);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public GenericVO login(String userName, String password) throws
AppException {
try {
return new UserDao().login(userName, password);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public Vector getOrdersByUserId(int userId) throws AppException {
try {
return new OrderDao().getOrdersByUserId(userId);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public Vector getOrdersByUserId(int userId, int status, int num) throws
AppException {
try {
return new OrderDao().getOrdersByUserId(userId, status, num);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void addRemit(GenericVO gvo) throws AppException {
try {
new RemitDao().add(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void addFavorite(GenericVO gvo) throws AppException {
try {
new FavoriteDao().add(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void deleteFavorite(int favoriteId) throws AppException {
try {
new FavoriteDao().delete(favoriteId);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public ListVO searchFavorite(GenericVO gvo) throws AppException {
try {
return new FavoriteDao().search(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public int modifyUserPass(int userId, String oldPass, String newPass) throws
AppException {
try {
return new UserDao().passModify(userId, oldPass, newPass);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public void addOrderStatus(GenericVO gvo) throws AppException {
try {
new OrderDao().addOrderStatus(gvo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
public Vector getOrderStatusByOrderNo(String orderNo) throws AppException {
try {
return new OrderDao().getOrderStatusByOrderNo(orderNo);
} catch (SQLException ex) {
throw new AppException(ex);
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -