📄 people.java
字号:
/*
* People.java
*
* Created on 2007年12月18日, 上午11:26
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/
package adressbook;
import java.io.*;
import java.util.*;
/**
*
* @author Administrator
*/
public class People extends ArrayList implements Serializable {
/** Creates a new instance of People */
public People() {
}
public void delete(Object p) {
this.remove(p);
}
public Person find(String nam) {
Person p = null;
for (int i = 0; i<this.size(); i++){
p = (Person)(this.get(i));
if (p.name.equals(nam)){
break;
}else{
p = null;
}
}
return p;
}
public void addnew(Person p) {
this.add(p);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -