[Mono-bugs] [Bug 54461][Nor] New - XmlInclude not supported on web service methods

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 17 Feb 2004 11:36:21 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by krisolav@hotmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=54461

--- shadow/54461	2004-02-17 11:36:20.000000000 -0500
+++ shadow/54461.tmp.13316	2004-02-17 11:36:20.000000000 -0500
@@ -0,0 +1,60 @@
+Bug#: 54461
+Product: Mono/Class Libraries
+Version: unspecified
+OS: Debian Woody
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: Sys.Web.Services
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: krisolav@hotmail.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: XmlInclude not supported on web service methods
+
+Please fill in this template when reporting a bug, unless you know what 
+you are doing.
+Description of Problem:
+I’d like to have a web service method that returns an array of custom 
+types.  I wrote a simple test that works under MS .NET, but not under Mono.
+
+Steps to reproduce the problem:
+1. Add the following method to a web service:
+    [WebMethod] 
+    [XmlInclude(typeof(ComplexThing))] 
+    public ArrayList foo() 
+    { 
+        ArrayList list = new ArrayList(); 
+        list.Add(new ComplexThing("abc", 1.1f)); 
+        list.Add(new ComplexThing("xyz", 2.0f)); 
+        return list; 
+    } 
+2. Add the code for ComplexThing:
+    public class ComplexThing 
+    { 
+        public ComplexThing() {} 
+
+        public ComplexThing(string name, float val) 
+        { 
+            this.name = name; 
+            this.val = val; 
+        } 
+        public string name; 
+        public float val; 
+    } 
+3. Try to access the web service
+
+Actual Results:
+Invalid type: TestService.ComplexThing 
+
+Expected Results:
+The array is sent back
+
+How often does this happen? 
+Every time
+
+Additional Information: