Java Code Examples for org.jfree.chart.renderer.category.CategoryItemRenderer#setSeriesURLGenerator()

The following examples show how to use org.jfree.chart.renderer.category.CategoryItemRenderer#setSeriesURLGenerator() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: AbstractCategoryItemRendererTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that the getSeriesURLGenerator() method behaves as expected.
 */
public void testGetSeriesURLGenerator() {
    CategoryItemRenderer r = new BarRenderer();
    assertNull(r.getSeriesURLGenerator(2));
    r.setSeriesURLGenerator(2, new StandardCategoryURLGenerator());
    assertNotNull(r.getSeriesURLGenerator(2));
    r.setSeriesURLGenerator(2, null);
    assertNull(r.getSeriesURLGenerator(2));
    r.setBaseURLGenerator(new StandardCategoryURLGenerator());
    assertNull(r.getSeriesURLGenerator(2));
}
 
Example 2
Source File: BarChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 3
Source File: LineChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 4
Source File: GanttChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 5
Source File: AreaChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 6
Source File: WaterfallChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 7
Source File: StackedBarChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 8
Source File: LineChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 9
Source File: BarChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 10
Source File: StackedBarChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0);
    assertTrue(url2 == url1);
}
 
Example 11
Source File: StackedBarChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 12
Source File: LineChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 13
Source File: BarChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 14
Source File: StackedAreaChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 15
Source File: GanttChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 16
Source File: AreaChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 17
Source File: WaterfallChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 18
Source File: StackedBarChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 19
Source File: LineChartTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}
 
Example 20
Source File: BarChart3DTests.java    From astor with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Check that setting a URL generator for a series does override the
 * default generator.
 */
public void testSetSeriesURLGenerator() {
    CategoryPlot plot = (CategoryPlot) this.chart.getPlot();
    CategoryItemRenderer renderer = plot.getRenderer();
    StandardCategoryURLGenerator url1
            = new StandardCategoryURLGenerator();
    renderer.setSeriesURLGenerator(0, url1);
    CategoryURLGenerator url2 = renderer.getURLGenerator(0, 0, false);
    assertTrue(url2 == url1);
}