logo       
Google Custom Search
    AddThis Social Bookmark Button

Re: Problem when using Chiba with JXPath 2.0: msg#00019

Subject: Re: Problem when using Chiba with JXPath 2.0
Hi,

When using JXPath 1.2 'JXPathContext.newContext(this)' calls getValue() which calls getInstanceDocument() and this returns null and fails, if my patch isn't applied.
If you have more questions please feel free to ask them.

Best regards,
Nick Van den Bleeken


----- Original Message ----- From: "Joern Turner" <joern.turner-S0/GAf8tV78@xxxxxxxxxxxxxxxx>
To: "Nick Van den Bleeken" 
<Nick.VandenBleeken-LPO8gxj9N8aZIoH1IeqzKA@xxxxxxxxxxxxxxxx>
Cc: <chiba-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx>
Sent: Sunday, September 05, 2004 11:31 PM
Subject: Re: [Chiba-developer] Problem when using Chiba with JXPath 2.0


Hello Nick,

thanks, that's very helpfull - we couldn't update to JXPath 1.2 yet cause our tests break and still use the older version. but we'd like to make the upgrade asap cause it makes some important fixes to namespace handling.

Nick Van den Bleeken wrote:

Hi,

I discovered a problem when using chiba 0.9.7 in conjunction with JXPath 2.0. I have also made a fix the problem (see attachment).
can you say some more about what the problem was? i cannot judge why your patch fixes the problem otherwise. thanks.

would you be so kind to notify us, if/when your patch to JXPath is accepted and we can get a fixed version of the jar?


thanks a lot,

Joern


There is also an other problem with JXPath 1.2 in how it handles the default namespace (see http://www.mail-archive.com/commons-dev-sSm70nXyYxXWgOoZo4XcuR2eb7JE58TQ@xxxxxxxxxxxxxxxx/msg47749.html).The problem is triggered by the xmls="" attribute on the instance element in the XForm model definition. I also provided a patch file to correct this problem in the post on the commons-dev mailing list.

Is it possible to apply my patch on the HEAD version of the cvs of Chiba?

Best Regards,
Nick Van den Bleeken Index: Instance.java
===================================================================
RCS file: /org/chiba/xml/xforms/Instance.java,v
retrieving revision 1.1
diff -u -r1.1 Instance.java
--- Instance.java    30 Aug 2004 13:43:23 -0000    1.1
+++ Instance.java    2 Sep 2004 11:44:50 -0000
@@ -164,15 +164,15 @@
        XFormsFunctions functions = new XFormsFunctions(this.model);
        functions.setNamespaceContext(this.element);

-        this.instanceContext = JXPathContext.newContext(this);
-        this.instanceContext.setFactory(factory);
-        this.instanceContext.setFunctions(functions);
-
        // load initial instance
        this.initialInstance = getInitiallInstance();

        // create instance document
        this.instanceDocument = createInstanceDocument();
+        +        this.instanceContext = JXPathContext.newContext(this);
+        this.instanceContext.setFactory(factory);
+        this.instanceContext.setFunctions(functions);

        //id handling
//        this.instanceDataItems = new HashMap();







-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click


<Prev in Thread] Current Thread [Next in Thread>