SchemaClassCollection.cs 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. //
  2. // System.Data.ObjectSpaces.Schema.SchemaClassCollection.cs
  3. //
  4. // Author:
  5. // Tim Coleman ([email protected])
  6. //
  7. // Copyright (C) Tim Coleman, 2003
  8. //
  9. #if NET_1_2
  10. using System.Collections;
  11. namespace System.Data.ObjectSpaces.Schema {
  12. public class SchemaClassCollection : CollectionBase
  13. {
  14. #region Properties
  15. public SchemaClass this [int index] {
  16. get { return (SchemaClass) List [index]; }
  17. }
  18. [MonoTODO]
  19. public SchemaClass this [string typeName] {
  20. get { throw new NotImplementedException (); }
  21. }
  22. #endregion // Properties
  23. #region Methods
  24. public void Add (SchemaClass schemaClass)
  25. {
  26. Insert (Count, schemaClass);
  27. }
  28. public bool Contains (SchemaClass schemaClass)
  29. {
  30. return List.Contains (schemaClass);
  31. }
  32. public void CopyTo (SchemaClass[] array, int index)
  33. {
  34. List.CopyTo (array, index);
  35. }
  36. public int IndexOf (SchemaClass schemaClass)
  37. {
  38. return List.IndexOf (schemaClass);
  39. }
  40. public void Insert (int index, SchemaClass schemaClass)
  41. {
  42. List.Insert (index, schemaClass);
  43. }
  44. [MonoTODO]
  45. protected override void OnInsert (int index, object value)
  46. {
  47. throw new NotImplementedException ();
  48. }
  49. [MonoTODO]
  50. protected override void OnRemove (int index, object value)
  51. {
  52. throw new NotImplementedException ();
  53. }
  54. public void Remove (SchemaClass schemaClass)
  55. {
  56. List.Remove (schemaClass);
  57. }
  58. #endregion // Methods
  59. }
  60. }
  61. #endif // NET_1_2