Full text: Proceedings, XXth congress (Part 4)

International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences, Vol XXXV, Part B4. Istanbul 2004 
  
  
5.3 Use of XSLT in the Integration Service 
In the GiMoDig Integration Service the XSLT technology is 
used extensively. As the incoming queries are encoded in XML, 
according to the WFS specification, and expressed in terms of 
the Global Schema and the common coordinate system, the 
XSLT mechanism can be equally well applied also for the 
query transformation. 
The query typically includes a spatial query window. The 
extent of the window has to be investigated to determine which 
national data services need to be included into the subsequent 
local WFS query processing. The initial query window, given in 
the common coordinate system, needs to be transformed into 
each of the involved local coordinate systems. 
The Feature types and their requested properties need to be 
mapped to the corresponding local types and properties. In 
many cases simple one-to-one relationship between the global 
and local types does not exist, but additional conditions must be 
introduced to the local queries. In some of the cases one global 
query actually generates two or more local queries. Thus, a 
schema transformation is also applied on the incoming queries, 
not only on the outbound datasets. 
In the GiMoDig prototype service the WFS query 
transformations are carried out with the help of the XSLT 
mechanisms. The code sample in Figure 3 illustrates a query 
transformation declaration from the GiMoDig global query to 
the corresponding Finnish local query (Feature type 'Road'). 
The following schema illustrates the process also in graphic 
form. 
The first template demonstrates how additional conditions are 
introduced to the local query (PropertylsEqualTo). The last 
template shows how an XSLT extension function is called to 
carry out the needed query window coordinate system 
transformation (ETRS2NLS:coordSysTrans). 
The resulting GML dataset is transformed from ‚the local 
national data model to the defined Global Schema applying the 
XSLT process declared in the sample code shown in Figure 4. 
The code illustrates that the local Feature type 
(nls:liikenneverkot viiva) actually contains three Global 
Schema Feature types (gmd:Road, gmd:Railway, gmd:Trail). 
These are differentiated in the local data model by a property 
(nls:luokka). The same property also identifies the road 
classification and can thus be used to determine value for the 
corresponding Global Schema property 'intendedUse'. The 
figure also contains a graphic illustration of the transformation 
procedure to help the code interpretation. 
180 
  
Query typeName= 
"Road" "liikenneverkot. viiva" 
Query typeName- 
     
  
   
PropertyName 
centerLineOf 
Property Name 
the geom 
  
  
  
PropertyName 
luokka 
     
    
PropertylsEqualTo 
Interne 
like 
-h 
  
BBOX BBOX 
coordinates coordSysTrans(coor 
dinates) 
  
  
  
<xsl:template match="wfs:Query[@typeName = 'Road']"> 
<Query typeName="ltikenneverkot_viiva" handle="q14"> 
<ogc:PropertyName>luokka</ogc:PropertyName> 
<xsl:if test="wfs:PropertyName = 'centerLineOf"> 
<ogc:PropertyName>the_geom</ogc:PropertyName> 
</xsl:if> 
<ogc:Filter> 
<ogc:And> 
<ogc:Or> 
«ogc:PropertylsEqualTo» 
<ogc:PropertyName>luokka</ogc:PropertyName> 
<ogc:Literal>12111</ogc:Literal> 
</ogc:PropertylsEqualTo> 
</ogc:Or> 
<xsl:apply-templates select="ogc:Filter"/> 
</ogc:And> 
</ogc:Filter> 
</Query> 
</xsl:template> 
<xsl:template match="ogc:Filter"> 
<xsl:apply-templates/> 
</xsl:template> 
<xsl:template match="ogc:BBOX"> 
<ogc:BBOX> 
<ogc:PropertyName>the_geom</ogc:PropertyName> 
«gml:Box srsName="EPSG:2393"> 
«gml:coordinates» 
«xsl:value-of 
select="ETRS2NLS:coordSysTrans(gml:Box/gml:coordinates)"/> 
</gml:coordinates> 
</gml:Box> 
</ogc:BBOX> 
</xsl:template> 
Figure 3. A sample WFS Query Transformation 
«xsl:t 
«Xs 
< 
«Ix 
</xsl:] 
Fig 
As ca 
techno 
data q 
straigh 
transfc 
read ir 
the prc 
The Fi 
respon 
data c« 
and fr 
of the 
coordi 
(GiMo 
Servic: 
transfc 
finally
	        
Waiting...

Note to user

Dear user,

In response to current developments in the web technology used by the Goobi viewer, the software no longer supports your browser.

Please use one of the following browsers to display this page correctly.

Thank you.