/// <summary>
                    /// 创建一个地图实例,名称与参数一致
                    /// </summary>
                    /// <param name="mapName">地图名称</param>
                    /// <returns>地图</returns>
                    public override EarthView.World.Spatial.Atlas.Imap CreateMap(string mapName)
                    {
                        IntPtr __ptr = EarthView_World_Spatial2D_Atlas_CMapFactory_createMap_IMap_EVString(this.NativeObject, mapName);

                        if (__ptr == IntPtr.Zero)
                        {
                            return(null);
                        }
                        EarthView.World.Spatial.Atlas.Imap csObj = new EarthView.World.Spatial.Atlas.Imap(CreatedWhenConstruct.CWC_NotToCreate);
                        csObj.BindNativeObject(__ptr, "IMap");
                        IClassFactory csObjClassFactory = GlobalClassFactoryMap.Get(csObj.GetCppInstanceTypeName());

                        if (csObjClassFactory != null)
                        {
                            csObj.Delegate = true;
                            csObj          = csObjClassFactory.Create() as EarthView.World.Spatial.Atlas.Imap;
                            csObj.BindNativeObject(__ptr, "IMap");
                        }
                        return(csObj);
                    }
                    /// <summary>
                    /// 从流中恢复出来一个map
                    /// </summary>
                    /// <param name="stream">map流</param>
                    /// <returns>地图</returns>
                    public new EarthView.World.Spatial.Atlas.Imap CreateMapFromStream_NoVirtual(EarthView.World.Core.DataStream stream)
                    {
                        IntPtr __ptr = EarthView_World_Spatial2D_Atlas_CMapFactory_createMapFromStream_IMap_CDataStream_NoVirtual(this.NativeObject, object.Equals(stream, null) ? IntPtr.Zero : stream.NativeObject);

                        if (__ptr == IntPtr.Zero)
                        {
                            return(null);
                        }
                        EarthView.World.Spatial.Atlas.Imap csObj = new EarthView.World.Spatial.Atlas.Imap(CreatedWhenConstruct.CWC_NotToCreate);
                        csObj.BindNativeObject(__ptr, "IMap");
                        IClassFactory csObjClassFactory = GlobalClassFactoryMap.Get(csObj.GetCppInstanceTypeName());

                        if (csObjClassFactory != null)
                        {
                            csObj.Delegate = true;
                            csObj          = csObjClassFactory.Create() as EarthView.World.Spatial.Atlas.Imap;
                            csObj.BindNativeObject(__ptr, "IMap");
                        }
                        return(csObj);
                    }
                    /// <summary>
                    /// 从xml元素中恢复出来一个map
                    /// </summary>
                    /// <param name="element">xml要素</param>
                    /// <returns>地图</returns>
                    public override EarthView.World.Spatial.Atlas.Imap CreateMapFromXMLElement(ref EarthView.World.Core.XmlElement element)
                    {
                        IntPtr __ptr = EarthView_World_Spatial2D_Atlas_CMapFactory_createMapFromXMLElement_IMap_CXmlElement(this.NativeObject, object.Equals(element, null) ? IntPtr.Zero : element.NativeObject);

                        if (__ptr == IntPtr.Zero)
                        {
                            return(null);
                        }
                        EarthView.World.Spatial.Atlas.Imap csObj = new EarthView.World.Spatial.Atlas.Imap(CreatedWhenConstruct.CWC_NotToCreate);
                        csObj.BindNativeObject(__ptr, "IMap");
                        IClassFactory csObjClassFactory = GlobalClassFactoryMap.Get(csObj.GetCppInstanceTypeName());

                        if (csObjClassFactory != null)
                        {
                            csObj.Delegate = true;
                            csObj          = csObjClassFactory.Create() as EarthView.World.Spatial.Atlas.Imap;
                            csObj.BindNativeObject(__ptr, "IMap");
                        }
                        return(csObj);
                    }
Example #4
0
                    /// <summary>
                    /// 获取与事件相关联的地图
                    /// </summary>
                    /// <param name=""></param>
                    /// <returns>地图</returns>
                    public EarthView.World.Spatial.Atlas.Imap GetMap()
                    {
                        IntPtr __ptr = EarthView_World_Spatial_SystemUI_CMapOperationEvent_getMap_IMap(this.NativeObject);

                        if (__ptr == IntPtr.Zero)
                        {
                            return(null);
                        }
                        EarthView.World.Spatial.Atlas.Imap csObj = new EarthView.World.Spatial.Atlas.Imap(CreatedWhenConstruct.CWC_NotToCreate);
                        csObj.BindNativeObject(__ptr, "IMap");
                        csObj.Delegate = true;
                        IClassFactory csObjClassFactory = GlobalClassFactoryMap.Get(csObj.GetCppInstanceTypeName());

                        if (csObjClassFactory != null)
                        {
                            csObj.Delegate = true;
                            csObj          = csObjClassFactory.Create() as EarthView.World.Spatial.Atlas.Imap;
                            csObj.BindNativeObject(__ptr, "IMap");
                            csObj.Delegate = true;
                        }
                        return(csObj);
                    }