用了2年多java了.还是第一次出现直接崩溃的系统bug.
控制台输出
写道
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x075132fe, pid=3768, tid=2532
#
# JRE version: 6.0_15-b03
# Java VM: Java HotSpot(TM) Client VM (14.1-b02 mixed mode, sharing windows-x86 )
# Problematic frame:
# C [SOGOUPY.IME+0x432fe]
#
# An error report file with more information is saved as:
# D:\Backup\�ҵ��ĵ�\NetBeansProjects\jfreechartTest\hs_err_pid3768.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x075132fe, pid=3768, tid=2532
#
# JRE version: 6.0_15-b03
# Java VM: Java HotSpot(TM) Client VM (14.1-b02 mixed mode, sharing windows-x86 )
# Problematic frame:
# C [SOGOUPY.IME+0x432fe]
#
# An error report file with more information is saved as:
# D:\Backup\�ҵ��ĵ�\NetBeansProjects\jfreechartTest\hs_err_pid3768.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
产生原因是在做jfreechart demo的时候.修改图表标题为中文的时候,点解确定.或者没修改点击退出.程序直接退出
例子代码
package jfreecharttest;
import org.jfree.chart.ChartFactory;
import org.jfree.chart.ChartPanel;
import org.jfree.chart.JFreeChart;
import org.jfree.chart.axis.CategoryAxis;
import org.jfree.chart.axis.CategoryLabelPositions;
import org.jfree.chart.plot.CategoryPlot;
import org.jfree.chart.plot.PlotOrientation;
import org.jfree.chart.renderer.category.BarRenderer3D;
import org.jfree.data.category.CategoryDataset;
import org.jfree.data.general.DatasetUtilities;
import org.jfree.ui.ApplicationFrame;
import org.jfree.ui.RefineryUtilities;
public class BarChart3DDemo1 extends ApplicationFrame {
public BarChart3DDemo1(final String title) {
super(title);
final CategoryDataset dataset = createDataset();
final JFreeChart chart = createChart(dataset);
final ChartPanel chartPanel = new ChartPanel(chart);
chartPanel.setPreferredSize(new java.awt.Dimension(500, 270));
setContentPane(chartPanel);
}
private CategoryDataset createDataset() {
final double[][] data = new double[][]{{10.0, 4.0, 15.0, 14.0},
{-5.0, -7.0, 14.0, -3.0},
{6.0, 17.0, -12.0, 7.0},
{7.0, 15.0, 11.0, 0.0},
{-8.0, -6.0, 10.0, -9.0},
{9.0, 8.0, 0.0, 6.0},
{-10.0, 9.0, 7.0, 7.0},
{11.0, 13.0, 9.0, 9.0},
{-3.0, 7.0, 11.0, -10.0}};
return DatasetUtilities.createCategoryDataset("Series ", "Category ", data);
}
private JFreeChart createChart(final CategoryDataset dataset) {
final JFreeChart chart = ChartFactory.createBarChart3D(
"3D Bar Chart Demo", // chart title
"Category", // domain axis label
"Value", // range axis label
dataset, // data
PlotOrientation.VERTICAL, // orientation
true, // include legend
true, // tooltips
false // urls
);
final CategoryPlot plot = chart.getCategoryPlot();
final CategoryAxis axis = plot.getDomainAxis();
axis.setCategoryLabelPositions(
CategoryLabelPositions.createUpRotationLabelPositions(Math.PI / 8.0));
final BarRenderer3D renderer = (BarRenderer3D) plot.getRenderer();
renderer.setDrawBarOutline(false);
return chart;
}
public static void main(final String[] args) {
final BarChart3DDemo1 demo = new BarChart3DDemo1("3D Bar Chart Demo 1");
RefineryUtilities.centerFrameOnScreen(demo);
demo.pack();
demo.setVisible(true);
}
}
jfreechart是1.0.13
依赖的jar包
产生bug截图.貌似je上传的文件下载不了...图片显示不了..
btw:这是jfreechart的bug还是java的bug呢?控制台输出的让我去sun的主页报告..