xml-xalan-j-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "siegfried" <siegfr...@heintze.com>
Subject FW: command line tool for reading and writing to/from stdin and stdout?
Date Thu, 04 Sep 2008 19:37:15 GMT
I was mucking around with the examples and found UseStyleSheetPI.java. This
almost works. It breaks when I substitute the first occurance of "fooX.xml"
with system.in it breaks! Apparently there is some problem with having
standard input open twice! Is there a way to resolve this?

 

Thanks,

Siegfried

 

  _____  

From: siegfried [mailto:siegfried@heintze.com] 
Sent: Thursday, September 04, 2008 11:07 AM
To: 'xalan-j-users@xml.apache.org'
Subject: command line tool for reading and writing to/from stdin and stdout?

 

I would like to perform XSLT with pipes and unfortunately, the little
program "java org.apache.xalan.xslt.Process -IN birds.xml -XSL birds.xsl
-OUT birds.out" requires I have files for input and output making piping
cumbersome!

 

Has anyone modified java source to org.apache.xalan.xslt.Process so it will
read from standard input and write to standard output? I tried and after 30
minutes of my attempts to replace "inputfile" with system.in not working, I
decided someone else has surely already done this! (I'm wondering if I was
encountering some constraints where the transform does not want to read from
standard input because it wants to report the file name the syntax error
messages and standard input does not have a file name.) Can someone point me
to an implementation of java org.apache.xalan.xslt.Process that will read
from standard input, figure out the name of the XSL file from the PI tag,
and write to standard output?

 

Thanks,

Siegfried


Mime
View raw message