You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xmlbeans.apache.org by "Wing Yew Poon (JIRA)" <xm...@xml.apache.org> on 2009/11/03 02:02:59 UTC

[jira] Commented: (XMLBEANS-366) Apache JXPath support

    [ https://issues.apache.org/jira/browse/XMLBEANS-366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12772804#action_12772804 ] 

Wing Yew Poon commented on XMLBEANS-366:
----------------------------------------

I submitted an enhancement in XMLBeans 2.4.0 to make the XPath/XQuery engine pluggable (see XMLBEANS-373). This is a more general solution to implement the functionality Robert seeks (using JXPath instead of Saxon).
We could add a sample demonstrating this pluggability, using JXPath as the XPath engine. That could be nice.


> Apache JXPath support
> ---------------------
>
>                 Key: XMLBEANS-366
>                 URL: https://issues.apache.org/jira/browse/XMLBEANS-366
>             Project: XMLBeans
>          Issue Type: New Feature
>          Components: XPath
>    Affects Versions:  Version 2.3.1
>            Reporter: Robert Marcano
>            Priority: Minor
>         Attachments: jxpath-support.patch
>
>
> I have patched the version 2.3 to support Apache JXPath  when no saxon is found (default behavior), I sent this to the dev mailing list without answer, so I an adding it here to see if it gets a little more attention (I can update it to trunk and make the necessary changes):
> Greeting everyone, I have been a long time user of XMlBeans but it is
> the first time I needed to use the XPath support. Using an old Saxon
> release (8.6.1 as documented because is the version that is API
> compatible) everything is working perfectly.
> My application is Webstart based so I try to reduce the amount of
> external dependencies in order to have a small download size, I am
> currently using JXPath for some Beans trees searches, so I decided to
> patch XMLBeans to try to use JXPath after it fails to find Saxon. I am
> attaching the patch so anyone can use it and to know if the changes are
> accepted so I can port it to the trunk release instead of 2.3.0.
> In the process of developing this patch I found one problem with the
> XPath function "id()". The JXPath implementation of this functions when
> it is traversing a DOM tree is to find the document owner and call
> getElementById(). the current DOM implementation of XMLBeans only
> recognize ID attributes when they are defined on a DTD and does not use
> the XML schema information. Even when my XMLBeans model parses a DOM
> tree obtained from a XML Schema validating DOM parser, the ID attributes
> information is lost because it recreated an internal tree that discards
> the "isId" information added by the DOM parser. I tried to use the
> schema type information in the method Cur>>isAttrOfTypeId but still do
> not find a way, any helps with this is appreciated

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@xmlbeans.apache.org
For additional commands, e-mail: dev-help@xmlbeans.apache.org