/** Detach All attached Axes. */ public void detachAxes() { int i; if (axis == null | axis.isEmpty()) return; for (i = 0; i < axis.size(); i++) { ((Axis) axis.elementAt(i)).detachAll(); ((Axis) axis.elementAt(i)).g2d = null; } axis.removeAllElements(); }
/** Detach All the DataSets from the class. */ public void detachDataSets() { DataSet d; int i; if (dataset == null | dataset.isEmpty()) return; for (i = 0; i < dataset.size(); i++) { d = ((DataSet) dataset.elementAt(i)); if (d.xaxis != null) d.xaxis.detachDataSet(d); if (d.yaxis != null) d.yaxis.detachDataSet(d); } dataset.removeAllElements(); }