System.out.println("Extracting point at position 1.5 offset -0.5: " + line.extractPoint(1.5, -0.5));
System.out.println("Extracting point at position " + length + ": " + line.extractPoint(length));
System.out.println("Extracting point at position " + (length / 2) + ": " + line.extractPoint(length / 2));
System.out.println("Extracting line from position 0.1 to 0.2: " + line.extractLine(0.1, 0.2));
System.out.println("Extracting line from position 0.0 to " + (length / 2) + ": " + line.extractLine(0, length / 2));
LocationIndexedLine pline = new LocationIndexedLine(geometry);
System.out.println("Have LocationIndexedLine: " + pline);
System.out.println("Have start index: " + pline.getStartIndex());
System.out.println("Have end index: " + pline.getEndIndex());
System.out.println("Extracting point at start: " + pline.extractPoint(pline.getStartIndex()));
System.out.println("Extracting point at end: " + pline.extractPoint(pline.getEndIndex()));
System.out.println("Extracting point at start offset 0.5: " + pline.extractPoint(pline.getStartIndex(), 0.5));
System.out.println("Extracting point at end offset 0.5: " + pline.extractPoint(pline.getEndIndex(), 0.5));
}