Summary
Methods:
addMathModel |
添加数学模型到地理解决方案图层 |
destroy |
销毁图层。 |
getAllMathModels |
获取地理解决方案图层上的所有数学模型 |
getMathModelById |
根据数学模型的唯一标识符获取数学模型对象 |
getModelsByClassName |
根据数学模型的类名(ClassName)属性获取对应的数学模型数组 |
redraw |
图层重绘,当模型数据发生更新时,手动调用 |
removeAllMathModels |
移除地理解决方案图层的所有数学模型对象 |
removeMathModelById |
根据数学模型的唯一标识符移除地理解决方案图层上的数学模型对象 |
Constructor
new GeosolutionLayer(options)
地理解决方案图层的构造函数。
Parameters:
Name | Type | Description | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
|
Members
-
clampToGround
-
设置贴地状态
-
depthTest
-
获取图层的深度测试属性
return {Boolean} 深度测试属性- Overrides:
Methods
-
addMathModel(mathModel)
-
添加数学模型到地理解决方案图层
Parameters:
Name Type Description mathModel
module:geosolution/math~MathModel 数学模型对象
Throws:
-
当图层未添加到地图上时,抛出异常:"GeosolutionLayer-addMathMode:Please add this layer to map first!"。
-
当添加对象非MathModel类型时,抛出异常:"GeosolutionLayer-addMathModel:parameter must be instance of MathModel!"
-
-
destroy()
-
销毁图层。
-
getAllMathModels() → {Array.<module:geosolution/math~MathModel>}
-
获取地理解决方案图层上的所有数学模型
-
getMathModelById(id) → {module:geosolution/math~MathModel}
-
根据数学模型的唯一标识符获取数学模型对象
Parameters:
Name Type Description id
String 添加到地理解决方案图层上数学模型对象的唯一标识符
-
getModelsByClassName(className) → {Array.<module:geosolution/math~MathModel>}
-
根据数学模型的类名(ClassName)属性获取对应的数学模型数组
Parameters:
Name Type Description className
String 数学模型的类名
-
redraw()
-
图层重绘,当模型数据发生更新时,手动调用
-
removeAllMathModels(autoDestroy)
-
移除地理解决方案图层的所有数学模型对象
Parameters:
Name Type Default Description autoDestroy
Boolean true 是否自动销毁资源,默认为true
-
removeMathModelById(id, autoDestroy)
-
根据数学模型的唯一标识符移除地理解决方案图层上的数学模型对象
Parameters:
Name Type Default Description id
String 添加到地理解决方案图层上的数学模型对象的唯一标识符
autoDestroy
Boolean true 是否自动销毁资源,默认为true