List of usage examples for org.jfree.data.gantt Task clone
@Override public Object clone() throws CloneNotSupportedException
From source file:org.jfree.data.gantt.TaskTest.java
/** * Confirm that cloning works.//from www . java 2 s . c o m */ @Test public void testCloning() throws CloneNotSupportedException { Task t1 = new Task("T", new Date(1), new Date(2)); Task t2 = (Task) t1.clone(); assertTrue(t1 != t2); assertTrue(t1.getClass() == t2.getClass()); assertTrue(t1.equals(t2)); }