Datasource definition section, Map definition section – Pitney Bowes MapXtreme User Manual

Page 488

Advertising
background image

Appendix C: Understanding the MapInfo Workspace

Structure of a Workspace

MapXtreme v7.1

495

Developer Guide

DataSource Definition Section

The DataSource Definition section defines the data files (for example, TAB files) and database
tables that are retrieved at each connection location. Optional metadata may also be included to
describe the data that is retrieved. This example shows a named data source definition, a database
datasource definition, and a TAB data source definition.

<DataSourceDefinitionSet>

<NamedDataSourceDefinitionRef resourceID="MyDataSource"/>
<DBDataSourceDefinition id="id1" readOnly="false">

<DataSourceName>alias_Line_ontario_oracle_9i_rel
</DataSourceName>
<ConnectionMember>

<ConnectionName>ontario_oracle_9i_release_1</ConnectionName>

</ConnectionMember>
<DBQuery>

<Query>select * from us_hiway_extra</Query>

</DBQuery>
<DBDataSourceMetadata>

<FeatureGeometryAttribute srsName="mapinfo:coordsys 1,62">

OBJECT

</FeatureGeometryAttribute>

<KeyAttributes />
</DBDataSourceMetadata>

</DBDataSourceDefinition>
<TABFileDataSourceDefinition id="id2" readOnly="false">

<DataSourceName>alias_Line_us_hiway_extra</DataSourceName>
<FileName>FeatureLayerBuilder\us_hiway_extra.tab</FileName>

</TABFileDataSourceDefinition>

</DataSourceDefinitionSet> ...

Map Definition Section

The Map Definition section defines one or more maps and their constituent layers. Each map has
display conditions that include the size of the image, the zoom and center settings, the coordinate
system of the rendered map. This example shows a named map definition reference and a map
definition. Under the LayerList, there are two named layers, three defined layers and a named style
reference for a label layer.

<MapDefinitionSet>

<NamedMapDefinitionRef resourceID="MyWorldMap"/>
<MapDefinition id="id7" name="Map1" alias="Map1" uniqueId="4adeb0e9-

7c77-4957-a3fb-a1a0677756ef">

<DisplayConditions>

<MapSize uom="mapinfo:imagesize pixel">

<ImageWidth>600</ImageWidth>
<ImageHeight>400</ImageHeight>

</MapSize>
<ZoomAndCenter>

<MapZoom uom="mapinfo:length mi">3000</MapZoom>
<gml:Point srsName="EPSG:4269">

Advertising