public class Salesperson { private Long id; private String name; private String region; private Date hireDate; private Department department; private Set orders = new HashSet(); public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getRegion() { return region; } public void setRegion(String region) { this.region = region; } public Set getOrders() { return orders; } public void setOrders(Set orders) { this.orders = orders; } public Date getHireDate() { return hireDate; } public void setHireDate(Date hireDate) { this.hireDate = hireDate; } public Department getDepartment() { return department; } public void setDepartment(Department department) { this.department = department;
public class Person { private Long id; private String name; private Address address; private String userId; private Set accounts = new HashSet(); private List systems = new ArrayList(); /** * @return Returns the userId. */ public String getUserId() { return userId; } /** * @param userId The userId to set. */ public void setUserId(String userId) { this.userId = userId; } /** * @return Returns the address. */ public Address getAddress() { return address; } /** * @param address The address to set. */ public void setAddress(Address address) { this.address = address; } /** * @return Returns the id. */ public Long getId() { return id; } /** * @param id The id to set. */ public void setId(Long id) { this.id = id; } /** * @return Returns the name. */ public String getName() { return name; } /** * @param name The name to set. */ public void setName(String name) { this.name = name; } /** * @return Returns the accounts. */ public Set getAccounts() { return accounts; } /** * @param accounts The accounts to set. */ public void setAccounts(Set accounts) { this.accounts = accounts; } public List getSystems() { return systems; } public void setSystems(List systems) { this.systems = systems;
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/filter/Salesperson.java File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/propertyref/basic/Person.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public class Salesperson {
1
public class Person {
2
	private Long id;
2
	private Long id;
3
	private String name;
3
	private String name;
4
	private String region;
4
	private 
5
	private Date hireDate;
5
Address address;
6
	private String userId;
6
	private Department department;
7
	private 
7
	private Set orders = new HashSet();
8
Set accounts = new HashSet();
9
	private List systems = new ArrayList();
10
	/**
11
	 * @return Returns the userId.
12
	 */
8
	public Long getId() {
13
	public String getUserId() {
9
		return id;
14
		return userId;
10
	}
15
	}
11
	public void setId(Long i
16
	/**
17
	 * @param userId The userId to set.
18
	 */
12
d) {
19
	public void setUserId(String userId) {
13
		this.id = id;
20
		this.userId = userId;
14
	}
21
	}
15
	public String getName
22
	/**
23
	 * @return Returns the address.
24
	 */
16
() {
25
	public Address getAddress() {
17
		return name;
26
		return 
18
	}
19
	public void setName(String name
27
address;
28
	}
29
	/**
30
	 * @param address The address to set.
31
	 */
20
) {
32
	public void setAddress(Address address) {
21
		this.name = name;
33
		this.
22
	}
34
address = address;
35
	}
36
	/**
37
	 * @return Returns the id.
38
	 */
23
	public String getRegion() {
39
	public Long getId() {
24
		return region;
40
		return 
25
	}
26
	public void setRegion(String region
41
id;
42
	}
43
	/**
44
	 * @param id The id to set.
45
	 */
27
) {
46
	public void setId(Long id) {
28
		this.region = region;
47
		this.
29
	}
48
id = id;
49
	}
50
	/**
51
	 * @return Returns the name.
52
	 */
30
	public Set getOrders() {
53
	public String getName() {
31
		return orders;
54
		return 
32
	}
55
name;
56
	}
57
	/**
58
	 * @param name The name to set.
59
	 */
33
	public void setOrders(Set orders) {
60
	public void setName(String name) {
34
		this.orders = orders;
61
		this.
35
	}
36
	public Date getHireDate
62
name = name;
63
	}
64
	/**
65
	 * @return Returns the accounts.
66
	 */
37
() {
67
	public Set getAccounts() {
38
		return hireDate;
68
		return 
39
	}
40
	public void setHireDate(Date hireDate
69
accounts;
70
	}
71
	/**
72
	 * @param accounts The accounts to set.
73
	 */
41
) {
74
	public void setAccounts(Set accounts) {
42
		this.hireDate = hireDate;
75
		this.
43
	}
44
	public Department getDepartment
76
accounts = accounts;
77
	}
45
() {
78
	public List getSystems() {
46
		return department;
79
		return 
47
	}
80
systems;
81
	}
82

48
	public void setDepartment(Department department) {
83
	public void setSystems(List systems) {
49
		this.department = department;
84
		this.systems = systems;
50
	
85
	
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0