调用ShapefileFeatureTable.getGeometryType返回几何类型

调用ShapefileFeatureTable.getGeometryType返回几何类型是Unknown
已邀请:

张赛

赞同来自: 爱的废墟

【解决办法】:
这一问题和ArcGIS Runtime SDK 100系列中的Loadable异步加载机制有关系,需要在加载完成的回调函数中进行判断


shapefileFeatureTable = new ShapefileFeatureTable(Environment.getExternalStorageDirectory().getAbsolutePath() + /ArcGIS/shapefile/center.shp);
shapefileFeatureTable.loadAsync();
shapefileFeatureTable.addDoneLoadingListener(new Runnable() {
@Override
public void run() {
System.out.println(shapefileFeatureTable.getGeometryType());
}
});

要回复问题请先登录注册