oxf:file-serializer

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

oxf:file-serializer

loic.merz
Hi every body,

I have a problem when I create my file data.xml. At each new instance, the file data.xml is overwrited that means the file data.xml take all new data and lost all the last one. Is it possible only to update the file data.xml with the new information.

Here is the code where I create the file data.xml:

<p:config xmlns:p="http://www.orbeon.com/oxf/pipeline" xmlns:oxf="http://www.orbeon.com/oxf/processors">
        <p:param name="instance" type="input"/>
        <p:processor name="oxf:xml-converter">
                <p:input name="config">
                        <config/>
                </p:input>
                <p:input name="data" href="#instance"/>
                <p:output name="data" id="converter"/>
        </p:processor>
        <p:processor name="oxf:file-serializer">
                <p:input name="config">
                        <config>
                                <file>data.xml</file>
                                <directory>C:\tomcat\webapps\CGC\WEB-INF\resources\is\publications</directory>
                        </config>
                </p:input>
                <p:input name="data" href="#converter"/>
        </p:processor>
</p:config>



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: oxf:file-serializer

Erik Bruchez
Administrator
Loic,

Good one. I have added an "append" option to the file serializer that
you can get with the latest nightly builds:

   http://forge.objectweb.org/nightlybuilds/ops/ops/

This is how you use it:

<p:processor name="oxf:file-serializer">
     <p:input name="config">
         <config>
             <directory>c:/temp</directory>
             <file>test.xml</file>
             <append>true</append>
         </config>
     </p:input>
     <p:input name="data" href="#converted"/>
</p:processor>

-Erik

[hidden email] wrote:

> Hi every body,
>
> I have a problem when I create my file data.xml. At each new instance, the file data.xml is overwrited that means the file data.xml take all new data and lost all the last one. Is it possible only to update the file data.xml with the new information.
>
> Here is the code where I create the file data.xml:
>
> <p:config xmlns:p="http://www.orbeon.com/oxf/pipeline" xmlns:oxf="http://www.orbeon.com/oxf/processors">
> <p:param name="instance" type="input"/>
> <p:processor name="oxf:xml-converter">
> <p:input name="config">
> <config/>
> </p:input>
> <p:input name="data" href="#instance"/>
> <p:output name="data" id="converter"/>
> </p:processor>
> <p:processor name="oxf:file-serializer">
> <p:input name="config">
> <config>
> <file>data.xml</file>
> <directory>C:\tomcat\webapps\CGC\WEB-INF\resources\is\publications</directory>
> </config>
> </p:input>
> <p:input name="data" href="#converter"/>
> </p:processor>
> </p:config>
>
>
> ------------------------------------------------------------------------
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws

--
Orbeon - XForms Everywhere:
http://www.orbeon.com/blog/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws