New test.
[mono.git] / mcs / class / System / System.Configuration / SettingElementCollection.cs
index cd960fc8af58dd1fc1a0f9378ace5891732287b5..725158ac7a90d875fdabdc7351a081a4e2bf4e5e 100644 (file)
@@ -31,7 +31,10 @@ using System;
 
 namespace System.Configuration
 {
-       public sealed class SettingElementCollection : ConfigurationElementCollection
+       public sealed class SettingElementCollection
+#if (CONFIGURATION_DEP)
+               : ConfigurationElementCollection
+#endif
        {
                public SettingElementCollection ()
                {
@@ -56,36 +59,30 @@ namespace System.Configuration
                }
 
                [MonoTODO]
-               public void Remove (string elementKey)
+               public void Remove (SettingElement element)
                {
                        throw new NotImplementedException ();
                }
 
-               [MonoTODO]
+#if (CONFIGURATION_DEP)
                protected override ConfigurationElement CreateNewElement ()
                {
-                       throw new NotImplementedException ();
+                       return new SettingElement ();
                }
 
-               [MonoTODO]
                protected override object GetElementKey (ConfigurationElement element)
                {
-                       throw new NotImplementedException ();
+                       return ((SettingElement) element).Name;
                }
 
-               [MonoTODO]
-               protected override ConfigurationElementCollectionType CollectionType {
-                       get {
-                               throw new NotImplementedException ();
-                       }
+               public override ConfigurationElementCollectionType CollectionType {
+                       get { return ConfigurationElementCollectionType.BasicMap; }
                }
 
-               [MonoTODO]
                protected override string ElementName {
-                       get {
-                               throw new NotImplementedException ();
-                       }
+                       get { return "setting"; }
                }
+#endif
        }
 
 }