You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Glen Daniels <gd...@macromedia.com> on 2002/03/12 15:11:42 UTC

RE: cvs commit: xml-axis/java/src/org/apache/axis/encoding/ser Be anDeserializer.java

Hi dims!

I think we can actually remove the get(localName) clause entirely, and just use the xmlNameToJava() version.

--G

> -----Original Message-----
> From: dims@apache.org [mailto:dims@apache.org]
> Sent: Tuesday, March 12, 2002 8:48 AM
> To: xml-axis-cvs@apache.org
> Subject: cvs commit: xml-axis/java/src/org/apache/axis/encoding/ser
> BeanDeserializer.java
> 
> 
> dims        02/03/12 05:47:54
> 
>   Modified:    java/src/org/apache/axis/encoding/ser 
> BeanDeserializer.java
>   Log:
>   Need this fix to get our WSDL2Java generated code to work 
> with Microsoft's "C# DataTypes.asmx" Web Service sample.
>   
>   Revision  Changes    Path
>   1.12      +6 -4      
> xml-axis/java/src/org/apache/axis/encoding/ser/BeanDeserializer.java
>   
>   Index: BeanDeserializer.java
>   ===================================================================
>   RCS file: 
> /home/cvs/xml-axis/java/src/org/apache/axis/encoding/ser/BeanD
> eserializer.java,v
>   retrieving revision 1.11
>   retrieving revision 1.12
>   diff -u -r1.11 -r1.12
>   --- BeanDeserializer.java	9 Mar 2002 19:29:48 -0000	1.11
>   +++ BeanDeserializer.java	12 Mar 2002 13:47:54 -0000	1.12
>   @@ -161,12 +161,14 @@
>            }
>    
>            if (propDesc == null) {
>   -            // look for a field by this name.  Assumes the 
> the number of
>   -            // properties in a bean is (relatively) small, 
> so uses a linear
>   -            // search.
>   +            // look for a field by this name.
>                propDesc = (BeanPropertyDescriptor) 
> propertyMap.get(localName);
>            }
>   -        
>   +        if (propDesc == null) {
>   +            // look for a field by the "adjusted" name.
>   +            propDesc = (BeanPropertyDescriptor) 
> propertyMap.get(JavaUtils.xmlNameToJava(localName));
>   +        }
>   +
>            if (propDesc == null) {
>                // No such field
>                throw new SAXException(
>   
>   
>   
> 

RE: cvs commit: xml-axis/java/src/org/apache/axis/encoding/ser Be anDeserializer.java

Posted by Davanum Srinivas <di...@yahoo.com>.
Ok by me.

Thanks,
dims

--- Glen Daniels <gd...@macromedia.com> wrote:
> 
> Hi dims!
> 
> I think we can actually remove the get(localName) clause entirely, and just use the
> xmlNameToJava() version.
> 
> --G
> 
> > -----Original Message-----
> > From: dims@apache.org [mailto:dims@apache.org]
> > Sent: Tuesday, March 12, 2002 8:48 AM
> > To: xml-axis-cvs@apache.org
> > Subject: cvs commit: xml-axis/java/src/org/apache/axis/encoding/ser
> > BeanDeserializer.java
> > 
> > 
> > dims        02/03/12 05:47:54
> > 
> >   Modified:    java/src/org/apache/axis/encoding/ser 
> > BeanDeserializer.java
> >   Log:
> >   Need this fix to get our WSDL2Java generated code to work 
> > with Microsoft's "C# DataTypes.asmx" Web Service sample.
> >   
> >   Revision  Changes    Path
> >   1.12      +6 -4      
> > xml-axis/java/src/org/apache/axis/encoding/ser/BeanDeserializer.java
> >   
> >   Index: BeanDeserializer.java
> >   ===================================================================
> >   RCS file: 
> > /home/cvs/xml-axis/java/src/org/apache/axis/encoding/ser/BeanD
> > eserializer.java,v
> >   retrieving revision 1.11
> >   retrieving revision 1.12
> >   diff -u -r1.11 -r1.12
> >   --- BeanDeserializer.java	9 Mar 2002 19:29:48 -0000	1.11
> >   +++ BeanDeserializer.java	12 Mar 2002 13:47:54 -0000	1.12
> >   @@ -161,12 +161,14 @@
> >            }
> >    
> >            if (propDesc == null) {
> >   -            // look for a field by this name.  Assumes the 
> > the number of
> >   -            // properties in a bean is (relatively) small, 
> > so uses a linear
> >   -            // search.
> >   +            // look for a field by this name.
> >                propDesc = (BeanPropertyDescriptor) 
> > propertyMap.get(localName);
> >            }
> >   -        
> >   +        if (propDesc == null) {
> >   +            // look for a field by the "adjusted" name.
> >   +            propDesc = (BeanPropertyDescriptor) 
> > propertyMap.get(JavaUtils.xmlNameToJava(localName));
> >   +        }
> >   +
> >            if (propDesc == null) {
> >                // No such field
> >                throw new SAXException(
> >   
> >   
> >   
> > 


=====
Davanum Srinivas - http://xml.apache.org/~dims/

__________________________________________________
Do You Yahoo!?
Try FREE Yahoo! Mail - the world's greatest free email!
http://mail.yahoo.com/