Re: [basex-talk] Quickest way to parse a DomSource
Thank you Martin. It's worth experimenting In the meanwhile (thanks to my colleague who had a closer look at the DOMSource API) I got to understand that there's a getNode() method returning the underlying DOM Node. This allows for minimizing the module import statements. Thus, fyi, at the moment this is my work-around: (: Import DOMSource API:) declare namespace source = "javax.xml.transform.dom.DOMSource"; (:... code to get to the custom Document representation stored in a variable called $document... :) (: get the DOMSource through custom API:) let $source := bpmndom:getDomSource($document) (:DOMSource API to get underlying Document Node :) let $doc := source:getNode($source) (:Now this Xpath expression works :) return $doc//*:userTask Cheers, Marco. On 22/07/19 12:53, Martin Honnen wrote: Am 22.07.2019 um 11:32 schrieb Marco Lettere: I have to access portions of the XML representation of the BPMN file by binding the engine's API. The closest that I can get to a standard XML representation is currently a javax.xml.transform.dom.DOMSource. What is the shortest way to transform (in XQuery) this DomSource to a BaseX representation of the Document in order to query it? The XQJ API seems to have a method http://xqj.net/javadoc/javax/xml/xquery/XQDynamicContext.html#bindDocument(javax.xml.namespace.QName,%20javax.xml.transform.Source,%20javax.xml.xquery.XQItemType) to allow passing in a java.xml.transform.Source so that seems at least one way to deal with a DOMSource. But it happens on the Java side and is tied to that particular XQJ API.
Re: [basex-talk] File-io:error. File lock by another process (windows-only)
Hi France, > It seems that basexhttp.bat was launching multiple instance of basex. We have multiple Windows instances running with BaseX, but I cannot recollect having had such an issue before (and I’m not sure how this could happen, as the code for starting the server is pretty straightforward). Maybe you had other instances running? Did you really call basexhttp only once? If yes, which flags do you supply as arguments? > It's the second time we see that on Windows systems. Is it possible that the > Windows installation process sets environment variables which creates > conflicts if other instances are installed using the .zip files? If you use the Windows installer, the PATH variable will be modified, such that basex will be found on command line. Best, Christian
Re: [basex-talk] Quickest way to parse a DomSource
Am 22.07.2019 um 11:32 schrieb Marco Lettere: I have to access portions of the XML representation of the BPMN file by binding the engine's API. The closest that I can get to a standard XML representation is currently a javax.xml.transform.dom.DOMSource. What is the shortest way to transform (in XQuery) this DomSource to a BaseX representation of the Document in order to query it? The XQJ API seems to have a method http://xqj.net/javadoc/javax/xml/xquery/XQDynamicContext.html#bindDocument(javax.xml.namespace.QName,%20javax.xml.transform.Source,%20javax.xml.xquery.XQItemType) to allow passing in a java.xml.transform.Source so that seems at least one way to deal with a DOMSource. But it happens on the Java side and is tied to that particular XQJ API.
[basex-talk] Quickest way to parse a DomSource
Hi all, I'm currently working on the usage of BaseX Xquery scripts inside a BPMN engine. I have to access portions of the XML representation of the BPMN file by binding the engine's API. The closest that I can get to a standard XML representation is currently a javax.xml.transform.dom.DOMSource. What is the shortest way to transform (in XQuery) this DomSource to a BaseX representation of the Document in order to query it? Thanks, Marco.
Re: [basex-talk] File-io:error. File lock by another process (windows-only)
Hi, We think we found the issue. It seems that basexhttp.bat was launching multiple instance of basex. It's the second time we see that on Windows systems. Is it possible that the Windows installation process sets environment variables which creates conflicts if other instances are installed using the .zip files? I was on Mac for years before switching to Linux and have never had this issue. I'm trying to figure out how this happens so I can advise my colleagues on Windows better. Thanks,