Home
last modified time | relevance | path

Searched refs:expectedValue (Results 1 – 25 of 27) sorted by relevance

12

/libcore/ojluni/src/main/java/java/util/concurrent/atomic/
DAtomicBoolean.java101 public final boolean compareAndSet(boolean expectedValue, boolean newValue) { in compareAndSet() argument
103 (expectedValue ? 1 : 0), in compareAndSet()
124 public boolean weakCompareAndSet(boolean expectedValue, boolean newValue) { in weakCompareAndSet() argument
126 (expectedValue ? 1 : 0), in weakCompareAndSet()
140 public boolean weakCompareAndSetPlain(boolean expectedValue, boolean newValue) { in weakCompareAndSetPlain() argument
142 (expectedValue ? 1 : 0), in weakCompareAndSetPlain()
267 public final boolean compareAndExchange(boolean expectedValue, boolean newValue) { in compareAndExchange() argument
269 (expectedValue ? 1 : 0), in compareAndExchange()
285 public final boolean compareAndExchangeAcquire(boolean expectedValue, boolean newValue) { in compareAndExchangeAcquire() argument
287 (expectedValue ? 1 : 0), in compareAndExchangeAcquire()
[all …]
DAtomicLong.java167 public final boolean compareAndSet(long expectedValue, long newValue) { in compareAndSet() argument
170 return VALUE.compareAndSet(this, expectedValue, newValue); in compareAndSet()
190 public final boolean weakCompareAndSet(long expectedValue, long newValue) { in weakCompareAndSet() argument
193 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSet()
206 public final boolean weakCompareAndSetPlain(long expectedValue, long newValue) { in weakCompareAndSetPlain() argument
209 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSetPlain()
532 public final long compareAndExchange(long expectedValue, long newValue) { in compareAndExchange() argument
535 return (long)VALUE.compareAndExchange(this, expectedValue, newValue); in compareAndExchange()
550 public final long compareAndExchangeAcquire(long expectedValue, long newValue) { in compareAndExchangeAcquire() argument
553 return (long)VALUE.compareAndExchangeAcquire(this, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
DAtomicInteger.java150 public final boolean compareAndSet(int expectedValue, int newValue) { in compareAndSet() argument
153 return VALUE.compareAndSet(this, expectedValue, newValue); in compareAndSet()
173 public final boolean weakCompareAndSet(int expectedValue, int newValue) { in weakCompareAndSet() argument
176 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSet()
189 public final boolean weakCompareAndSetPlain(int expectedValue, int newValue) { in weakCompareAndSetPlain() argument
192 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSetPlain()
517 public final int compareAndExchange(int expectedValue, int newValue) { in compareAndExchange() argument
520 return (int)VALUE.compareAndExchange(this, expectedValue, newValue); in compareAndExchange()
535 public final int compareAndExchangeAcquire(int expectedValue, int newValue) { in compareAndExchangeAcquire() argument
538 return (int)VALUE.compareAndExchangeAcquire(this, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
DAtomicReference.java122 public final boolean compareAndSet(V expectedValue, V newValue) { in compareAndSet() argument
123 return VALUE.compareAndSet(this, expectedValue, newValue); in compareAndSet()
143 public final boolean weakCompareAndSet(V expectedValue, V newValue) { in weakCompareAndSet() argument
144 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSet()
157 public final boolean weakCompareAndSetPlain(V expectedValue, V newValue) { in weakCompareAndSetPlain() argument
158 return VALUE.weakCompareAndSetPlain(this, expectedValue, newValue); in weakCompareAndSetPlain()
360 public final V compareAndExchange(V expectedValue, V newValue) { in compareAndExchange() argument
361 return (V)VALUE.compareAndExchange(this, expectedValue, newValue); in compareAndExchange()
376 public final V compareAndExchangeAcquire(V expectedValue, V newValue) { in compareAndExchangeAcquire() argument
377 return (V)VALUE.compareAndExchangeAcquire(this, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
DAtomicLongArray.java145 public final boolean compareAndSet(int i, long expectedValue, long newValue) { in compareAndSet() argument
146 return AA.compareAndSet(array, i, expectedValue, newValue); in compareAndSet()
167 public final boolean weakCompareAndSet(int i, long expectedValue, long newValue) { in weakCompareAndSet() argument
168 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSet()
182 public final boolean weakCompareAndSetPlain(int i, long expectedValue, long newValue) { in weakCompareAndSetPlain() argument
183 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSetPlain()
477 public final long compareAndExchange(int i, long expectedValue, long newValue) { in compareAndExchange() argument
478 return (long)AA.compareAndExchange(array, i, expectedValue, newValue); in compareAndExchange()
495 public final long compareAndExchangeAcquire(int i, long expectedValue, long newValue) { in compareAndExchangeAcquire() argument
496 return (long)AA.compareAndExchangeAcquire(array, i, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
DAtomicIntegerArray.java145 public final boolean compareAndSet(int i, int expectedValue, int newValue) { in compareAndSet() argument
146 return AA.compareAndSet(array, i, expectedValue, newValue); in compareAndSet()
167 public final boolean weakCompareAndSet(int i, int expectedValue, int newValue) { in weakCompareAndSet() argument
168 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSet()
182 public final boolean weakCompareAndSetPlain(int i, int expectedValue, int newValue) { in weakCompareAndSetPlain() argument
183 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSetPlain()
477 public final int compareAndExchange(int i, int expectedValue, int newValue) { in compareAndExchange() argument
478 return (int)AA.compareAndExchange(array, i, expectedValue, newValue); in compareAndExchange()
495 public final int compareAndExchangeAcquire(int i, int expectedValue, int newValue) { in compareAndExchangeAcquire() argument
496 return (int)AA.compareAndExchangeAcquire(array, i, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
DAtomicReferenceArray.java152 public final boolean compareAndSet(int i, E expectedValue, E newValue) { in compareAndSet() argument
153 return AA.compareAndSet(array, i, expectedValue, newValue); in compareAndSet()
174 public final boolean weakCompareAndSet(int i, E expectedValue, E newValue) { in weakCompareAndSet() argument
175 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSet()
189 public final boolean weakCompareAndSetPlain(int i, E expectedValue, E newValue) { in weakCompareAndSetPlain() argument
190 return AA.weakCompareAndSetPlain(array, i, expectedValue, newValue); in weakCompareAndSetPlain()
441 public final E compareAndExchange(int i, E expectedValue, E newValue) { in compareAndExchange() argument
442 return (E)AA.compareAndExchange(array, i, expectedValue, newValue); in compareAndExchange()
459 public final E compareAndExchangeAcquire(int i, E expectedValue, E newValue) { in compareAndExchangeAcquire() argument
460 return (E)AA.compareAndExchangeAcquire(array, i, expectedValue, newValue); in compareAndExchangeAcquire()
[all …]
/libcore/luni/src/test/java/libcore/libcore/io/
DMemoryMappedFileTest.java241 short expectedValue = (short) ((bytes[0] << 8) | bytes[1]); in testReadShort_bigEndian() local
242 assertReadShortSucceeds(iterator, expectedValue); in testReadShort_bigEndian()
248 expectedValue = (short) ((bytes[1] << 8) | bytes[2]); in testReadShort_bigEndian()
249 assertReadShortSucceeds(iterator, expectedValue); in testReadShort_bigEndian()
263 short expectedValue = (short) ((bytes[1] << 8) | bytes[0]); in testReadShort_littleEndian() local
264 assertReadShortSucceeds(iterator, expectedValue); in testReadShort_littleEndian()
270 expectedValue = (short) ((bytes[2] << 8) | bytes[1]); in testReadShort_littleEndian()
271 assertReadShortSucceeds(iterator, expectedValue); in testReadShort_littleEndian()
303 int expectedValue = (bytes[0] << 24) | (bytes[1] << 16) | (bytes[2] << 8) | bytes[3]; in testReadInt_bigEndian() local
304 assertReadIntSucceeds(iterator, expectedValue); in testReadInt_bigEndian()
[all …]
/libcore/ojluni/src/test/java/lang/Thread/
DITLConstructor.java70 int expectedValue = 1; in test() local
72 expectedValue = i + 1; in test()
75 Assert.assertEquals(x[i], expectedValue, "Got x[" + i + "] = " + x[i] in test()
76 + ", expected: " + expectedValue); in test()
/libcore/ojluni/src/test/java/time/test/java/time/format/
DTestFractionPrinterParser.java248 int expectedValue = fixParsedValue(maxWidth, value); in test_reverseParse() local
251 … assertParsed(parsed, NANO_OF_SECOND, value == 0 && minWidth == 0 ? null : (long) expectedValue); in test_reverseParse()
259 int expectedValue = fixParsedValue(maxWidth, value); in test_reverseParse_noDecimalPoint() local
260 … assertParsed(parsed, NANO_OF_SECOND, value == 0 && minWidth == 0 ? null : (long) expectedValue); in test_reverseParse_noDecimalPoint()
266 int expectedValue = fixParsedValue(maxWidth, value); in test_reverseParse_followedByNonDigit() local
269 … assertParsed(parsed, NANO_OF_SECOND, value == 0 && minWidth == 0 ? null : (long) expectedValue); in test_reverseParse_followedByNonDigit()
284 int expectedValue = fixParsedValue(maxWidth, value); in test_reverseParse_preceededByNonDigit() local
287 … assertParsed(parsed, NANO_OF_SECOND, value == 0 && minWidth == 0 ? null : (long) expectedValue); in test_reverseParse_preceededByNonDigit()
DTestTextParserWithLocale.java151 …andaloneText(Locale locale, TemporalField field, TextStyle style, int expectedValue, String input)… in test_parseStandaloneText() argument
154 assertEquals(formatter.parseUnresolved(input, pos).getLong(field), (long) expectedValue); in test_parseStandaloneText()
180 …public void test_parseLenientText(Locale locale, TemporalField field, int expectedValue, String in… in test_parseLenientText() argument
184 assertEquals(formatter.parseUnresolved(input, pos).getLong(field), (long) expectedValue); in test_parseLenientText()
DTestNumberParser.java167 …nStyle signStyle, int subsequentWidth, String text, int pos, int expectedPos, long expectedValue) { in test_parse_fresh() argument
180 assertEquals(parsed.getLong(DAY_OF_MONTH), expectedValue); in test_parse_fresh() local
187 …nStyle signStyle, int subsequentWidth, String text, int pos, int expectedPos, long expectedValue) { in test_parse_textField() argument
200 assertEquals(parsed.getLong(DAY_OF_WEEK), expectedValue); in test_parse_textField() local
/libcore/ojluni/src/test/java/time/tck/java/time/format/
DTCKLocalizedFieldParser.java105 …d test_parse_textField(String pattern, String text, int pos, int expectedPos, long expectedValue) { in test_parse_textField() argument
135 assertEquals(value, expectedValue, "Value incorrect for " + field); in test_parse_textField()
157 …rse_textLocalDate(String pattern, String text, int pos, int expectedPos, LocalDate expectedValue) { in test_parse_textLocalDate() argument
172 assertEquals(result, expectedValue, "LocalDate incorrect for " + pattern); in test_parse_textLocalDate()
194 …rse_WeekBasedYear(String pattern, String text, int pos, int expectedPos, LocalDate expectedValue) { in test_parse_WeekBasedYear() argument
209 …assertEquals(result, expectedValue, "LocalDate incorrect for " + pattern + ", weekDef: " + weekDef… in test_parse_WeekBasedYear()
268 LocalDate expectedValue = LocalDate.of(2012, 07, 20); in test_adjacentValuePatterns3() local
269 assertEquals(result, expectedValue, "LocalDate incorrect for " + pattern); in test_adjacentValuePatterns3()
DTCKDateTimeParseResolver.java835 … public void test_resolveClockHourOfAmPm(ResolverStyle style, long value, Integer expectedValue) { in test_resolveClockHourOfAmPm() argument
839 if (expectedValue != null) { in test_resolveClockHourOfAmPm()
845 assertEquals(accessor.getLong(HOUR_OF_AMPM), expectedValue.longValue()); in test_resolveClockHourOfAmPm()
879 … test_resolveAmPm(ResolverStyle style, long value, LocalTime expectedTime, Integer expectedValue) { in test_resolveAmPm() argument
883 if (expectedValue != null) { in test_resolveAmPm()
888 assertEquals(accessor.getLong(AMPM_OF_DAY), expectedValue.longValue()); in test_resolveAmPm()
/libcore/ojluni/src/test/java/text/AttributedString/
DAttributedStringTest.java214 …ttributedCharacterIterator iterator, int index, Attribute key, Object expectedValue) throws Except… in checkIteratorAttribute() argument
217 …if (!((expectedValue == null && value == null) || (expectedValue != null && expectedValue.equals(v… in checkIteratorAttribute()
218 …on(iterator, "iterator returns wrong attribute value - " + value + " instead of " + expectedValue); in checkIteratorAttribute()
221 …if (!((expectedValue == null && value == null) || (expectedValue != null && expectedValue.equals(v… in checkIteratorAttribute()
222 …rator, "iterator's map returns wrong attribute value - " + value + " instead of " + expectedValue); in checkIteratorAttribute()
/libcore/ojluni/src/test/java/io/Serializable/records/
DStreamRefTest.java216 static void assertExpectedIntValue(int expectedValue, byte[] bytes, int offset) in assertExpectedIntValue() argument
220 assertEquals(dis.readInt(), expectedValue); in assertExpectedIntValue() local
223 static void updateIntValue(int expectedValue, int newValue, byte[] bytes, int offset) in updateIntValue() argument
226 assertExpectedIntValue(expectedValue, bytes, offset); in updateIntValue()
/libcore/luni/src/test/java/libcore/java/util/zip/
DDeflaterTest.java92 int expectedValue = i < expected.length ? expected[i] : 0;
93 assertEquals(expectedValue, decompressed[i]);
/libcore/ojluni/src/main/java/sun/misc/
DUnsafe.java136 int expectedValue, int newValue); in compareAndSwapInt() argument
152 long expectedValue, long newValue); in compareAndSwapLong() argument
168 Object expectedValue, Object newValue); in compareAndSwapObject() argument
/libcore/ojluni/annotations/hiddenapi/sun/misc/
DUnsafe.java67 java.lang.Object obj, long offset, int expectedValue, int newValue); in compareAndSwapInt() argument
71 java.lang.Object obj, long offset, long expectedValue, long newValue); in compareAndSwapLong() argument
77 java.lang.Object expectedValue, in compareAndSwapObject() argument
/libcore/luni/src/test/java/libcore/java/util/
DAbstractListTest.java85 Integer expectedValue = list.get(2); in spliterator_modification_failFast() local
102 assertEquals(expectedValue, receivedValue.get()); in spliterator_modification_failFast()
DLinkedHashMapTest.java393 Object expectedValue = expected.getValue(); in check_eldest_comparibleWithIterationOrder() local
394 assertEntry(expectedKey, expectedValue, eldest(map)); in check_eldest_comparibleWithIterationOrder()
/libcore/ojluni/annotations/mmodule/sun/misc/
DUnsafe.annotated.java54 public native boolean compareAndSwapInt(java.lang.Object obj, long offset, int expectedValue, int n… in compareAndSwapInt() argument
57 public native boolean compareAndSwapLong(java.lang.Object obj, long offset, long expectedValue, lon… in compareAndSwapLong() argument
60 …pareAndSwapObject(java.lang.Object obj, long offset, java.lang.Object expectedValue, java.lang.Obj… in compareAndSwapObject() argument
/libcore/ojluni/src/main/java/jdk/internal/misc/
DUnsafe.java4256 int expectedValue, int newValue); in compareAndSwapInt() argument
4272 long expectedValue, long newValue); in compareAndSwapLong() argument
4288 Object expectedValue, Object newValue); in compareAndSwapObject() argument
/libcore/jsr166-tests/src/test/java/jsr166/
DJSR166TestCase.java1304 <T> void checkTimedGet(Future<T> f, T expectedValue, long timeoutMillis) {
1307 assertEquals(expectedValue, f.get(timeoutMillis, MILLISECONDS));
1313 <T> void checkTimedGet(Future<T> f, T expectedValue) {
1314 checkTimedGet(f, expectedValue, LONG_DELAY_MS);
/libcore/ojluni/src/test/java/util/concurrent/tck/
DJSR166TestCase.java1576 <T> void checkTimedGet(Future<T> f, T expectedValue, long timeoutMillis) {
1579 assertEquals(expectedValue, f.get(timeoutMillis, MILLISECONDS));
1585 <T> void checkTimedGet(Future<T> f, T expectedValue) {
1586 checkTimedGet(f, expectedValue, LONG_DELAY_MS);

12