Java Generic Deep Copy(三)

2014-11-24 03:19:36 · 作者: · 浏览: 6
copy = deepCopyUtil.deepCopy(simpleCircle); // deep copy the object.

assertFalse(simpleCircle == copy); // test that they are not equal.

// test that the circular references are in tact.

assertTrue(copy == copy.outerToInner.innerToOuter);

assertTrue(copy == copy.pointerToSelf);

}

}

摘自 snowdream