Logo Search packages:      
Sourcecode: libjfreechart-java version File versions  Download package

int org::jfree::chart::plot::XYPlot::indexOf ( XYDataset  dataset  )  [inline, inherited]

Returns the index of the specified dataset, or -1 if the dataset does not belong to the plot.

Parameters:
dataset the dataset (null not permitted).
Returns:
The index.

Definition at line 1334 of file XYPlot.java.

Referenced by org::jfree::chart::renderer::xy::XYBarRenderer::initialise().

                                          {
        int result = -1;
        for (int i = 0; i < this.datasets.size(); i++) {
            if (dataset == this.datasets.get(i)) {
                result = i;
                break;
            }
        }
        return result;
    }


Generated by  Doxygen 1.6.0   Back to index