Hi Peter,

Castor is used by thousands of people, as with every opensource project
I have ever seen, we do not allow CVS commit access to everyone. Patches
need to be reviewed first and approved before they can be commited by
someone who has commit access.

For tracking purposes, the best way to submit a patch is via Bugzilla
(bugzilla.exolab.org).

However, we do monitor the list for patches as well. I've added your
patch to my list of patches which need reviewing and I will review it
once I have the chance.

Thanks,

--Keith





Peter Vince wrote:
> 
> I'm marshalling a wrapper class that embeds a superclass that could, in
> actual fact, be one of several subclasses.
> After seeing the annoying attributes in the resulting xml for the sub class
> AxClass:
>      xsi:type="java:pollux.AxClass" xmlns:xsi
> ="http://www.w3.org/2001/XMLSchema-instance";
> and looking into the marshal private method, I added a minor fix to the
> Castor Marshaller class .
> Also, I needed a "getReadMethod()" for the FieldhandlerImpl class, that
> just returns, unsurprisingly, the get method.
> 
> The cvs diffs are as follows:
> 
> cvs -z9 diff Marshaller.java (in directory D:
> \castor9_3_19\castor_current\castor\src\main\org\exolab\castor\xml\)
> Index: Marshaller.java
> ===================================================================
> RCS file:
> /cvs/castor/castor/src/main/org/exolab/castor/xml/Marshaller.java,v
> retrieving revision 1.108
> diff -r1.108 Marshaller.java
> 851a852
> >                   boolean override = false;
> 855a857,864
> >                   //--- pmv -----------------------------
> >                   //--- if descriptor is of a class extended by class
> found by
> >                   //--- classDescriptorResolver, then we should be able
> to
> >                   //--- marshall without the xsi:type insertion.
> >                   if(classDesc != null && descriptor.getFieldType
> ().isAssignableFrom(_class)) {
> >                        saveType = false;
> >                        override = true;
> >                   }
> 871c880,883
> <              else if (descriptor.getXMLName()==null)
> ---
> >              //--- pmv
> >              //--- add additional test --------------------
> >              else if (descriptor.getXMLName()==null || override)
> >                   //else if (descriptor.getXMLName()==null)
> 
> *****CVS exited normally with code 1*****
> 
> cvs -z9 diff FieldHandlerImpl.java (in directory D:
> \castor9_3_19\castor_current\castor\src\main\org\exolab\castor\mapping\loader\)
> Index: FieldHandlerImpl.java
> ===================================================================
> RCS file:
> /cvs/castor/castor/src/main/org/exolab/castor/mapping/loader/FieldHandlerImpl.java,v
> retrieving revision 1.42
> diff -r1.42 FieldHandlerImpl.java
> 777a778,781
> >    //---- pmv
> >    //---- please, as a convenience
> >    public Method getReadMethod() {return _getMethod;}
> >
> 
> *****CVS exited normally with code 1*****
> 
> cvs -z9 commit -m "added getReadMethod()" FieldHandlerImpl.java (in
> directory D:
> \castor9_3_19\castor_current\castor\src\main\org\exolab\castor\mapping\loader\)
> cvs [server aborted]: "commit" requires write access to the repository
> 
> *****CVS exited normally with code 1*****
> 
> As can be seen from the last cvs comment, I cannot commit the changes! Here
> I need some direction/help.
> A test case, rather ugly code, illustrates the usage.
> (See attached file: pollux.zip)
> 
> The output xml before the fix is applied.
> (See attached file: PolluxTestPreFix.xml)
> 
> The xml after the fix.
> (See attached file: PolluxTestPostFix.xml)
> 
> Again, I cannot commit these changes - some direction would be appreciated.
> 
>   ------------------------------------------------------------------------
>                  Name: pollux.zip
>    pollux.zip    Type: Zip Compressed Data (application/x-zip-compressed)
>              Encoding: base64
> 
>                            Name: PolluxTestPreFix.xml
>    PolluxTestPreFix.xml    Type: XML Document (text/xml)
>                        Encoding: base64
> 
>                             Name: PolluxTestPostFix.xml
>    PolluxTestPostFix.xml    Type: XML Document (text/xml)
>                         Encoding: base64

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to