标记构造函数
Name | Type | Description |
---|---|---|
dataSource |
DataSource | 数据源,标记对象会被添加入其中 |
styleOption |
BillboardGraphics.ConstructorOptions | 标记对象参数 |
option.image |
string | 标记图片URI |
Methods
添加单个标记
Name | Type | Description |
---|---|---|
id |
string | 指定标记的id,方便后续更新等操作,在一个标记实例里需要唯一 |
position |
Array.<number> | 要标记的点坐标 |
styleOption |
BillboardGraphics.ConstructorOptions | 标记对象参数 |
option.image |
string | 标记图片URI |
properties |
PropertyBag | 实体附属属性 |
name |
string | 实体名 |
Returns:
成功添加的标注id
添加单个标记
Name | Type | Description |
---|---|---|
id |
string | 指定标记的id,方便后续更新等操作,在一个标记实例里需要唯一 |
position |
Array.<number> | 要标记的点坐标 |
styleOption |
BillboardGraphics.ConstructorOptions | 标记对象参数 |
option.image |
string | 标记图片URI |
properties |
PropertyBag | 实体附属属性 |
name |
string | 实体名 |
Returns:
成功添加的标注id
隐藏所有标注
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要隐藏标注的id数组,没有时隐藏所有 |
隐藏所有标注
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要隐藏标注的id数组,没有时隐藏所有 |
删除标记
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要删除标注的id数组,没有时删除所有 |
Returns:
删除标记数组,成功删除status值为true, 否则为false
删除标记
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要删除标注的id数组,没有时删除所有 |
Returns:
删除标记数组,成功删除status值为true, 否则为false
显示所有标注
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要显示标注的id数组,没有时显示所有 |
显示所有标注
Name | Type | Description |
---|---|---|
ids |
Array.<string> | 要显示标注的id数组,没有时显示所有 |
更新标记
Name | Type | Description |
---|---|---|
id |
string | 要更新的标记id |
position |
Array.<number> | 更新后的位置坐标 |
option |
BillboardGraphics.ConstructorOptions | 更新后的样式属性 |
更新标记
Name | Type | Description |
---|---|---|
id |
string | 要更新的标记id |
position |
Array.<number> | 更新后的位置坐标 |
option |
BillboardGraphics.ConstructorOptions | 更新后的样式属性 |