Skip to content

YY. ArcConnectorLine

覆盖物弧形连接线, 用来连接两个覆盖物,连线为弧线 基于 YY. Overlay

creation

  • constructor(src, dest, [style].[pro], [conf])

events

example

demo

js
var point1 = new YY.Point(
    lnglats[0],
    YY.Style.formatImage({
        markerFile: "./../assets/icons/0002.png"
    }), {}, {
        draggable: true
    }
);

var point2 = new YY.Point(
    lnglats[1],
    YY.Style.formatImage({
        markerFile: "./../assets/icons/0002.png"
    }), {}, {
        draggable: true
    }
);

var conLine = new YY.ArcConnectorLine(
    point1,
    point2,
    YY.Style.formatLine({
        lineColor: "red"
    })
);

vectorLayer.addOverlays([point1, point2, conLine]);

method

getSrcOverlay()

  • 获取开始的覆盖物连接点
  • 返回值: YY. Overlay

getDestOverlay()

  • 获取结束的覆盖物连接点
  • 返回值: YY. Overlay

animateShow(options, step)

  • 动态显示线
  • 参数
    • {Object} options: 动画配置
    • {function} step: 回调函数
  • 返回值: this

其他方法参考

YY. Overlay

This document is generated by vitepress and Edit by deyihu