[ 
http://jira.codehaus.org/browse/XFIRE-768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_98315
 ] 

Samuel Clough commented on XFIRE-768:
-------------------------------------

Ok, I had this same problem and hunted it down and I'm not sure this is an 
xfire bug.  The problem seems to be the way .NET handles properties now that it 
has nullable types like DateTime in 2.0.  If your WSDL includes "minOccurs=0" 
and nillable=true (which are the defaults in xfire), then .NET is basically 
treating your date property as optional.  

You can verify this by noticing on your proxy object, .NET will build a 
propertyname and then a [propertyName]Specified property that you have to set 
to tell .NET to actually pass the property.  It's basically not passing the 
property because it thinks it's optional and it's trying to trim the WSDL 
passed.  I think you can get around this by setting the [propertyName]Specified 
property in your .NET classes, but to avoid confusion for .NET programmers, I 
just removed the minOccurs and nillable attributes from the WSDL, but 
defaulting Aegis to minOccurs=1 and nillable=false.  I'm now getting the date 
and time.

So this appears to be a configuration issue and perhaps even a .NET bug more 
than an xfire bug.  I mean, if you set the property in .NET you do want is 
passed across the wire, right? 

This blog post is what tipped me off to what was going on:
http://www.nileshk.com/node/69

> Pass DateTime 
> --------------
>
>                 Key: XFIRE-768
>                 URL: http://jira.codehaus.org/browse/XFIRE-768
>             Project: XFire
>          Issue Type: Bug
>    Affects Versions: 1.2.2
>         Environment: .net 2.0
>            Reporter: xfireuser
>            Assignee: Dan Diephouse
>
> In my Service Class has a method:
> public void setDate(Date date)
> {
>        System.out.println("callingDate: " + date);
> }
> use .NET client to call:
> client.setDate(DateTime.now);
> server output:
>          callingDate: null;
> how to pass a dateTime  DataType from ,NET to JAVA via xfire?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to