Changeset 118 for Include/Classes/System/Collections/misc.ab
- Timestamp:
- Feb 23, 2007, 10:48:08 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Include/Classes/System/Collections/misc.ab
r55 r118 4 4 #define __SYSTEM_COLLECTIONS_MISC_AB__ 5 5 6 Interface IObject7 End Interface8 9 6 Interface ICollection 10 Inherits /* IObject, */IEnumerable7 Inherits IEnumerable 11 8 ' Properties 12 ConstFunction Count() As Long13 Const Function IsSynchronized() As BOOL9 '/*Const*/ Function Count() As Long 10 '/*Const*/ Function IsSynchronized() As Boolean 14 11 ' Function SyncRoot() As ... 15 12 ' Methods … … 18 15 19 16 Interface IComparer 20 Inherits IObject21 17 ' Methods 22 Function Compare(ByRef x As IObject, ByRef y As IObject) As Long18 Function Compare(ByRef x As Object, ByRef y As Object) As Long 23 19 End Interface 24 20 25 21 Interface IDictionary 26 Inherits /*IObject, */ICollection /*, IEnumerable */22 Inherits ICollection /*, IEnumerable */ 27 23 ' Methods 28 Sub Add(ByRef key As IObject, ByRef value As IObject)24 Sub Add(ByRef key As Object, ByRef value As Object) 29 25 Sub Clear() 30 Const Function Contains(ByRef key As IObject) As BOOL31 ConstFunction GetEnumerator() As *IDictionaryEnumerator32 Const Function Remove(ByRef key As IObject) As BOOL26 /*Const*/ Function Contains(ByRef key As Object) As Boolean 27 ' /*Const*/ Function GetEnumerator() As *IDictionaryEnumerator 28 /*Const*/ Function Remove(ByRef key As Object) As Boolean 33 29 ' Properties 34 Const Function IsFixedSize() As BOOL35 Const Function IsReadOnly() As BOOL36 Const Function Operator [](ByRef key As IObject) As *IObject37 Sub Operator []=(ByRef key As IObject, ByRef value As IObject)38 ConstFunction Keys() As *ICollection39 ConstFunction Values() As ICollection30 /*Const*/ Function IsFixedSize() As Boolean 31 /*Const*/ Function IsReadOnly() As Boolean 32 ' /*Const*/ Function Operator [](ByRef key As Object) As *Object 33 ' Sub Operator []=(ByRef key As Object, ByRef value As Object) 34 /*Const*/ Function Keys() As *ICollection 35 /*Const*/ Function Values() As ICollection 40 36 End Interface 41 37 … … 43 39 Inherits IEnumerator 44 40 ' Properties 45 ConstFunction Entry() As DictionaryEntry46 Const Function Key() As *IObject47 Const Function Value() As *IObject41 /*Const*/ Function Entry() As DictionaryEntry 42 /*Const*/ Function Key() As *Object 43 /*Const*/ Function Value() As *Object 48 44 End Interface 49 45 50 46 Interface IEnumerable 51 Inherits IObject52 47 ' Method 53 Function GetEnumerator() As *IEnumerator48 ' Function GetEnumerator() As *IEnumerator 54 49 End Interface 55 50 56 51 Interface IEnumerator 57 Inherits IObject58 52 ' Methods 59 Function MoveNext() As B OOL53 Function MoveNext() As Boolean 60 54 Sub Reset() 61 55 ' Property 62 Function Current() As * IObject56 Function Current() As *Object 63 57 End Interface 64 58 65 59 Interface IEqualityComparer 66 Inherits IObject67 60 ' Methods 68 Function Equals(ByRef x As Object, ByRef y As Object) As B OOL69 Function GetHashCode(ByRef obj As IObject) As Long61 Function Equals(ByRef x As Object, ByRef y As Object) As Boolean 62 Function GetHashCode(ByRef obj As Object) As Long 70 63 End Interface 71 64 … … 73 66 Inherits ICollection /*, IEnumerable */ 74 67 ' Methods 75 Function Add(ByRef value As IObject) As Long76 Sub Clear()77 Const Function Contains(ByRef value As IObject) As BOOL78 Const Function IndexOf(ByRef value As IObject) As Long79 Sub Insert(index As Long, ByRef value As IObject)80 Sub Remove( ByRef value As IObject)68 'Function Add(value As *Object) As Long 69 'Sub Clear() 70 '/*Const*/ Function Contains(value As *Object) As Boolean 71 /*Const*/ Function IndexOf(value As *Object) As Long 72 Sub Insert(index As Long, value As *Object) 73 Sub Remove(value As *Object) 81 74 Sub RemoveAt(index As Long) 82 75 ' Properties 83 Const Function IsFixedSize() As BOOL84 Const Function IsReadOnly() As BOOL85 Const Function Operator [](index As Long) As *IObject86 Const Sub Operator []=(index As Long, ByRef obj As IObject)76 /*Const*/ Function IsFixedSize() As Boolean 77 /*Const*/ Function IsReadOnly() As Boolean 78 '/*Const*/ Function Operator [](index As Long) As *Object 79 '/*Const*/ Sub Operator []=(index As Long, obj As *Object) 87 80 End Interface 88 81 89 82 Class DictionaryEntry 90 Inherits IObject91 83 Public 92 ' Constructors84 ' /*Const*/ructors 93 85 Sub DictionaryEntry() 94 86 k = 0 … … 96 88 End Sub 97 89 98 Sub DictionaryEntry(ByRef key As IObject, ByRef value As IObject)90 Sub DictionaryEntry(ByRef key As Object, ByRef value As Object) 99 91 k = VarPtr(key) 100 92 v = VarPtr(value) … … 102 94 103 95 ' Properties 104 Const Function Key() As *IObject96 /*Const*/ Function Key() As *Object 105 97 Return k 106 98 End Function 107 99 108 Sub Key(ByRef key As IObject)100 Sub Key(ByRef key As Object) 109 101 k = VarPtr(key) 110 102 End Sub 111 103 112 Const Function Value() As *IObject104 /*Const*/ Function Value() As *Object 113 105 Return v 114 106 End Function 115 107 116 Sub Value(ByRef value As IObject)108 Sub Value(ByRef value As Object) 117 109 v = VarPtr(value) 118 110 End Sub 119 111 Private 120 k As * IObject121 v As * IObject112 k As *Object 113 v As *Object 122 114 End Class 123 115
Note:
See TracChangeset
for help on using the changeset viewer.