source: branch/egtra-gdiplus/Classes/System/Drawing/CharacterRange.ab@ 711

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

GDI+に対して名前空間で囲ったものの、現在コンパイルできないため分岐させておく

File size: 1.1 KB
Line 
1' Classes/System/Drawing/CharacterRange.ab
2
3#ifndef __SYSTEM_DRAWING_CHARACTERRANGE_AB__
4#define __SYSTEM_DRAWING_CHARACTERRANGE_AB__
5
6Namespace System
7Namespace Drawing
8
9Class CharacterRange
10Public
11 Sub CharacterRange(f As Long, l As Long)
12 first = f
13 length = l
14 End Sub
15
16 Sub CharacterRange()
17 First = 0
18 Length = 0
19 End Sub
20
21 Function First() As Long
22 Return first
23 End Function
24
25 Sub First(f As Long)
26 first = f
27 End Sub
28
29 Function Length() As Long
30 Return l
31 End Function
32
33 Sub Length(l As Long)
34 length = l
35 End Sub
36
37 Function Operator ==(c As CharacterRange)
38 Return Equals(c)
39 End Function
40
41 Function Operator <>(c As CharacterRange)
42 Return Not Equals(c)
43 End Function
44
45 Function Equals(c As CharacterRange)
46 Return first = c.first And length = c.length
47 End Function
48
49 Override Function GetHashCode() As Long
50 Return first Xor length
51 End Function
52
53Private
54 first As Long
55 length As Long
56End Class
57
58End Namespace 'Drawing
59End Namespace 'System
60
61
62#endif '__SYSTEM_DRAWING_CHARACTERRANGE_AB__
Note: See TracBrowser for help on using the repository browser.