1 89 90 package org.jfree.chart.renderer.category; 91 92 import java.awt.Font ; 93 import java.awt.Graphics2D ; 94 import java.awt.Paint ; 95 import java.awt.Shape ; 96 import java.awt.Stroke ; 97 import java.awt.geom.Rectangle2D ; 98 99 import org.jfree.chart.LegendItem; 100 import org.jfree.chart.LegendItemSource; 101 import org.jfree.chart.axis.CategoryAxis; 102 import org.jfree.chart.axis.ValueAxis; 103 import org.jfree.chart.event.RendererChangeEvent; 104 import org.jfree.chart.event.RendererChangeListener; 105 import org.jfree.chart.labels.CategoryItemLabelGenerator; 106 import org.jfree.chart.labels.CategoryToolTipGenerator; 107 import org.jfree.chart.labels.ItemLabelPosition; 108 import org.jfree.chart.plot.CategoryMarker; 109 import org.jfree.chart.plot.CategoryPlot; 110 import org.jfree.chart.plot.Marker; 111 import org.jfree.chart.plot.PlotRenderingInfo; 112 import org.jfree.chart.urls.CategoryURLGenerator; 113 import org.jfree.data.Range; 114 import org.jfree.data.category.CategoryDataset; 115 116 136 137 public interface CategoryItemRenderer extends LegendItemSource { 138 139 147 public int getPassCount(); 148 149 156 public CategoryPlot getPlot(); 157 158 165 public void setPlot(CategoryPlot plot); 166 167 172 public void addChangeListener(RendererChangeListener listener); 173 174 179 public void removeChangeListener(RendererChangeListener listener); 180 181 190 public Range findRangeBounds(CategoryDataset dataset); 191 192 207 public CategoryItemRendererState initialise(Graphics2D g2, 208 Rectangle2D dataArea, 209 CategoryPlot plot, 210 int rendererIndex, 211 PlotRenderingInfo info); 212 213 222 public boolean getItemVisible(int series, int item); 223 224 232 public boolean isSeriesVisible(int series); 233 234 241 public Boolean getSeriesVisible(); 242 243 251 public void setSeriesVisible(Boolean visible); 252 253 262 public void setSeriesVisible(Boolean visible, boolean notify); 263 264 271 public Boolean getSeriesVisible(int series); 272 273 280 public void setSeriesVisible(int series, Boolean visible); 281 282 291 public void setSeriesVisible(int series, Boolean visible, boolean notify); 292 293 298 public boolean getBaseSeriesVisible(); 299 300 306 public void setBaseSeriesVisible(boolean visible); 307 308 315 public void setBaseSeriesVisible(boolean visible, boolean notify); 316 317 319 327 public boolean isSeriesVisibleInLegend(int series); 328 329 337 public Boolean getSeriesVisibleInLegend(); 338 339 347 public void setSeriesVisibleInLegend(Boolean visible); 348 349 358 public void setSeriesVisibleInLegend(Boolean visible, boolean notify); 359 360 370 public Boolean getSeriesVisibleInLegend(int series); 371 372 379 public void setSeriesVisibleInLegend(int series, Boolean visible); 380 381 390 public void setSeriesVisibleInLegend(int series, Boolean visible, 391 boolean notify); 392 393 398 public boolean getBaseSeriesVisibleInLegend(); 399 400 406 public void setBaseSeriesVisibleInLegend(boolean visible); 407 408 415 public void setBaseSeriesVisibleInLegend(boolean visible, boolean notify); 416 417 418 420 428 public Paint getItemPaint(int row, int column); 429 430 437 public void setPaint(Paint paint); 438 439 446 public Paint getSeriesPaint(int series); 447 448 455 public void setSeriesPaint(int series, Paint paint); 456 457 462 public Paint getBasePaint(); 463 464 470 public void setBasePaint(Paint paint); 471 472 474 482 public Paint getItemOutlinePaint(int row, int column); 483 484 489 public void setOutlinePaint(Paint paint); 490 491 498 public Paint getSeriesOutlinePaint(int series); 499 500 507 public void setSeriesOutlinePaint(int series, Paint paint); 508 509 514 public Paint getBaseOutlinePaint(); 515 516 522 public void setBaseOutlinePaint(Paint paint); 523 524 526 534 public Stroke getItemStroke(int row, int column); 535 536 542 public void setStroke(Stroke stroke); 543 544 551 public Stroke getSeriesStroke(int series); 552 553 560 public void setSeriesStroke(int series, Stroke stroke); 561 562 567 public Stroke getBaseStroke(); 568 569 574 public void setBaseStroke(Stroke stroke); 575 576 578 589 public Stroke getItemOutlineStroke(int row, int column); 590 591 597 public void setOutlineStroke(Stroke stroke); 598 599 606 public Stroke getSeriesOutlineStroke(int series); 607 608 615 public void setSeriesOutlineStroke(int series, Stroke stroke); 616 617 622 public Stroke getBaseOutlineStroke(); 623 624 630 public void setBaseOutlineStroke(Stroke stroke); 631 632 634 642 public Shape getItemShape(int row, int column); 643 644 650 public void setShape(Shape shape); 651 652 659 public Shape getSeriesShape(int series); 660 661 668 public void setSeriesShape(int series, Shape shape); 669 670 675 public Shape getBaseShape(); 676 677 683 public void setBaseShape(Shape shape); 684 685 687 696 public boolean isItemLabelVisible(int row, int column); 697 698 706 public boolean isSeriesItemLabelsVisible(int series); 707 708 714 public void setItemLabelsVisible(boolean visible); 715 716 722 public void setItemLabelsVisible(Boolean visible); 723 724 733 public void setItemLabelsVisible(Boolean visible, boolean notify); 734 735 741 public void setSeriesItemLabelsVisible(int series, boolean visible); 742 743 749 public void setSeriesItemLabelsVisible(int series, Boolean visible); 750 751 760 public void setSeriesItemLabelsVisible(int series, Boolean visible, 761 boolean notify); 762 763 768 public Boolean getBaseItemLabelsVisible(); 769 770 775 public void setBaseItemLabelsVisible(boolean visible); 776 777 782 public void setBaseItemLabelsVisible(Boolean visible); 783 784 792 public void setBaseItemLabelsVisible(Boolean visible, boolean notify); 793 794 796 804 public CategoryItemLabelGenerator getItemLabelGenerator(int series, 805 int item); 806 807 814 public CategoryItemLabelGenerator getSeriesItemLabelGenerator(int series); 815 816 823 public void setItemLabelGenerator(CategoryItemLabelGenerator generator); 824 825 832 public void setSeriesItemLabelGenerator( 833 int series, CategoryItemLabelGenerator generator); 834 835 840 public CategoryItemLabelGenerator getBaseItemLabelGenerator(); 841 842 848 public void setBaseItemLabelGenerator(CategoryItemLabelGenerator generator); 849 850 852 862 public CategoryToolTipGenerator getToolTipGenerator(int row, int column); 863 864 870 public CategoryToolTipGenerator getToolTipGenerator(); 871 872 879 public void setToolTipGenerator(CategoryToolTipGenerator generator); 880 881 889 public CategoryToolTipGenerator getSeriesToolTipGenerator(int series); 890 891 899 public void setSeriesToolTipGenerator(int series, 900 CategoryToolTipGenerator generator); 901 902 907 public CategoryToolTipGenerator getBaseToolTipGenerator(); 908 909 916 public void setBaseToolTipGenerator(CategoryToolTipGenerator generator); 917 918 920 928 public Font getItemLabelFont(int row, int column); 929 930 936 public Font getItemLabelFont(); 937 938 946 public void setItemLabelFont(Font font); 947 948 955 public Font getSeriesItemLabelFont(int series); 956 957 964 public void setSeriesItemLabelFont(int series, Font font); 965 966 972 public Font getBaseItemLabelFont(); 973 974 980 public void setBaseItemLabelFont(Font font); 981 982 984 992 public Paint getItemLabelPaint(int row, int column); 993 994 1001 public Paint getItemLabelPaint(); 1002 1003 1009 public void setItemLabelPaint(Paint paint); 1010 1011 1018 public Paint getSeriesItemLabelPaint(int series); 1019 1020 1027 public void setSeriesItemLabelPaint(int series, Paint paint); 1028 1029 1034 public Paint getBaseItemLabelPaint(); 1035 1036 1042 public void setBaseItemLabelPaint(Paint paint); 1043 1044 1046 1054 public ItemLabelPosition getPositiveItemLabelPosition(int row, int column); 1055 1056 1061 public ItemLabelPosition getPositiveItemLabelPosition(); 1062 1063 1071 public void setPositiveItemLabelPosition(ItemLabelPosition position); 1072 1073 1080 public void setPositiveItemLabelPosition(ItemLabelPosition position, 1081 boolean notify); 1082 1083 1090 public ItemLabelPosition getSeriesPositiveItemLabelPosition(int series); 1091 1092 1099 public void setSeriesPositiveItemLabelPosition(int series, 1100 ItemLabelPosition position); 1101 1102 1111 public void setSeriesPositiveItemLabelPosition(int series, 1112 ItemLabelPosition position, 1113 boolean notify); 1114 1115 1120 public ItemLabelPosition getBasePositiveItemLabelPosition(); 1121 1122 1127 public void setBasePositiveItemLabelPosition(ItemLabelPosition position); 1128 1129 1136 public void setBasePositiveItemLabelPosition(ItemLabelPosition position, 1137 boolean notify); 1138 1139 1140 1142 1152 public ItemLabelPosition getNegativeItemLabelPosition(int row, int column); 1153 1154 1159 public ItemLabelPosition getNegativeItemLabelPosition(); 1160 1161 1169 public void setNegativeItemLabelPosition(ItemLabelPosition position); 1170 1171 1179 public void setNegativeItemLabelPosition(ItemLabelPosition position, 1180 boolean notify); 1181 1182 1189 public ItemLabelPosition getSeriesNegativeItemLabelPosition(int series); 1190 1191 1198 public void setSeriesNegativeItemLabelPosition(int series, 1199 ItemLabelPosition position); 1200 1201 1210 public void setSeriesNegativeItemLabelPosition(int series, 1211 ItemLabelPosition position, 1212 boolean notify); 1213 1214 1219 public ItemLabelPosition getBaseNegativeItemLabelPosition(); 1220 1221 1227 public void setBaseNegativeItemLabelPosition(ItemLabelPosition position); 1228 1229 1236 public void setBaseNegativeItemLabelPosition(ItemLabelPosition position, 1237 boolean notify); 1238 1239 1241 1249 public CategoryURLGenerator getItemURLGenerator(int series, int item); 1250 1251 1258 public CategoryURLGenerator getSeriesItemURLGenerator(int series); 1259 1260 1265 public void setItemURLGenerator(CategoryURLGenerator generator); 1266 1267 1273 public void setSeriesItemURLGenerator(int series, 1274 CategoryURLGenerator generator); 1275 1276 1281 public CategoryURLGenerator getBaseItemURLGenerator(); 1282 1283 1288 public void setBaseItemURLGenerator(CategoryURLGenerator generator); 1289 1290 1298 public LegendItem getLegendItem(int datasetIndex, int series); 1299 1300 1307 public void drawBackground(Graphics2D g2, 1308 CategoryPlot plot, 1309 Rectangle2D dataArea); 1310 1311 1318 public void drawOutline(Graphics2D g2, 1319 CategoryPlot plot, 1320 Rectangle2D dataArea); 1321 1322 1336 public void drawItem(Graphics2D g2, 1337 CategoryItemRendererState state, 1338 Rectangle2D dataArea, 1339 CategoryPlot plot, 1340 CategoryAxis domainAxis, 1341 ValueAxis rangeAxis, 1342 CategoryDataset dataset, 1343 int row, 1344 int column, 1345 int pass); 1346 1347 1356 public void drawDomainGridline(Graphics2D g2, 1357 CategoryPlot plot, 1358 Rectangle2D dataArea, 1359 double value); 1360 1361 1371 public void drawRangeGridline(Graphics2D g2, 1372 CategoryPlot plot, 1373 ValueAxis axis, 1374 Rectangle2D dataArea, 1375 double value); 1376 1377 1387 public void drawDomainMarker(Graphics2D g2, 1388 CategoryPlot plot, 1389 CategoryAxis axis, 1390 CategoryMarker marker, 1391 Rectangle2D dataArea); 1392 1393 1403 public void drawRangeMarker(Graphics2D g2, 1404 CategoryPlot plot, 1405 ValueAxis axis, 1406 Marker marker, 1407 Rectangle2D dataArea); 1408 1409} 1410 | Popular Tags |