Notes on Calumet and resolve-uri

When I execute the pipeline [1] with Calumet 1.0.9 from the command
line, I get the following messages:
1.
p:base-uri(.):***file:/J:/any/***
p:base-uri(.):******
While the base uri is correct _before_ the p:for-each step, it is lost
inside. But even the step iterates over the child elements (which have
no explicit xml:base attribute), they should have inherited it (see
http://www.w3.org/TR/xmlbase/ )
2.
p:resolve-uri(*/@name):***test%20yyy***
p:resolve-uri(*/@name, file:/J:/any/):***file:/J:/any/test%20yyy***
When given an (for anyURI) invalid name p:resolve-uri % encodes it,
but has also no base uri to use. A solution to this problem should be
seen in connection with the same problem for the p:make-absolute-uris
step.

Regards,
Manfred

[1]
<?xml version="1.0" encoding="UTF-8"?>
<p:declare-step name="myPipeline"
	xmlns:x="http://www.emc.com/documentum/xml/xproc"
	xmlns:c="http://www.w3.org/ns/xproc-step"
	xmlns:p="http://www.w3.org/ns/xproc">
	<p:input port='parameters' kind='parameter' primary='true'/>
	<p:output port="result" primary="true"/>
	<p:declare-step type="x:message">
		<p:option name="message" required="true"/>
		<p:option name="stderr" select="'true'"/>
		<p:option name="stdout" select="'false'"/>
		<p:input port="source" sequence="true"/>
		<p:output port="result" sequence="true"/>
	</p:declare-step>
	<p:identity>
		<p:input port="source">
			<p:inline>
<c:directory xml:base="file:/J:/any/">
	<c:directory name="test yyy"/>
</c:directory>
			</p:inline>
		</p:input>
	</p:identity>
<x:message><p:with-option name="message"
select="concat('p:base-uri(.):***', p:base-uri(.),
'***')"/></x:message>
	<p:for-each name="level-1">
		<p:iteration-source select="/c:directory/c:directory"/>
		<p:output port="result"/>
<x:message><p:with-option name="message"
select="concat('p:base-uri(.):***', p:base-uri(.),
'***')"/></x:message>
<x:message><p:with-option name="message"
select="concat('p:resolve-uri(*/@name):***', p:resolve-uri(*/@name),
'***')"/></x:message>
<x:message><p:with-option name="message"
select="concat('p:resolve-uri(*/@name, file:/J:/any/):***',
p:resolve-uri(*/@name, 'file:/J:/any/'), '***')"/></x:message>
		<p:identity/>
	</p:for-each>
</p:declare-step>

Received on Thursday, 24 September 2009 10:25:48 UTC