* ConformanceChecker.cs, BasicProfileChecker.cs: New files that implement
[mono.git] / mcs / class / System.Web.Services / System.Web.Services.Description / MessagePart.cs
1 // \r
2 // System.Web.Services.Description.MessagePart.cs\r
3 //\r
4 // Author:\r
5 //   Tim Coleman (tim@timcoleman.com)\r
6 //\r
7 // Copyright (C) Tim Coleman, 2002\r
8 //\r
9
10 //
11 // Permission is hereby granted, free of charge, to any person obtaining
12 // a copy of this software and associated documentation files (the
13 // "Software"), to deal in the Software without restriction, including
14 // without limitation the rights to use, copy, modify, merge, publish,
15 // distribute, sublicense, and/or sell copies of the Software, and to
16 // permit persons to whom the Software is furnished to do so, subject to
17 // the following conditions:
18 // 
19 // The above copyright notice and this permission notice shall be
20 // included in all copies or substantial portions of the Software.
21 // 
22 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
23 // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
24 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
25 // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
26 // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
27 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
28 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
29 //
30 \r
31 using System.Xml;\r
32 using System.Xml.Serialization;\r
33 \r
34 namespace System.Web.Services.Description \r
35 {\r
36         public sealed class MessagePart :\r
37 #if NET_2_0\r
38                 NamedItem\r
39 #else\r
40                 DocumentableItem \r
41 #endif\r
42         {\r
43 \r
44                 #region Fields\r
45 \r
46                 XmlQualifiedName element;\r
47                 Message message;\r
48 #if !NET_2_0\r
49                 string name;\r
50 #endif\r
51                 XmlQualifiedName type;\r
52 \r
53                 #endregion // Fields\r
54 \r
55                 #region Constructors\r
56                 \r
57                 public MessagePart ()\r
58                 {\r
59                         element = XmlQualifiedName.Empty;\r
60                         message = null;\r
61 #if !NET_2_0\r
62                         name = String.Empty;\r
63 #endif\r
64                         type = XmlQualifiedName.Empty;\r
65                 }\r
66                 \r
67                 #endregion // Constructors\r
68 \r
69                 #region Properties\r
70 \r
71                 [XmlAttribute ("element")]\r
72                 public XmlQualifiedName Element {\r
73                         get { return element; }\r
74                         set { element = value; }\r
75                 }\r
76                 \r
77 //              [XmlIgnore]\r
78                 public Message Message {\r
79                         get { return message; }\r
80                 }\r
81         \r
82 #if !NET_2_0\r
83                 [XmlAttribute ("name", DataType = "NMTOKEN")]\r
84                 public string Name {\r
85                         get { return name; }\r
86                         set { name = value; }\r
87                 }\r
88 #endif\r
89 \r
90                 [XmlAttribute ("type")]\r
91                 public XmlQualifiedName Type {\r
92                         get { return type; }\r
93                         set { type = value; }\r
94                 }\r
95 \r
96                 #endregion // Properties\r
97 \r
98                 #region Methods\r
99 \r
100                 internal void SetParent (Message message)\r
101                 {\r
102                         this.message = message; \r
103                 }\r
104 \r
105                 #endregion // Methods\r
106 \r
107         }\r
108 }\r