Example usage for org.jfree.data.general DefaultKeyedValueDataset updateValue

List of usage examples for org.jfree.data.general DefaultKeyedValueDataset updateValue

Introduction

In this page you can find the example usage for org.jfree.data.general DefaultKeyedValueDataset updateValue.

Prototype

public void updateValue(Number value) 

Source Link

Document

Updates the value.

Usage

From source file:org.jfree.data.general.DefaultKeyedValueDatasetTest.java

/**
 * Confirm that the clone is independent of the original.
 *//*from  ww  w  . j  a va  2 s.co m*/
@Test
public void testCloneIndependence() throws CloneNotSupportedException {
    DefaultKeyedValueDataset d1 = new DefaultKeyedValueDataset("Key", new Double(10.0));
    DefaultKeyedValueDataset d2 = (DefaultKeyedValueDataset) d1.clone();
    assertTrue(d1.equals(d2));
    d2.updateValue(new Double(99.9));
    assertFalse(d1.equals(d2));
    d2.updateValue(new Double(10.0));
    assertTrue(d1.equals(d2));
}