W3C home > Mailing lists > Public > xproc-dev@w3.org > October 2010

Re: What are single, non-primary, output ports?

From: Romain Deltour <rdeltour@gmail.com>
Date: Fri, 8 Oct 2010 09:41:41 +0200
Message-Id: <9E156714-D307-4BED-A0BB-1A49027D3E2D@gmail.com>
To: XProc Dev <xproc-dev@w3.org>
The primary/non-primary nature is related with implied port connections.

As far as I understand it is particularly important in the case where  
the step is the final step in a compound step, since if the last  
output was primary, it would implicitly add a primary output to the  
compound step.

 From the spec:
"Additionally, if a compound step has no declared outputs and the last  
step in its subpipeline has an unconnected primary output, then an  
implicit primary output port will be added to the compound step (and  
consequently the last step's primary output will be connected to it)"

BR,
Romain.

Le 8 oct. 10 à 09:18, Philip Fennell a écrit :

> As taken from the current recommendation, XProc defines the  
> following four steps (p:compare, p:parameters, p:store and p:xsl- 
> formatter) as having a single output port (result) that is also not  
> the primary output port.
>
> I may not have found the whole story but according to the  
> recommendation:
>
> 'The primary attribute is used to identify the primary output port.  
> An output port is a primary output port if primary is specified with  
> the value true or if the step has only a single output port and  
> primary is not specified. It is a static error (err:XS0014) to  
> identify more than one output port as primary.'
>
> However, what it doesn't explain is what is meant by a single output  
> port that isn't a primary output port. I can see that, conceptually,  
> the primary result of both p:store and p:xsl-formatter is the  
> document written to the URI declared in the href attribute and not  
> what appears on the output result port but I'm not sure of the  
> practicle implications of such a declaration.
>
>
>
>
> <p:declare-step type="p:compare">
>    <p:input port="source" primary="true"/>
>    <p:input port="alternate"/>
>    <p:output port="result" primary="false"/>
>    ...
> </p:declare-step>
>
>
> <p:declare-step type="p:parameters">
>    <p:input port="parameters" kind="parameter" primary="false"/>
>    <p:output port="result" primary="false"/>
> </p:declare-step>
>
>
> <p:declare-step type="p:store">
>    <p:input port="source"/>
>    <p:output port="result" primary="false"/>
>    ...
> </p:declare-step>
>
>
> <p:declare-step type="p:xsl-formatter">
>    <p:input port="source"/>
>    <p:input port="parameters" kind="parameter"/>
>    <p:output port="result" primary="false"/>
>    ...
> </p:declare-step>
>
>
>
> Regards
>
> Philip Fennell
> Consultant
> MarkLogic Corporation
>
> Mobile +44 (0) 7824 830 866
>
> email  Philip.Fennell@marklogic.com
> web    www.marklogic.com
>
>
> This e-mail and any accompanying attachments are confidential. The  
> information is intended solely for the use of the individual to whom  
> it is addressed. Any review, disclosure, copying, distribution, or  
> use of this e-mail communication by others is strictly prohibited.  
> If you are not the intended recipient, please notify us immediately  
> by returning this message to the sender and delete all copies. Thank  
> you for your cooperation.
Received on Friday, 8 October 2010 07:51:25 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 8 October 2010 07:51:25 GMT