use of com.revolsys.geometry.model.ClockDirection in project com.revolsys.open by revolsys.
the class OracleSdoGeometryJdbcFieldDefinition method toSodAddPolygonRing.
private int toSodAddPolygonRing(int offset, final int[] elemInfo, final int elemIndex, final int elemType, final int axisCount, final double[] coordinates, final ClockDirection expectedRingOrientation, final LinearRing ring) {
elemInfo[elemIndex] = offset + 1;
// Exterior counter clockwise
elemInfo[elemIndex + 1] = elemType;
elemInfo[elemIndex + 2] = 1;
final ClockDirection ringOrientation = ring.getClockDirection();
if (ringOrientation == expectedRingOrientation) {
offset = ring.copyCoordinates(axisCount, NAN_VALUE, coordinates, offset);
} else {
offset = ring.copyCoordinatesReverse(axisCount, NAN_VALUE, coordinates, offset);
}
return offset;
}
Aggregations