How to draw a polyline

OpenMap4u om4u = new OpenMap4u();
...
SetAreaOfInterestOrDrawOrWriteable myCanvas =  om4u.getCanvas(4, 1);
...
Polyline myPolyline = om4u.get(Polyline.class);
Set the polyline to draw
myPolyline.lineTo(0.25,.125).lineTo(1.0, 0.75).lineTo(2.0, 0.125).lineTo(3,0.5).lineTo(3.75,0.15);
Draw it:
myCanvas.draw(myPolyline);
Write the result
myCanvas.write("C:/temp/myPolyline.png");
Which results in the following output.
the result
But wait you can do it much faster and simpler with the fluent builder pattern
myCanvas.draw(
    om4u.get(Text.class).text("Hello world").center(0.5,0.25)
  ).write("myPolyline.png");