Examples of removeColumn()


Examples of org.jfree.data.KeyedObjects2D.removeColumn()

     */
    public void testRemoveColumnByKey() {
        KeyedObjects2D data = new KeyedObjects2D();
        data.setObject("Obj1", "R1", "C1");
        data.setObject("Obj2", "R2", "C2");
        data.removeColumn("C2");
        assertEquals(1, data.getColumnCount());
        assertEquals("Obj1", data.getObject(0, 0));

        // try unknown column key
        boolean pass = false;
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertEquals("Obj1", data.getObject(0, 0));

        // try unknown column key
        boolean pass = false;
        try {
            data.removeColumn("XXX");
        }
        catch (UnknownKeyException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertTrue(pass);

        // try null column key
        pass = false;
        try {
            data.removeColumn(null);
        }
        catch (IllegalArgumentException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

     */
    public void testRemoveColumnByIndex() {
        KeyedObjects2D data = new KeyedObjects2D();
        data.setObject("Obj1", "R1", "C1");
        data.setObject("Obj2", "R2", "C2");
        data.removeColumn(0);
        assertEquals(1, data.getColumnCount());
        assertEquals("Obj2", data.getObject(1, 0));

        // try negative column index
        boolean pass = false;
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertEquals("Obj2", data.getObject(1, 0));

        // try negative column index
        boolean pass = false;
        try {
            data.removeColumn(-1);
        }
        catch (IndexOutOfBoundsException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertTrue(pass);

        // try column index too high
        pass = false;
        try {
            data.removeColumn(data.getColumnCount());
        }
        catch (IndexOutOfBoundsException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

     */
    public void testRemoveColumnByKey() {
        KeyedObjects2D data = new KeyedObjects2D();
        data.setObject("Obj1", "R1", "C1");
        data.setObject("Obj2", "R2", "C2");
        data.removeColumn("C2");
        assertEquals(1, data.getColumnCount());
        assertEquals("Obj1", data.getObject(0, 0));

        // try unknown column key
        boolean pass = false;
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertEquals("Obj1", data.getObject(0, 0));

        // try unknown column key
        boolean pass = false;
        try {
            data.removeColumn("XXX");
        }
        catch (UnknownKeyException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.KeyedObjects2D.removeColumn()

        assertTrue(pass);

        // try null column key
        pass = false;
        try {
            data.removeColumn(null);
        }
        catch (IllegalArgumentException e) {
            pass = true;
        }
        assertTrue(pass);
View Full Code Here

Examples of org.jfree.data.category.DefaultCategoryDataset.removeColumn()

     */
    public void testBug1835955() {
        DefaultCategoryDataset d = new DefaultCategoryDataset();
        d.addValue(1.0, "R1", "C1");
        d.addValue(2.0, "R2", "C2");
        d.removeColumn("C2");
        d.addValue(3.0, "R2", "C2");
        assertEquals(3.0, d.getValue("R2", "C2").doubleValue(), EPSILON);
    }

    /**
 
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.