1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
|
--- source/common/uvector.cpp
+++ source/common/uvector.cpp
@@ -110,7 +110,7 @@
}
// This only does something sensible if this object has a non-null comparer
-UBool UVector::operator==(const UVector& other) {
+UBool UVector::operator==(const UVector& other) const {
int32_t i;
if (count != other.count) return FALSE;
if (comparer != NULL) {
--- source/common/uvector.h
+++ source/common/uvector.h
@@ -113,12 +113,12 @@
* equal if they are of the same size and all elements are equal,
* as compared using this object's comparer.
*/
- UBool operator==(const UVector& other);
+ UBool operator==(const UVector& other) const;
/**
* Equivalent to !operator==()
*/
- inline UBool operator!=(const UVector& other);
+ inline UBool operator!=(const UVector& other) const;
//------------------------------------------------------------
// java.util.Vector API
@@ -382,7 +382,7 @@
return elementAt(index);
}
-inline UBool UVector::operator!=(const UVector& other) {
+inline UBool UVector::operator!=(const UVector& other) const {
return !operator==(other);
}
--- source/i18n/tzrule.cpp
+++ source/i18n/tzrule.cpp
@@ -53,7 +53,7 @@
return *this;
}
-UBool
+bool
TimeZoneRule::operator==(const TimeZoneRule& that) const {
return ((this == &that) ||
(typeid(*this) == typeid(that) &&
@@ -120,7 +120,7 @@
return *this;
}
-UBool
+bool
InitialTimeZoneRule::operator==(const TimeZoneRule& that) const {
return ((this == &that) ||
(typeid(*this) == typeid(that) &&
@@ -226,7 +226,7 @@
return *this;
}
-UBool
+bool
AnnualTimeZoneRule::operator==(const TimeZoneRule& that) const {
if (this == &that) {
return TRUE;
@@ -445,7 +445,7 @@
return *this;
}
-UBool
+bool
TimeArrayTimeZoneRule::operator==(const TimeZoneRule& that) const {
if (this == &that) {
return TRUE;
--- source/i18n/unicode/rbtz.h
+++ source/i18n/unicode/rbtz.h
@@ -85,6 +85,7 @@
* @stable ICU 3.8
*/
virtual UBool operator!=(const TimeZone& that) const;
+ UBool operator!=(const RuleBasedTimeZone& that) const {return !operator==(that);}
/**
* Adds the <code>TimeZoneRule</code> which represents time transitions.
--- source/i18n/unicode/simpletz.h
+++ source/i18n/unicode/simpletz.h
@@ -110,6 +110,7 @@
* @stable ICU 2.0
*/
virtual UBool operator==(const TimeZone& that) const;
+ UBool operator!=(const SimpleTimeZone& that) const {return !operator==(that);}
/**
* Constructs a SimpleTimeZone with the given raw GMT offset and time zone ID,
--- source/i18n/unicode/smpdtfmt.h
+++ source/i18n/unicode/smpdtfmt.h
@@ -874,6 +874,7 @@
* @stable ICU 2.0
*/
virtual UBool operator==(const Format& other) const;
+ UBool operator!=(const SimpleDateFormat& that) const {return !operator==(that);}
using DateFormat::format;
--- source/i18n/unicode/stsearch.h
+++ source/i18n/unicode/stsearch.h
@@ -297,6 +297,7 @@
* @stable ICU 2.0
*/
virtual UBool operator==(const SearchIterator &that) const;
+ UBool operator!=(const StringSearch &that) const {return !operator==(that);}
// public get and set methods ----------------------------------------
--- source/i18n/unicode/tzrule.h
+++ source/i18n/unicode/tzrule.h
@@ -54,7 +54,7 @@
* @return true if the given <code>TimeZoneRule</code> objects are semantically equal.
* @stable ICU 3.8
*/
- virtual UBool operator==(const TimeZoneRule& that) const;
+ virtual bool operator==(const TimeZoneRule& that) const;
/**
* Return true if the given <code>TimeZoneRule</code> objects are semantically unequal. Objects
@@ -245,7 +245,7 @@
* @return true if the given <code>TimeZoneRule</code> objects are semantically equal.
* @stable ICU 3.8
*/
- virtual UBool operator==(const TimeZoneRule& that) const;
+ virtual bool operator==(const TimeZoneRule& that) const;
/**
* Return true if the given <code>TimeZoneRule</code> objects are semantically unequal. Objects
@@ -255,6 +255,7 @@
* @stable ICU 3.8
*/
virtual UBool operator!=(const TimeZoneRule& that) const;
+ UBool operator!=(const InitialTimeZoneRule& that) const {return !operator==(that);}
/**
* Gets the time when this rule takes effect in the given year.
@@ -456,7 +457,7 @@
* @return true if the given <code>TimeZoneRule</code> objects are semantically equal.
* @stable ICU 3.8
*/
- virtual UBool operator==(const TimeZoneRule& that) const;
+ virtual bool operator==(const TimeZoneRule& that) const;
/**
* Return true if the given <code>TimeZoneRule</code> objects are semantically unequal. Objects
@@ -672,7 +673,7 @@
* @return true if the given <code>TimeZoneRule</code> objects are semantically equal.
* @stable ICU 3.8
*/
- virtual UBool operator==(const TimeZoneRule& that) const;
+ virtual bool operator==(const TimeZoneRule& that) const;
/**
* Return true if the given <code>TimeZoneRule</code> objects are semantically unequal. Objects
--- source/i18n/unicode/vtzone.h
+++ source/i18n/unicode/vtzone.h
@@ -81,6 +81,7 @@
* @stable ICU 3.8
*/
virtual UBool operator!=(const TimeZone& that) const;
+ UBool operator!=(const VTimeZone& that) const {return !operator==(that);}
/**
* Create a <code>VTimeZone</code> instance by the time zone ID.
|