G3DMapDoc Class

G3DMapDoc(option)

三维地图文档类

Fx构造函数

# new G3DMapDoc(option)

参数:
名称 类型 属性 默认值 描述
option Object

属性键值对,地图属性字段。

docName String <optional>
null

三维服务名称

gdbp String <optional>
null

图层的gdbp地址,多个图层用逗号分隔,使用该属性则地图服务名称失效

proj String <optional>
null

坐标系参数,输出的图层信息里的坐标为设置坐标系下对应的坐标,不设置则输出图层默认坐标系下的坐标。示例:设置proj='WGS1984_度',输出图层信息中坐标为 WGS1984_度 坐标

f String <optional>
json

回结果的格式,缺省xml(json / xml),base64_geometry:返回单个三维几何信息的流,并转为base64

guid String <optional>
newGuid()

唯一id,可缺省

encryptPassword String <optional>
null

服务密码

layerindex String <optional>
0

要查询的图层索引(多个请用','分隔)

geometryType String <optional>
null

几何类型(point3D,rect3D等)

geometry Object <optional>
null

几何类型的图形参数,现在只支持点x,y,z,distance

where String <optional>
null

查询条件(例如:id = 12)

structs Object <optional>

指定查询结果的结构,json规范(例如:structs={ IncludeAttribute:true | false, IncludeGeometry:true | false, IncludeWebGraphic :true |false})

page Number <optional>
0

返回的要素分页的页数,默认返回第0页

pageCount Number <optional>
20

要素结果集每页的记录数量,默认为20条/页

objectIds String <optional>
null

要查询的要素oid(多个请用','分隔)

orderField String <optional>
null

排序字段名称

rtnLabel Boolean <optional>
false

是否计算Label点

isAsc Boolean <optional>
false

按照字段进行排列时,是否升序排列

format String <optional>
json

回结果的格式,缺省xml(json / xml)

systemLib String <optional>
null

系统库名称或者guid

layerRenderIndex String <optional>
0

图层layerRenderIndex

作者:
  • 基础平台/产品2部 龚跃健

查看源代码 service/Igserver/G3D/G3DMapDoc.js, line 6

继承关系

类名

成员变量

string

# domain

请求使用的域名,基地址

Inherited From:

查看源代码 service/ServiceBase.js, line 30

方法

# GetDocInfo(option, onSuccess, onError)

获取指定三维地图文档的详细信息

参数:
名称 类型 属性 默认值 描述
option Object

属性键值对,地图属性字段。

docName String <optional>
null

【必选】三维服务名称

onSuccess function

成功回调函数。

onError function

失败回调函数。

查看源代码 service/Igserver/G3D/G3DMapDoc.js, line 254

Example
var mapdoc = new Zondy.Catalog.G3DMapDoc({
                ip: "192.168.176.40",
                port: "6163",
                docName: "shenzhenZT"
            });
     mapdoc.GetDocInfo(function(res){
                console.log('GetDocInfo');
                console.log(res)
            },false,false,function (error) {
                console.log(error)
            },false);

# GetDocList(onSuccess, onError)

获取服务器三维地图文档列表。

参数:
名称 类型 描述
onSuccess function

成功回调函数。

onError function

失败回调函数。

查看源代码 service/Igserver/G3D/G3DMapDoc.js, line 223

Example
var mapdoc = new Zondy.Catalog.G3DMapDoc({
                ip: "192.168.176.40",
                port: "6163"
            });
     mapdoc.GetDocList(function(res){
                console.log('GetDocList');
                console.log(res)
            },function (error) {
                console.log(error)
            });

# GetLayerInfo(option, onSuccess, onError)

获取指定三维地图文档图层的详细信息

参数:
名称 类型 属性 默认值 描述
option Object

属性键值对,地图属性字段。

gdbp String <optional>
null
proj String <optional>
null

坐标系参数,输出的图层信息里的坐标为设置坐标系下对应的坐标,不设置则输出图层默认坐标系下的坐标。示例:设置proj='WGS1984_度',输出图层信息中坐标为 WGS1984_度 坐标

f String <optional>
json

回结果的格式,缺省xml(json / xml),base64_geometry:返回单个三维几何信息的流,并转为base64

guid String <optional>
newGuid()

唯一id,可缺省

encryptPassword String <optional>
null

服务密码

onSuccess function

成功回调函数。

onError function

失败回调函数。

查看源代码 service/Igserver/G3D/G3DMapDoc.js, line 288

Example
var mapdoc = new Zondy.Catalog.G3DMapDoc({
                ip: "192.168.176.40",
                port: "6163",
                gdbp: "GDBP://MapGisLocal/深圳数据库/sfcls/深圳南山"
            });
     mapdoc.GetLayerInfo(function(res){
                console.log('GetLayerInfo');
                console.log(res)
            },false,false,function (error) {
                console.log(error)
            },false);

# SetSystemLibraryByDoc(option)

设置三维文档下图层系统库接口

参数:
名称 类型 属性 默认值 描述
option Object

属性键值对,地图属性字段。

docName String <optional>
null

三维服务名称

systemLib String <optional>
null

系统库名称或者guid

layerRenderIndex String <optional>
null

图层layerRenderIndex

f String <optional>
json

回结果的格式,缺省xml(json / xml),base64_geometry:返回单个三维几何信息的流,并转为base64

guid String <optional>
newGuid()

唯一id,可缺省

查看源代码 service/Igserver/G3D/G3DMapDoc.js, line 449

Example
var mapdoc = new Zondy.Catalog.G3DMapDoc({
                ip: "192.168.176.40",
                port: "6163",
                docName: "shenzhenZT",
                systemLib:"9cbd5f3b-3d69-46aa-8a6d-af8d0f9f621b",
                layerRenderIndex:2
            });
     mapdoc.SetSystemLibraryByDoc(function(res){
                console.log('SetSystemLibraryByDoc');
                console.log(res)
            },false,false,function (error) {
                console.log(error)
            },false);