qexo-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qexo-general] Using qexo from Java with unusual input & output form


From: Per Bothner
Subject: Re: [Qexo-general] Using qexo from Java with unusual input & output formats
Date: Thu, 10 Sep 2015 22:00:37 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0



On 09/10/2015 09:12 PM, John Ohno wrote:
I'm sorry -- I think my question wasn't clear enough.

I don't want to specify an XML filename. I want to specify an already-parsed 
DOM Document or Node object -- because my source file is in FastInfoset format, 
not XML.

First, note that Qexo doesn't know anything about FastInfoset, so you have to 
convert it to
either XML source, or Qexo's Node representation (gnu.kawa.xml.KNode).  (Jus 
using something
that implements org.w3c.dom.Node probably won't work.)  You can use SAX to do 
convert
from FastInfoset to Qexo's imlementation.

Once you have a Node (or more genberally a sequence of items) how you run some 
XQuery
with that as the context node (or context sequence)?  For that look into
gnu/xquery/lang/XQuery.java.  It contains a number of helper methods you can 
use.

--
        --Per Bothner
address@hidden   http://per.bothner.com/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]