首页 / 浏览问题 / 移动GIS / 问题详情
用iServer发布了三维数据服务,如何在移动端访问发布的数据?
16EXP 2023年05月22日


使用产品:supermap imobile 11i for android (V11.0.1)
电脑操作系统:win10 x64
手机操作系统:Android 12

问题详情:开发了一个移动应用,之前一直使用拷贝在本地的离线数据,现在将其发布在iServer上,不知如何修改代码才能对发布的网络数据访问。

以下是加载本地离线数据时使用的代码。想问一下该如何修改才能访问发布的网络数据。

        workspace = new Workspace();
        info = new WorkspaceConnectionInfo();
        info.setServer(sdcard + "/SuperMap/data/scene/scene.sxwu");
        info.setType(WorkspaceType.SXWU);
        workspace.open(info);

        //场景 与工作空间相关联
        sceneControl = (SceneControl) findViewById(R.id.SceneControl);
        scene = sceneControl.getScene();
        scene.setWorkspace(workspace);
        //打开场景
        sceneName = workspace.getScenes().get(0);
        scene.open(sceneName);

1个回答

您好,可以用scene.open(java.lang.String iserverUrl, java.lang.String sceneName)

打开已经使用iServer发布的三维服务中指定名称的三维场景。
3,405EXP 2023年05月22日
...