?? customerejb.java
字號:
package apusic.myshop.customer.ejb;import java.rmi.RemoteException;import javax.naming.InitialContext;import javax.naming.Context;import javax.naming.NamingException;import javax.ejb.EntityBean;import javax.ejb.EntityContext;import javax.ejb.EJBException;import javax.ejb.FinderException;import javax.ejb.CreateException;import javax.ejb.RemoveException;import javax.ejb.DuplicateKeyException;import apusic.myshop.customer.model.CustomerModel;public class CustomerEJB implements EntityBean { public String userId; public String password; public String name; public String sex; public String company; public String cid; public String address; public String province; public String city; public String zip; public String phone; public String email; public java.sql.Date regDate; private EntityContext initCtx; protected transient boolean dirty = false; public void ejbActivate() { // } public void ejbPassivate() { // } public void ejbLoad() throws RemoteException { // } public void ejbStore() { // } public void ejbRemove() throws RemoveException { // } private void setDirty(boolean flag) { dirty = flag; } public boolean isModified() { return dirty; } public void setEntityContext(EntityContext ctx) { initCtx = ctx; } public void unsetEntityContext() { initCtx = null; } public CustomerPK ejbCreate( String userId, String password, String name, String sex, String company, String cid, String address, String province, String city, String zip, String phone, String email, java.sql.Date regDate ) throws CreateException { this.userId = userId; this.password = password; this.name = name; this.sex = sex; this.company = company; this.cid = cid; this.address = address; this.province = province; this.city = city; this.zip = zip; this.phone = phone; this.email = email; this.regDate = regDate; return null; } public void ejbPostCreate( String userId, String password, String name, String sex, String company, String cid, String address, String province, String city, String zip, String phone, String email, java.sql.Date regDate ) {} //++++++++++++++++++++++++++++++++++++++++++++++++++++ //+++ business method //++++++++++++++++++++++++++++++++++++++++++++++++++++ public String getUserId() { return userId; } public String getPassword() { return password; } public String getName() { return name; } public String getSex() { return sex; } public String getCompany() { return company; } public String getCid() { return cid; } public String getAddress() { return address; } public String getProvince() { return province; } public String getCity() { return city; } public String getZip() { return zip; } public String getPhone() { return phone; } public String getEmail() { return email; } public java.sql.Date getRegDate() { return regDate; } public CustomerModel getDetails() { return new CustomerModel( userId, password, name, sex, company, cid, address, province, city, zip, phone, email, regDate ); } public void setUserId(String userId) { this.userId = userId; setDirty(true); } public void setPassword(String password) { this.password = password; setDirty(true); } public void setName(String name) { this.name = name; setDirty(true); } public void setSex(String sex) { this.sex = sex; setDirty(true); } public void setCompany(String company) { this.company = company; setDirty(true); } public void setCid(String cid) { this.cid = cid; setDirty(true); } public void setAddress(String address) { this.address = address; setDirty(true); } public void setProvince(String province) { this.province = province; setDirty(true); } public void setCity(String city) { this.city = city; setDirty(true); } public void setZip(String zip) { this.zip = zip; setDirty(true); } public void setPhone(String phone) { this.phone = phone; setDirty(true); } public void setEmail(String email) { this.email = email; setDirty(true); } public void setRegDate(java.sql.Date regDate) { this.regDate = regDate; setDirty(true); }}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -