惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Google DeepMind News
Google DeepMind News
aimingoo的专栏
aimingoo的专栏
Microsoft Security Blog
Microsoft Security Blog
T
Tenable Blog
Security Archives - TechRepublic
Security Archives - TechRepublic
W
WeLiveSecurity
D
DataBreaches.Net
Attack and Defense Labs
Attack and Defense Labs
H
Heimdal Security Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
AI
AI
P
Proofpoint News Feed
PCI Perspectives
PCI Perspectives
Schneier on Security
Schneier on Security
T
Threatpost
GbyAI
GbyAI
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
H
Help Net Security
F
Full Disclosure
T
Threat Research - Cisco Blogs
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
M
MIT News - Artificial intelligence
L
Lohrmann on Cybersecurity
Martin Fowler
Martin Fowler
博客园 - 【当耐特】
Y
Y Combinator Blog
腾讯CDC
The Hacker News
The Hacker News
博客园 - Franky
Hacker News - Newest:
Hacker News - Newest: "LLM"
博客园_首页
Simon Willison's Weblog
Simon Willison's Weblog
L
LINUX DO - 最新话题
Security Latest
Security Latest
Know Your Adversary
Know Your Adversary
Forbes - Security
Forbes - Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
S
SegmentFault 最新的问题
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
L
LangChain Blog
Vercel News
Vercel News
Cisco Talos Blog
Cisco Talos Blog
量子位
P
Proofpoint News Feed
H
Hacker News: Front Page
Help Net Security
Help Net Security
L
LINUX DO - 热门话题
Project Zero
Project Zero
C
Cisco Blogs

博客园 - 紫微星

Python ImportError: No module named arcgisscripting ENVI遥感影像处理实用手册PDF下载 卡巴斯基许可Key需求登记表 ArcGIS Desktop 9.3 中文运行环境|中文补丁 胡适:赠与今年的大学毕业生 ArcMap打不开且出现提示(Hostname:Not_Set)的解决方法 QQ超级群问题反馈 “GIS空间分析-使用ArcGIS”课程资料完整打包下载,感谢杨克诚老师! ArcGIS 9.3 下载(包含ArcGIS Desktop、ArcGIS Engine、ArcGIS Server、ArcSDE、workstation) ArcGIS中查看metadata显示"warning+乱码"的解决方法 [请您去投票]ESRI中国社区2008年度优秀会员评选 [新年快乐!] Modeling Our World三版合集 下载[2009-4-27更新] ADO.NET入门学习备忘 GIS界首个超级QQ群——“GIS人@E家”,欢迎GIS朋友们加入! 深入研究VS2008中的JavaScript编辑调试器 引用与using的什么区别 控件和组件的差别[转] 平时遇到的GISblog收集 平时遇到的C#和VS问题及解决方法记录 - 紫微星 - 博客园
AE初学的一点理解及有关QI(接口查询)
紫微星 · 2008-08-13 · via 博客园 - 紫微星

开始学习ArcGIS Engine,卡在了QI上了。

再请教了几位朋友和查阅了一些资料后,现有所感悟,特记录下来。

以代码实例和注释为主。 

IMap pMap;  //定义了一个IMap的接口变量。有了这个接口变量还不行,因为接口是定义在对象上的,那么接下来的步骤应该是产生一个对象,而对象又是从那里来的呢---类。 
            pMap = new MapClass();  //在这句中不只是实例化出一个Map对象,同时将上句的pMap接口变量做为了该对象的缺省接口。
            pMap.Name = "VGIS☆紫微星的练习";  //现在我们就可以通过这个接口来对地图名进行修改。
             
            
//一些其他的代码

            pMap.ClearLayers();  
//或者调用ClearLayer方法来删除掉该地图中的所有图层了。
            pMap.Clear();  //出错。为什么?因为不同的接口中的方法或属性只能通过其接口来访问,而Clear方法属于Map类的另外一个接口IActiveView所有。此时需要QI,如下。

            IActiveView pView;    
//定义一个IActiveView的接口变量。
            pView = pMap as IActiveView ;  //通过接口查询QI转到IActiveView上。
            pView .Clear();  //可以调用Clear方法了。

 不知道我的理解是否正确。请指正。

vgis