source: Include/Classes/System/Collections/misc.ab@ 176

Last change on this file since 176 was 118, checked in by イグトランス (egtra), 18 years ago

とりあえずおおよそ実装した(未テスト)

File size: 2.9 KB
Line 
1' Classes/System/Collections/misc.ab
2
3#ifndef __SYSTEM_COLLECTIONS_MISC_AB__
4#define __SYSTEM_COLLECTIONS_MISC_AB__
5
6Interface ICollection
7 Inherits IEnumerable
8 ' Properties
9 '/*Const*/ Function Count() As Long
10 '/*Const*/ Function IsSynchronized() As Boolean
11 ' Function SyncRoot() As ...
12 ' Methods
13 ' Sub CopyTo(ByRef array As ..., index As Long)
14End Interface
15
16Interface IComparer
17 ' Methods
18 Function Compare(ByRef x As Object, ByRef y As Object) As Long
19End Interface
20
21Interface IDictionary
22 Inherits ICollection /*, IEnumerable */
23 ' Methods
24 Sub Add(ByRef key As Object, ByRef value As Object)
25 Sub Clear()
26 /*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
29 ' Properties
30 /*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
36End Interface
37
38Interface IDictionaryEnumerator
39 Inherits IEnumerator
40 ' Properties
41 /*Const*/ Function Entry() As DictionaryEntry
42 /*Const*/ Function Key() As *Object
43 /*Const*/ Function Value() As *Object
44End Interface
45
46Interface IEnumerable
47 ' Method
48' Function GetEnumerator() As *IEnumerator
49End Interface
50
51Interface IEnumerator
52 ' Methods
53 Function MoveNext() As Boolean
54 Sub Reset()
55 ' Property
56 Function Current() As *Object
57End Interface
58
59Interface IEqualityComparer
60 ' Methods
61 Function Equals(ByRef x As Object, ByRef y As Object) As Boolean
62 Function GetHashCode(ByRef obj As Object) As Long
63End Interface
64
65Interface IList
66 Inherits ICollection /*, IEnumerable */
67 ' Methods
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)
74 Sub RemoveAt(index As Long)
75 ' Properties
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)
80End Interface
81
82Class DictionaryEntry
83Public
84 ' /*Const*/ructors
85 Sub DictionaryEntry()
86 k = 0
87 v = 0
88 End Sub
89
90 Sub DictionaryEntry(ByRef key As Object, ByRef value As Object)
91 k = VarPtr(key)
92 v = VarPtr(value)
93 End Sub
94
95 ' Properties
96 /*Const*/ Function Key() As *Object
97 Return k
98 End Function
99
100 Sub Key(ByRef key As Object)
101 k = VarPtr(key)
102 End Sub
103
104 /*Const*/ Function Value() As *Object
105 Return v
106 End Function
107
108 Sub Value(ByRef value As Object)
109 v = VarPtr(value)
110 End Sub
111Private
112 k As *Object
113 v As *Object
114End Class
115
116#endif '__SYSTEM_COLLECTIONS_MISC_AB__
Note: See TracBrowser for help on using the repository browser.