1、Copyright 2004 ESRI. All rights reserved. Developing Applications with ArcGIS Engine开发 Engine 应用程序的基本原理Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.课程 2uArcObjects librariesuArcObjects Engine APIsu 开发 Engine 应用程序u 许可2Developing Applications with ArcGIS EngineCop
2、yright 2004 ESRI. All rights reserved.ArcGIS 结构u 所有产品共享 ArcObjectsuEngine包括核心 ArcObjects的功能ArcGIS Desktop ArcGIS Engine ArcGIS Server3Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.ArcGIS 库u 所有产品共享库u 一些特定库不被共享u例如 : esriArcMapUIu 明确哪些库是属于不同产品u 理解库的互依赖性u 开发工具uArcGIS
3、 Developer HelpuESRI 自动提及的附加资源4Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.ArcGIS Engine library 体系结构5Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.ArcObjectsu 所有 ArcGIS产品都是由 ArcObjects组成uArcObjects都是 C+对象u 通过不同的应用程序接口( API)
4、 来进行调用u 本身其就是 COM组成6Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.Component(Map.dll)ClientArcMapCOMu 连接一个软件模型和另一个软件模型的一种协议u独立的一种语言 u二进制规范u运用界面或组件来开发、配置程序模型u 客户端调用服务器并且服务给予响应u 所有通讯是通过接口进行的7Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights r
5、eserved.ArcObjects和 COM API( 应用编程接口)u 所有 ArcObjects COM 类型都已在类型库里定义好u 并且类型库是通过二进制文件来进行描述u类 : CLSIDs 和 ProgIDsu接口: IIDsu常量和列举u 执行 DLL和 EXE文件u 开发工具uArcGIS Developer Help (VB6 or VC+)uLibraryLocator, EOBrowser and OleView*ArcObjects C+*.dll files*COM Type Libraries*.olb files8Developing Applications wi
6、th ArcGIS EngineCopyright 2004 ESRI. All rights reserved.COM 类uCOM类执行接口u 所有类执行 IUnknownu 管理所有对象的产生、终结u 成员 : QueryInterface, AddRef 和 ReleaseuCoclasses 是可创建的Public Sub mapName()Dim pMap As IMap你能通过一个接口来创建一个实例Set pMap = New MapEnd SubIUnknown9Developing Applications with ArcGIS EngineCopyright 2004 ESRI. All rights reserved.COM 接口u 定义一组逻辑的方法和属性u 从 IUnknown (default)继承uArcObjects 支持u客户化接口u通过 QueryInterface (QI)访问接口Public Sub mapName()Dim pMap As IMapSet pMap = New Map通过定义的 pMap你可以有权使用其的 properties and methods MsgBox pMap.NameEnd Sub10