📄 applicantbean.java
字号:
package web;
import java.rmi.*;
import javax.ejb.*;
import javax.naming.*;
import agency.*;
public class ApplicantBean
{
RegisterHome registerHome;
Register register;
private String login;
public void setLogin (String login) throws Exception {
this.login = login;
register = registerHome.create(login);
}
public void updateDetails (String name, String email, String location, String summary, String[] skills) throws RemoteException {
if (skills == null)
skills = new String[0];
register.updateDetails(name,email,location,summary,skills);
}
public String getLogin() throws RemoteException {
return login;
}
public String getName() throws RemoteException {
return register.getName();
}
public String getEmail() throws RemoteException {
return register.getEmail();
}
public String getLocation() throws RemoteException {
return register.getLocation();
}
public String getSummary() throws RemoteException {
return register.getSummary();
}
public String[] getSkills() throws RemoteException {
return register.getSkills();
}
public ApplicantBean () throws NamingException {
InitialContext ic = new InitialContext();
registerHome = (RegisterHome)ic.lookup("java:comp/env/ejb/Register");
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -