public class Customer { public Customer() { super(); } public Customer(String orgName, String custName, String add) { this.orgName = orgName; this.customerName = custName; this.address = add; } private String orgName; private String customerName; private String address; public String getAddress() { return address; } public void setAddress(String address) { this.address = address; } public String getCustomerName() { return customerName; } public void setCustomerName(String customerName) { this.customerName = customerName; } public String getOrgName() { return orgName; } public void setOrgName(String orgName) { this.orgName = orgName;
public class Employee { private String personName; private Person person; private Collection employments = new ArrayList(); Employee() {} public Employee(Person p) { this.person = p; this.personName = p.getName(); p.setEmployee(this); } public Person getPerson() { return person; } public void setPerson(Person person) { this.person = person; } public String getPersonName() { return personName; } public void setPersonName(String personName) { this.personName = personName; } public Collection getEmployments() { return employments; } public void setEmployments(Collection employments) { this.employments = employments;
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/idclass/Customer.java File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/lazyonetoone/Employee.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public class Customer {
1
public class 
2
	public Customer() {
3
		super();
4
	}
5
	public Customer(String orgName, String custName, String add
2
Employee {
3
	private String personName;
4
	private Person person;
5
	private Collection employments = new ArrayList(); 
6
	Employee() {}
6
) {
7
	public Employee(Person p) {
7
		this.orgName = orgName;
8
		this.
8
		this.customer
9
person = p;
9
Name = custName;
10
		this.personName = p.getName();
10
		this.address = add;
11
		
11
	}
12
	private String orgName;
13
	private String customerName;
14
	private String address;
12
p.setEmployee(this);
13
	}
15
	public String getAddress() {
14
	public Person getPerson() {
16
		return address;
15
		return 
16
person;
17
	}
17
	}
18
	public void setAddress(String address) {
18
	public void setPerson(Person person) {
19
		this.address = address;
19
		this.
20
	}
20
person = person;
21
	}
21
	public String getCustomerName() {
22
	public String getPersonName() {
22
		return customerName;
23
		return personName;
23
	}
24
	}
24
	public void setCustomerName(String customerName) {
25
	public void setPersonName(String personName) {
25
		this.customerName = customerName;
26
		this.personName = personName;
26
	}
27
	}
27
	public String getOrgName() {
28
	public Collection getEmployments() {
28
		return orgName;
29
		return 
30
employments;
29
	}
31
	}
30
	public void setOrgName(String orgName) {
32
	public void setEmployments(Collection employments) {
31
		this.orgName = orgName;
33
		this.employments = employments;
34
	
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