Class Lines

java.lang.Object
cn.mapway.geo.geometry.Lines
All Implemented Interfaces:
com.google.gwt.user.client.rpc.IsSerializable, Serializable

public class Lines extends Object implements Serializable, com.google.gwt.user.client.rpc.IsSerializable
Line
Author:
zhangjianshe@gmail.com
See Also:
  • Constructor Details

    • Lines

      public Lines()
  • Method Details

    • add

      public void add(Line line)
    • getSize

      public int getSize()
    • getLine

      public Line getLine(int index)
    • getExtend

      public GeoExtend getExtend()
    • center

      public GeoPoint center()
    • forceRightHandRule

      public void forceRightHandRule()
      将多边形强制转化为 右手规则 外边框是 逆时针方向 内部是顺时针方向 算法参考 https://github.com/mapbox/geojson-rewind if (rings.length === 0) return;

      rewindRing(rings[0], outer); for (var i = 1; i < rings.length; i++) { rewindRing(rings[i], !outer); }