cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ROSSEL Olivier <olivier.ros...@airbus.com>
Subject RE: Please help with SourceWritingTransformer
Date Fri, 12 Jul 2002 08:35:48 GMT
> I seem to have done everything right and was testing out the
> SourceWritingTransformer and can't get it to write to a file. 
>  I have the
> pipeline
> 
> <map:match pattern="test/*.xsp">
>       <map:generate type ="serverpages" src="test/{1}.xsp"/>
>       <map:transform type="sql">
>           <map:parameter name="use-connection" value="dev_database"/>
>       </map:transform>
>       <map:transform src="test/metadata.xsl"/>
>       <map:transform type="xslt-with-parameters" 
> src="test/source.xsl">
>           <map:parameter name="page-title" value="{page-title}"/>
>       </map:transform>
>       <map:transform type="tofile2">
>           <map:parameter name="serializer" value="xml"/>
>       </map:transform>
>       <map:serialize type="xml"/>
>    </map:match>
> 
> 
> I know that everything up to the second transformation works 
> (until the
> tofile2 trans which is the SWT).  The input to the SWT looks 
> like this:
> 
> <?xml version="1.0" encoding="UTF-8" ?>
>    <source:write 
> xmlns:source="http://apache.org/cocoon/source/1.0" src="
>    context://my.xml">
>       <KnowledgeObject xmlns:sql="http://apache.org/cocoon/SQL/2.0"
>      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
>      .......stuff..........
>      </KnowledgeObject>
>     </source:write>
Can you try with a src containing only the path and no "context:" at all?
I think it may be the problem.

Gurus will confirm, but I think that Writable source are URLs that can
written
to. context:// is a pseudo protocol, that is probably not handled correctly
bu the SWT. Try with a path, I think SWT will be happier.

Note for developpers: may be, the context:// could be considered a Writable
Source.

---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message