本文整理汇总了Java中org.jfree.data.KeyedValues2D类的典型用法代码示例。如果您正苦于以下问题:Java KeyedValues2D类的具体用法?Java KeyedValues2D怎么用?Java KeyedValues2D使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
KeyedValues2D类属于org.jfree.data包,在下文中一共展示了KeyedValues2D类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setColours
import org.jfree.data.KeyedValues2D; //导入依赖的package包/类
protected void setColours(final AbstractRenderer renderer, final KeyedValues2D dataset) {
final int tmpRowDim = dataset.getRowCount();
for (int i = 0; i < tmpRowDim; i++) {
final Comparable<?> tmpKey = dataset.getRowKey(i);
final Paint tmpPaint = this.getColour(tmpKey);
renderer.setSeriesPaint(i, tmpPaint);
}
}
示例2: writeKeyedValues2D
import org.jfree.data.KeyedValues2D; //导入依赖的package包/类
/**
* Returns a string containing the data in JSON format. The format is...
* <br><br>
* Note that this method can be used with instances of
* {@link CategoryDataset}.
*
* @param data the data ({@code null} not permitted).
*
* @return A string in JSON format.
*/
public static String writeKeyedValues2D(KeyedValues2D data) {
Args.nullNotPermitted(data, "data");
StringWriter sw = new StringWriter();
try {
writeKeyedValues2D(data, sw);
} catch (IOException ex) {
throw new RuntimeException(ex);
}
return sw.toString();
}