in .:
authorJb Evain <jbevain@gmail.com>
Tue, 9 Sep 2008 13:34:57 +0000 (13:34 -0000)
committerJb Evain <jbevain@gmail.com>
Tue, 9 Sep 2008 13:34:57 +0000 (13:34 -0000)
2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
Jb Evain  <jbevain@novell.com>

* net_2_1_raw_System.Runtime.Serialization.dll.sources: new sources
file for the SL2 profile.
* Makefile: add support for SL2 profile.

in System.Xml.Schema:
2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
Jb Evain  <jbevain@novell.com>

* XmlSchema.cs: add helper internal class.

in System.Xml:
2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
Jb Evain  <jbevain@novell.com>

* XmlBinaryDictionaryReader.cs, XmlSimpleDictionaryReader.cs:
add support to build on the net_2_1 profile.

in System.Runtime.Serialization:
2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
Jb Evain  <jbevain@novell.com>

* IDataContractSurrogater.cs, SerializationMap.cs:
add support to build on the net_2_1 profile.

svn path=/trunk/mcs/; revision=112586

mcs/class/System.Runtime.Serialization/ChangeLog
mcs/class/System.Runtime.Serialization/Makefile
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/ChangeLog
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/IDataContractSurrogate.cs
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/SerializationMap.cs
mcs/class/System.Runtime.Serialization/System.Xml.Schema/ChangeLog [new file with mode: 0644]
mcs/class/System.Runtime.Serialization/System.Xml.Schema/XmlSchema.cs [new file with mode: 0644]
mcs/class/System.Runtime.Serialization/System.Xml/ChangeLog
mcs/class/System.Runtime.Serialization/System.Xml/XmlBinaryDictionaryReader.cs
mcs/class/System.Runtime.Serialization/System.Xml/XmlSimpleDictionaryReader.cs
mcs/class/System.Runtime.Serialization/net_2_1_raw_System.Runtime.Serialization.dll.sources [new file with mode: 0644]

index f9eaf00f188c4b815d6cc66f19c562a1dc8cc8b8..09b5024d2cdc76795b8d507319f730842523e732 100644 (file)
@@ -1,3 +1,10 @@
+2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
+                       Jb Evain  <jbevain@novell.com>
+
+       * net_2_1_raw_System.Runtime.Serialization.dll.sources: new sources
+       file for the SL2 profile.
+       * Makefile: add support for SL2 profile.
+
 2008-03-31  Igor Zelmanovich <igorz@mainsoft.com>
 
        * Makefile : add reference to System.Data.dll, 
index 817abcd6bfaaa88b13b71fa96b31cc4987289512..9d30188b5c5db9f43d8daa17a03db6a8ad8b2bd3 100644 (file)
@@ -7,13 +7,14 @@ RESOURCE_FILES = \
 
 LIBRARY = System.Runtime.Serialization.dll
 LIB_MCS_FLAGS = \
-                       /d:NET_3_0      \
                        /nowarn:168,169,219,414 \
                /r:System.dll \
                /r:System.Xml.dll \
-               /r:System.Data.dll \
-               /r:System.Configuration.dll \
-               $(RESOURCE_FILES:%=/resource:%)
+               $(RESOURCE_FILES:%=/resource:%)
+
+ifneq (2.1, $(FRAMEWORK_VERSION))
+LIB_MCS_FLAGS += /d:NET_3_0 /r:System.Data.dll /r:System.Configuration.dll
+endif
 
 TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) /r:System.ServiceModel.dll
 
index 6cab997fef5996cff6acfe88cb95a1606383bd07..c84f9926706cb384789978561082860d7683d910 100755 (executable)
@@ -1,3 +1,9 @@
+2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
+                       Jb Evain  <jbevain@novell.com>
+
+       * IDataContractSurrogater.cs, SerializationMap.cs:
+       add support to build on the net_2_1 profile.
+
 2008-06-19  Noam Lampert <noaml@mainsoft.com>
        
        * KnownTypeCollection.cs: Support anyUri type
index dce5a5a29085d6df565beacd7bf7174ffbe9ba1c..ac08aad202eff42e5291433c6475ea2d1f3cd8b8 100644 (file)
@@ -47,14 +47,14 @@ namespace System.Runtime.Serialization
                void GetKnownCustomDataTypes (Collection<Type> customDataTypes);
 
                object GetObjectToSerialize (object obj, Type targetType);
-
+#if !NET_2_1
                Type GetReferencedTypeOnImport (string typeName,
                        string typeNamespace, object customData);
 
                CodeTypeDeclaration ProcessImportedType (
                        CodeTypeDeclaration typeDeclaration,
                        CodeCompileUnit compileUnit);
-
+#endif
        }
 }
 #endif
index e5a1e6595f235093bf21475cc2b6a7bdcc02e56c..6dc8b22e7ac246b7911011ace6dd685699b76a72 100644 (file)
@@ -87,7 +87,9 @@ namespace System.Runtime.Serialization
                public readonly Type RuntimeType;
                public readonly QName XmlName;
                public List<DataMemberInfo> Members;
+#if !NET_2_1
                XmlSchemaSet schema_set;
+#endif
  
                //FIXME FIXME
                Dictionary<Type, QName> qname_table = new Dictionary<Type, QName> ();
@@ -120,6 +122,7 @@ namespace System.Runtime.Serialization
                        return (Type.GetTypeCode (type) != TypeCode.Object || type == typeof (object));
                }
 
+#if !NET_2_1
                /* Returns the XmlSchemaType AND adds it to @schemas */
                public virtual XmlSchemaType GetSchemaType (XmlSchemaSet schemas, Dictionary<QName, XmlSchemaType> generated_schema_types)
                {
@@ -221,6 +224,7 @@ namespace System.Runtime.Serialization
                        imp.Namespace = ns;
                        schema.Includes.Add (imp);
                }
+#endif
 
                //Returns list of data members for this type ONLY
                public virtual List<DataMemberInfo> GetMembers ()
@@ -228,6 +232,7 @@ namespace System.Runtime.Serialization
                        throw new NotImplementedException (String.Format ("Implement me for {0}", this));
                }
 
+#if !NET_2_1
                protected XmlSchemaElement GetSchemaElement (QName qname, XmlSchemaType schemaType)
                {
                        XmlSchemaElement schemaElement = new XmlSchemaElement ();
@@ -259,6 +264,7 @@ namespace System.Runtime.Serialization
 
                        return schema;
                }
+#endif
 
                //FIXME: redundant?
                protected XmlQualifiedName GetQualifiedName (Type type)
@@ -490,6 +496,7 @@ namespace System.Runtime.Serialization
                        throw new NotImplementedException ();
                }
                
+#if !NET_2_1
                public override XmlSchemaType GetSchemaType (XmlSchemaSet schemas, Dictionary<QName, XmlSchemaType> generated_schema_types)
                {
                        if (generated_schema_types.ContainsKey (XmlName))
@@ -531,6 +538,7 @@ namespace System.Runtime.Serialization
 
                        return complex_type;
                }
+#endif
        }
 
        internal class SharedTypeMap : SerializationMap
@@ -615,6 +623,7 @@ namespace System.Runtime.Serialization
                        return (EnumMemberAttribute) atts [0];
                }
 
+#if !NET_2_1
                public override XmlSchemaType GetSchemaType (XmlSchemaSet schemas, Dictionary<QName, XmlSchemaType> generated_schema_types)
                {
                        if (generated_schema_types.ContainsKey (XmlName))
@@ -644,6 +653,7 @@ namespace System.Runtime.Serialization
 
                        return simpleType;
                }
+#endif
 
                public override void Serialize (object graph,
                        XmlFormatterSerializer serializer)
diff --git a/mcs/class/System.Runtime.Serialization/System.Xml.Schema/ChangeLog b/mcs/class/System.Runtime.Serialization/System.Xml.Schema/ChangeLog
new file mode 100644 (file)
index 0000000..7182f05
--- /dev/null
@@ -0,0 +1,4 @@
+2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
+                       Jb Evain  <jbevain@novell.com>
+
+       * XmlSchema.cs: add helper internal class.
diff --git a/mcs/class/System.Runtime.Serialization/System.Xml.Schema/XmlSchema.cs b/mcs/class/System.Runtime.Serialization/System.Xml.Schema/XmlSchema.cs
new file mode 100644 (file)
index 0000000..f1f9610
--- /dev/null
@@ -0,0 +1,41 @@
+//
+// System.Xml.Schema/XmlSchema.cs
+//
+// Author:
+//     Atsushi Enomoto <atsushi@ximian.com>
+//
+// Copyright (C) 2008 Novell, Inc.  http://www.novell.com
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+// This is a dummy class that just holds constants
+
+#if NET_2_1
+
+namespace System.Xml.Schema
+{
+       internal class XmlSchema
+       {
+               public const string Namespace = "http://www.w3.org/2001/XMLSchema";
+               public const string InstanceNamespace = "http://www.w3.org/2001/XMLSchema-instance";
+       }
+}
+#endif
index 88c98281e95596bc9296be4481a4cb73727594b5..f08e2f984e77c6ed689edd39e68c6193893b3432 100755 (executable)
@@ -1,3 +1,9 @@
+2008-09-09  Atsushi Enomoto  <atsushi@ximian.com>
+                       Jb Evain  <jbevain@novell.com>
+
+       * XmlBinaryDictionaryReader.cs, XmlSimpleDictionaryReader.cs:
+       add support to build on the net_2_1 profile.
+
 2008-04-10  Eyal Alaluf <eyala@mainsoft.com>
 
        * XmlBinaryDictionaryWriter.cs: WriteXmlnsAttribute generates a prefix
index e5387f00e5c113fa547365b51018a63f2b3489b0..1c53348c23421d35cf524c230ad0bcf1601dffa4 100644 (file)
@@ -306,9 +306,11 @@ namespace System.Xml
                        get { return state == ReadState.EndOfFile || state == ReadState.Error; }
                }
 
+#if !NET_2_1
                public override bool HasValue {
                        get { return current.Value.Length > 0; }
                }
+#endif
 
                public override bool IsEmptyElement {
                        get { return false; }
@@ -452,6 +454,7 @@ namespace System.Xml
                        return false;
                }
 
+#if !NET_2_1
                public override bool ReadAttributeValue ()
                {
                        if (current_attr < 0)
@@ -472,6 +475,7 @@ namespace System.Xml
                        }
                        return false;
                }
+#endif
 
                public override bool Read ()
                {
index 50ba24b9870784505a2edfc38b3196b0425e7d7b..62a17193d52f1f16784800fdb691a1cf73d47014 100644 (file)
@@ -144,9 +144,11 @@ namespace System.Xml
                        get { return reader.Prefix; }
                }
 
+#if !NET_2_1
                public override bool HasValue {
                        get { return reader.HasValue; }
                }
+#endif
 
                public override string Value {
                        get { return reader.Value; }
@@ -291,12 +293,12 @@ namespace System.Xml
                {
                        reader.ResolveEntity ();
                }
-
+#if !NET_2_1
                public override bool ReadAttributeValue ()
                {
                        return reader.ReadAttributeValue ();
                }
-
+#endif
                #endregion
        }
 }
diff --git a/mcs/class/System.Runtime.Serialization/net_2_1_raw_System.Runtime.Serialization.dll.sources b/mcs/class/System.Runtime.Serialization/net_2_1_raw_System.Runtime.Serialization.dll.sources
new file mode 100644 (file)
index 0000000..b093468
--- /dev/null
@@ -0,0 +1,49 @@
+../../build/common/Consts.cs
+../../build/common/Locale.cs
+../../build/common/MonoTODOAttribute.cs
+Assembly/AssemblyInfo.cs
+System.Runtime.Serialization/CollectionDataContractAttribute.cs
+System.Runtime.Serialization/ContractNamespaceAttribute.cs
+System.Runtime.Serialization/DataContractAttribute.cs
+System.Runtime.Serialization/DataContractSerializer.cs
+System.Runtime.Serialization/DataMemberAttribute.cs
+System.Runtime.Serialization/EnumMemberAttribute.cs
+System.Runtime.Serialization/ExportOptions.cs
+System.Runtime.Serialization/ExtensionDataObject.cs
+System.Runtime.Serialization/IDataContractSurrogate.cs
+System.Runtime.Serialization/IExtensibleDataObject.cs
+System.Runtime.Serialization/InvalidDataContractException.cs
+System.Runtime.Serialization/KnownTypeAttribute.cs
+System.Runtime.Serialization/KnownTypeCollection.cs
+System.Runtime.Serialization/NetDataContractSerializer.cs
+System.Runtime.Serialization/SerializationMap.cs
+System.Runtime.Serialization/XmlFormatterDeserializer.cs
+System.Runtime.Serialization/XmlFormatterSerializer.cs
+System.Runtime.Serialization/XmlObjectSerializer.cs
+System.Xml/IStreamProvider.cs
+System.Xml/IXmlBinaryReaderInitializer.cs
+System.Xml/IXmlBinaryWriterInitializer.cs
+System.Xml/IXmlDictionary.cs
+System.Xml/IXmlMtomReaderInitializer.cs
+System.Xml/IXmlMtomWriterInitializer.cs
+System.Xml/IXmlUTF8ReaderInitializer.cs
+System.Xml/IXmlUTF8WriterInitializer.cs
+System.Xml/OnXmlDictionaryReaderClose.cs
+System.Xml/UniqueId.cs
+System.Xml/XmlBinaryDictionaryReader.cs
+System.Xml/XmlBinaryDictionaryWriter.cs
+System.Xml/XmlBinaryFormat.cs
+System.Xml/XmlBinaryReaderSession.cs
+System.Xml/XmlBinaryWriterSession.cs
+System.Xml/XmlC14NWriter.cs
+System.Xml/XmlCanonicalWriter.cs
+System.Xml/XmlDictionary.cs
+System.Xml/XmlDictionaryReader.cs
+System.Xml/XmlDictionaryReaderAutoGen.cs
+System.Xml/XmlDictionaryReaderQuotas.cs
+System.Xml/XmlDictionaryString.cs
+System.Xml/XmlDictionaryWriter.cs
+System.Xml/XmlDictionaryWriterAutoGen.cs
+System.Xml/XmlSimpleDictionaryReader.cs
+System.Xml/XmlSimpleDictionaryWriter.cs
+System.Xml.Schema/XmlSchema.cs