免费视频|新人指南|投诉删帖|广告合作|地信网APP下载

查看: 1844|回复: 2
收起左侧

[资料] ArcGIS Server Flex实现BS下数据编辑

[复制链接]

7658

主题

1160

铜板

2299

好友

技术员

为地信喝彩!

积分
106249
QQ
发表于 2012-12-14 19:03 | 显示全部楼层 |阅读模式

到来的arcgis 10,据说已经提供了数据修改的REST接口,但远水解不了近渴,通过flex客户端实现用户录入数据仍然是一个棘手的问题,本文提供了一种思路。
以点数据的录入为例:
arcgis服务器端通过AO实现数据的插入
public void savePoint(double x,double y) throws utomationException,IOException
{
IServerContext serverContext = getServerContext(ARCGIS_SERVER_NAME,ARCGIS_SERVER_USER,ARCGIS_SERVER_PASSWORD,ARCGIS_MAP_NAME,ARCGIS_SERVICE_NAME);
MapServer mapServer = (MapServer) serverContext.getServerObject();
ILayer editLayer = mapServer.getLayer("", LAYERID);
IFeatureLayer featureLayer = new IFeatureLayerProxy(editLayer);
IFeatureClass featureClass = featureLayer.getFeatureClass();
IFeature feature = featureClass.createFeature();
IPoint point = (IPoint)serverContext.createObject(Point.getClsid());
point.setX(x);
point.setY(y);
feature.setShapeByRef(point);
feature.store();
serverContext.releaseContext();
地质啷http://weibo.com/943569550

0

主题

613

铜板

2

好友

助理工程师

Rank: 5Rank: 5

积分
192
发表于 2013-7-25 10:11 | 显示全部楼层
学习一下,谢谢分享

评分

参与人数 1铜板 +1 收起 理由
admin + 1 亲,你好快哦~~~

查看全部评分

回复 支持 反对

使用道具 举报

37

主题

2万

铜板

111

好友

钻石会员

Rank: 26Rank: 26Rank: 26Rank: 26Rank: 26Rank: 26Rank: 26

积分
5776
发表于 2022-2-9 20:59 | 显示全部楼层
学习学习,谢谢分享
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

在线客服
快速回复 返回顶部 返回列表