///<summary> ///根据给定格式的投影参考文本 创建相应的坐标系统 ///</summary> /// <param name="eStrType">EVSpatialReferenceStrTypes文本格式</param> /// <param name="strReference">空间参考的字符串描述</param> /// <returns>EarthView::World::Spatial::Utility::CSpatialReference*空间参考指针</returns> public static EarthView.World.Spatial.Utility.SpatialReference CreateCoordSys(EarthView.World.Spatial.Utility.EVSPATIALREFERENCESTRINGTYPE eStrType, string pszReference) { IntPtr __ptr = EarthView_World_Spatial_Utility_CCoordinateSystemFactory_createCoordSys_CSpatialReference_EVSpatialReferenceStringType_EVString(eStrType, pszReference); if (__ptr == IntPtr.Zero) { return(null); } EarthView.World.Spatial.Utility.SpatialReference csObj = new EarthView.World.Spatial.Utility.SpatialReference(CreatedWhenConstruct.CWC_NotToCreate); csObj.BindNativeObject(__ptr, "CSpatialReference"); csObj.Delegate = true; IClassFactory csObjClassFactory = GlobalClassFactoryMap.Get(csObj.GetCppInstanceTypeName()); if (csObjClassFactory != null) { csObj.Delegate = true; csObj = csObjClassFactory.Create() as EarthView.World.Spatial.Utility.SpatialReference; csObj.BindNativeObject(__ptr, "CSpatialReference"); csObj.Delegate = true; } return(csObj); }
private static extern IntPtr EarthView_World_Spatial_Utility_CCoordinateSystemFactory_createCoordSys_CSpatialReference_EVSpatialReferenceStringType_EVString(EarthView.World.Spatial.Utility.EVSPATIALREFERENCESTRINGTYPE eStrType, string pszReference);