1 43 44 package org.jfree.chart.entity; 45 46 import java.awt.Shape ; 47 import java.io.Serializable ; 48 49 54 public class ContourEntity extends ChartEntity 55 implements Cloneable , Serializable { 56 57 58 private static final long serialVersionUID = 1249570520505992847L; 59 60 61 private int index = -1; 62 63 69 public ContourEntity(Shape area, String toolTipText) { 70 super(area, toolTipText); 71 } 72 73 80 public ContourEntity(Shape area, String toolTipText, String urlText) { 81 super(area, toolTipText, urlText); 82 } 83 84 89 public int getIndex() { 90 return this.index; 91 } 92 93 98 public void setIndex(int index) { 99 this.index = index; 100 } 101 102 109 public boolean equals(Object obj) { 110 if (obj == this) { 111 return true; 112 } 113 if (obj instanceof ContourEntity && super.equals(obj)) { 114 ContourEntity ce = (ContourEntity) obj; 115 if (this.index != ce.index) { 116 return false; 117 } 118 return true; 119 } 120 return false; 121 } 122 123 130 public Object clone() throws CloneNotSupportedException { 131 return super.clone(); 132 } 133 134 } 135 | Popular Tags |