SVG Map Linked by ISO Attribute

Consider an example of a map where the link with the territories is based on values of the ISO attribute.

<svg version="1.1" xmlns:fs="http://www.fsight.ru" width="800px" height="600px" xmlns="http://www.w3.org/2000/svg">

<g fs:ItemType="Layer" id="Root">

<g fs:ItemType="Layer" id="Regions">

<g id="RU-MOS" style="fill: #0000FF; stroke: #FF0000; stroke-width: 1;">

<path d="M255.3767,316.2664 249.8184,318.5767 ... Z" />

</g>

<g id="RU-MUR" style="fill: #0000FF; stroke: #FF0000; stroke-width: 1;">

<path d="M396.2842,92.87696 396.4967,93.01862 ... Z" />

</g>

...

</g>

</g>

<fs:MetaInfo>

<fs:Attributes>

<fs:Attribute Name="ISO" Type="string">

<fs:Data Id="RU-MOS" Value="RU-MOS" />

<fs:Data Id="RU-MUR" Value="RU-MUR" />

...

</fs:Attribute>

<fs:Attribute Name="Name" Type="string">

<fs:Data Id="RU-MOS" Value="Moscow region" />

     <fs:Data Id="RU-MUR" Value="Murmansk region" />

     ...

</fs:Attribute>

</fs:Attributes>

</fs:MetaInfo>

</svg>

Description

The map has a root layer and a layer with the Regions identifier. Shapes that represent territories are created in the Regions layer. An identifier that corresponds to ISO 3166 is determined for each shape. The shapes also have assigned names. These names are assigned to the territories on converting. They are used when the territory dimension does not have names for any territories.

All the other attributes are not determined, thus, default values are set for these attributes on converting.

To use such a map in user applications, load the file to the repository by selecting the following context menu item in the object navigator: New > Other > Map. Select the Convert Topobase item in the context menu of the created object. The map is converted into other formats. Territory dimension of data sources must include a string attribute with the TERRID identifier. Values of this attribute must match the values specified in the Value attribute of the <fs:Data> element in description of the ISO attribute.

On connecting the map in an express report, the link is established automatically.

On connecting the map in a regular report, the attributes must be specified on setting up data adapter.

See also:

Examples