Beruflich Dokumente
Kultur Dokumente
with ArcGIS
Juan Castaneda
Jonas Pålsson
Desktop Engine
Developer Kit Developer Kit API API SDK
.NET COM .NET COM .NET .NET Java .NET
C++ Java
ArcSDE
Data Personal
(Geodatabase) for MS File
File Personal Workgroup Enterprise
Access
• ArcGIS Desktop
– ArcView, ArcEditor, ArcInfo
• ArcGIS Server
– Functionality / Capacity
• Extensions
– Desktop
• 3D, Geostatistics, Network, Schematics Analyst; Publisher,
Data Interop., Maplex, ArcPress, etc
– Server
• Network Analyst*, Data Interoperability*, Spatial Analyst**, 3D
Analyst**
* = requires Standard or Advanced editions
** = requires Advanced edition
EUC 2007 Technical Track
Editions and Levels of ArcGIS Server
Capacity
Level
Edition Edition includes Workgroup Enterprise
Basic • ArcSDE • SQL Server • Any
• Geodata services for Express supported
replication • 10 users database
• Unlimited
Functionality
users
• Fundation
– Building blocks for ArcGIS Point
– Users and programmers interact with the same objects
Map
Polygon
Layer
Polygon Field
• There is only one Map class, like for this car blueprint
• You make many map objects: Map and Sweden Counties. Using
the blueprint to create car objects
• A class is code behind an object’s properties and methods
• Objects live in memory and take on your settings
Blueprint
Map
Objects
EUC 2007 Technical Track
Where are ArcObjects?
pLayer = pMap.Layer(0) 1
• COM compliant
– Component object model
– Industry standard for creating classes
– Programming language independent
– COM classes can be reused between applications
Map
Layer
IMap Layer (index): ILayer
*
AddLayer (ILayer)
Feature
IMore Other: Something Class
Button
• Simple objects (VB, Excel, MapObjects)
– One default interface _Button
– Hidden
IPoint
Point
• ArcObjects
IGeometry
– Multiple interfaces
'Simple Object
Commandbutton
Dim b as CommandButton 'Declare
Color
Set b = frmClock.cmdTime 'Set
Enabled
b.Caption = “Time” 'Use Font
Caption
ToolTip
_CommandButton
On a VBA form
EUC 2007 Technical Track
Client and server environment
Point
Dim p as IPoint IPoint X
Y
Z
Set p = New Point
IGeometry Projection
p.z = 5280
Third-party DLL
developer code Request OLB
(e.g., VBA) services DEMO EXE
Interface
• Interface module
ESRI’s ArcObjects code
Your code Your
Server
• Developer module
– Instantiate class
– Call its methods
EUC 2007 Technical Track
Developing custom COM components
esriControlCommands
ArcMap
ICommand
Find FindButton
command
DEMO
EUC 2007 Technical Track
API objects match your experience as a user
Workspace
FeatureDataset
FeatureClass
FeatureClass
Workspace
FeatureDataset
FeatureClass
FeatureClass
Two Products
• Engine Developer Kit is the toolkit for building custom GIS
and mapping applications
• Components
– Web ADF Native .Net Assemblies
– ArcObjects primary Interop Assemblies
• Library architecture
• COM concepts
– Interfaces
– GUIDs
– Component Categories
• Using COM objects with .NET – COM Interop
– COM Callable Wrappers
– Runtime Callable Wrappers
• The Application architecture
'Visual
'Visual Basic
Basic .NET
.NET uses
uses the
the 'Imports'
'Imports' keyword
keyword
Imports
Imports ESRI.ArcGIS.CatalogUI
ESRI.ArcGIS.CatalogUI
Imports
Imports ESRI.ArcGIS.ArcMapUI
ESRI.ArcGIS.ArcMapUI
Imports ESRI.ArcGIS.Framework
Imports ESRI.ArcGIS.Framework
.. .. ..
'Visual
'Visual C# C# uses
uses the
the ‘using'
‘using' keyword
keyword
using
using ESRI.ArcGIS.CatalogUI
ESRI.ArcGIS.CatalogUI
using
using ESRI.ArcGIS.ArcMapUI
ESRI.ArcGIS.ArcMapUI
using ESRI.ArcGIS.Framework
using ESRI.ArcGIS.Framework
Dim
Dim point
point As
As New
New PointClass
PointClass
Dim geometry As IGeometry
Dim geometry As IGeometry
If
If (TypeOf
(TypeOf point
point IsIs IGeometry)
IGeometry) Then
Then
geometry
geometry == point
point
End
End If
If
EUC 2007 Technical Track
.Net base classes save time
Public
Public NotInheritable
NotInheritable Class
Class RouteFinderCmd
RouteFinderCmd
Inherits BaseCommand
Inherits BaseCommand
……
Public
Public Sub
Sub New()
New()
MyBase.New()
MyBase.New()
MyBase.m_caption
MyBase.m_caption == "RouteWindow
"RouteWindow VB"
VB"
MyBase.m_category
MyBase.m_category = "ArcObjects .NET Tools"
= "ArcObjects .NET Tools"
MyBase.m_message
MyBase.m_message == "Toggles
"Toggles view
view for
for the
the RouteFinder
RouteFinder window"
window"
MyBase.m_name = "ArcObjects .NET Tools_RouteFinderCmd"
MyBase.m_name = "ArcObjects .NET Tools_RouteFinderCmd"
MyBase.m_toolTip
MyBase.m_toolTip == "Displays
"Displays or
or hides
hides Route
Route Finder"
Finder"
MyBase.m_bitmap = New System.Drawing.Bitmap
MyBase.m_bitmap = New System.Drawing.Bitmap _ _
(Me.GetType.Assembly.GetManifestResourceStream
(Me.GetType.Assembly.GetManifestResourceStream __
("ESRI.ArcObjects.AAON.RouteFinderVB.RouteFinder.bmp"))
("ESRI.ArcObjects.AAON.RouteFinderVB.RouteFinder.bmp"))
End Sub
End Sub
Public
Public Overrides
Overrides Sub
Sub OnCreate(ByVal
OnCreate(ByVal hook
hook As
As Object)
Object)
……
End
End Sub
Sub
Public
Public Overrides
Overrides Sub
Sub OnClick()
OnClick()
……
End
End Sub
Sub
DEMO
EUC 2007 Technical Track
ArcGIS Engine Developer Kit for .NET
– Java components
Integration Environment
• Web ADF
• Enterprise ADF
Plus the Web Mobile Web Enterprise
ArcGIS Explorer
SDK for custom tasks .NET Java
• Components
– Web ADF Native .Net Assemblies
– ArcObjects primary Interop Assemblies
• ArcGIS Engine
• ArcGIS Server
Interop Bridge
ArcObjects
• Web ADF
– Java Server Faces
• Enterprise Application Development Framework
– Supports development of J2EE applications powered by Enterprise
JavaBeans (EJB) technology by providing out-of-the-box EJBs
ready to use
• Web services
• Visit
– EDN http://edn.esri.com
– Documentation
– Conference proceedings