Package com.googlecode.charts4j

Examples of com.googlecode.charts4j.Marker


    }

    @Test
    public void addFreeShapeMarker() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addFreeMarker(sm, 10, 20);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=@o,CD853F,0,0.1:0.2,13,-1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here


    }

    @Test
    public void addFreeTextMarker() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newTextMarker("charts4j", PERU, 13, Priority.HIGH);
        p.addFreeMarker(sm, 20, 10);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=@tcharts4j,CD853F,0,0.2:0.1,13,1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here

    }

    @Test
    public void test3() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addMarker(sm, 1, 5, 6, 1);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=o,CD853F,1,5,13,-1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here

    }

    @Test
    public void test5() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addMarker(sm, 1, 5, 6, 1);
        p.addMarker(Markers.newTextMarker("foobar", BLACK, 15), 7, 5, 6, 1);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=o,CD853F,1,5,13,-1|tfoobar,000000,7,5,15,0";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
View Full Code Here

    }

    @Test
    public void test7() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addMarker(sm, 1, 5, 10 ,2);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=o,CD853F,1,5:9:2,13,-1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here

    }

    @Test
    public void test8() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addMarker(sm, 1, 5, 6 ,2);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=o,CD853F,1,5,13,-1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here

    }

    @Test
    public void test9() {
        final ChartMarkersParameter p = new ChartMarkersParameter();
        final Marker sm = Markers.newShapeMarker(Shape.CIRCLE, PERU, 13, Priority.LOW);
        p.addMarkers(sm, 1);
        Logger.getLogger(Logger.GLOBAL_LOGGER_NAME).info(p.toURLParameterString());
        final String expectedString = "chm=o,CD853F,1,-1,13,-1";
        assertEquals("Junit error", expectedString, p.toURLParameterString());
    }
View Full Code Here

TOP

Related Classes of com.googlecode.charts4j.Marker

Copyright © 2018 www.massapicom. 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.