-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathContact.java
More file actions
41 lines (31 loc) · 748 Bytes
/
Contact.java
File metadata and controls
41 lines (31 loc) · 748 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
public class Contact {
private String name;
private long phoneNo;
private String email;
Contact(String name, long phoneNo){
this.name = name;
this.phoneNo = phoneNo;
}
Contact(String name, long phoneNo, String email){
this(name, phoneNo);
this.email = email;
}
public String getName(){
return name;
}
public Long getPhoneNo(){
return this.phoneNo;
}
public String getEmail(){
return this.email;
}
public void setName(String name){
this.name = name;
}
public void setPhoneNo(long phoneNo){
this.phoneNo = phoneNo;
}
public void setEmail(String email){
this.email = email;
}
}