if (segment1 instanceof LineString) {
return (LineString) segment1;
}
} else if (count > 0) {
boolean allLineString = true;
LineStringImpl lsi = new LineStringImpl();
LineString ls = null;
List retList = lsi.getControlPoints();
Object lastPoint = null;
List segList = null;
for (int i = 0; i < count && allLineString; i++) {
Object segment = curveSegments.get(0);
if (segment instanceof LineString) {