8000 java programming · ravitomar7/Java_Programming_CCVT@d6a16b2 · GitHub
[go: up one dir, main page]

Skip to content

Commit d6a16b2

Browse files
500052217500052217
500052217
authored and
500052217
committed
java programming
1 parent 9c56fd8 commit d6a16b2

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

CCVT_Code_Distribute/src/com/rt/cloning/Department.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ public int getDid() {
1010
public void setDid(int did) {
1111
this.did = did;
1212
}
13+
1314
public String getDname() {
1415
return dname;
1516
}

CCVT_Code_Distribute/src/com/rt/cloning/Employee.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public String toString() {
4646
// TODO Auto-generated method stub
4747
return "Employee id: "+eid+" Employee Name: "+ename+" Dep Name:"+dep.getDname()+" Dep Id:"+dep.getDid();
4848
}
49-
49+
//temp.dep=this.dep.clone();
5050
@Override
5151
protected Employee clone() throws CloneNotSupportedException {
5252
// TODO Auto-generated method stub

CCVT_Code_Distribute/src/com/rt/cloning/TestClass.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ public static void main(String[] args) throws CloneNotSupportedException {
2020
e2.getDep().setDid(8);
2121
e2.getDep().setDname("Acc");
2222
System.out.println(e1);
23+
2324
System.out.println(e2);
2425
//new Employee().getEid();
2526
System.out.println(e1 instanceof Cloneable);

0 commit comments

Comments
 (0)
0