-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPerson.java
More file actions
77 lines (70 loc) · 1.51 KB
/
Person.java
File metadata and controls
77 lines (70 loc) · 1.51 KB
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
/**
* "Information Holder" for single search analysis result
*
* @author Chae Jubb
* @version 1.0
*
*/
public class Person {
private final String name;
private final String link;
private final String movie;
private final String movieLink;
/**
* Constructor
*
* @param name
* Name of result (Actor, Actress, Director, etc.)
* @param link
* Link for page corresponding to this.name
* @param movie
* Movie corresponding to result
* @param movieLink
* Link for page corresponding to this.movie
*/
public Person(String name, String link, String movie, String movieLink) {
this.name = name;
this.link = link;
this.movie = movie;
this.movieLink = movieLink;
}
/**
* Returns String representation of Object in format Key:Value;Key:Value...
*/
public String toString() {
return "Name: " + this.name + "; Link: " + this.link + "; Movie: "
+ this.movie + "; MovieLink: " + this.movieLink;
}
/**
* Accessor for Link (corresponding to name)
*
* @return this.link (corresponds to name)
*/
public String getLink() {
return this.link;
}
/**
* Accessor for Name of result
*
* @return this.name
*/
public String getName() {
return this.name;
}
/**
* Accessor for Movie corresponding to result
*
* @return this.movie
*/
public String getMovie() {
return this.movie;
}
/**
* Accessor for link corresponding to Movie
*
* @return this.movieLink
*/
public String getMovieLink() {
return this.movieLink;
}
}