/libcore/ojluni/src/test/java/time/test/java/time/ |
D | TestZoneId.java | 120 assertEquals(test.getRules().getOffset(Instant.ofEpochSecond(0L)), ZoneOffset.UTC); in test_constant_UTC() 165 …assertEquals(test.getRules().getOffset(createInstant(2008, 1, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 166 …assertEquals(test.getRules().getOffset(createInstant(2008, 2, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 167 …assertEquals(test.getRules().getOffset(createInstant(2008, 3, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 168 …assertEquals(test.getRules().getOffset(createInstant(2008, 4, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 169 …assertEquals(test.getRules().getOffset(createInstant(2008, 5, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 170 …assertEquals(test.getRules().getOffset(createInstant(2008, 6, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 171 …assertEquals(test.getRules().getOffset(createInstant(2008, 7, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 172 …assertEquals(test.getRules().getOffset(createInstant(2008, 8, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() 173 …assertEquals(test.getRules().getOffset(createInstant(2008, 9, 1, ZoneOffset.UTC)), ZoneOffset.ofHo… in test_London_getOffset() [all …]
|
D | TestOffsetDateTime_instants.java | 162 assertEquals(test.getOffset(), OFFSET_MIN); in factory_ofInstant_minWithMinOffset() 178 assertEquals(test.getOffset(), OFFSET_MAX); in factory_ofInstant_minWithMaxOffset() 194 assertEquals(test.getOffset(), OFFSET_MIN); in factory_ofInstant_maxWithMinOffset() 210 assertEquals(test.getOffset(), OFFSET_MAX); in factory_ofInstant_maxWithMaxOffset()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/text/ |
D | CollationElementIteratorTest.java | 49 int offset = iterator.getOffset(); in testGetOffset() 54 offset = iterator.getOffset(); in testGetOffset() 70 int offset = iterator.getOffset(); in testNext() 81 assertEquals(0, iterator.getOffset()); in testNext() 97 int offset = iterator.getOffset(); in testPrevious() 108 assertEquals(0, iterator.getOffset()); in testPrevious() 122 int offset = iterator.getOffset(); in testReset() 126 assertEquals(0, iterator.getOffset()); in testReset() 189 assertEquals(0, iterator.getOffset()); in testSetOffset() 191 assertEquals(0, iterator.getOffset()); in testSetOffset() [all …]
|
D | RuleBasedCollatorTest.java | 107 int offset = iterator.getOffset(); in testGetCollationElementIteratorString() 112 offset = iterator.getOffset(); in testGetCollationElementIteratorString() 124 int offset = iterator.getOffset(); in testGetCollationElementIteratorString() 129 offset = iterator.getOffset(); in testGetCollationElementIteratorString() 150 int offset = iterator.getOffset(); in testGetCollationElementIteratorCharacterIterator() 155 offset = iterator.getOffset(); in testGetCollationElementIteratorCharacterIterator() 169 int offset = iterator.getOffset(); in testGetCollationElementIteratorCharacterIterator() 174 offset = iterator.getOffset(); in testGetCollationElementIteratorCharacterIterator()
|
/libcore/ojluni/src/test/java/time/tck/java/time/zone/ |
D | TCKZoneRules.java | 125 assertEquals(test.getOffset(instant), offset); in test_London_preTimeZones() 134 assertEquals(test.getOffset(createInstant(2008, 1, 1, ZoneOffset.UTC)), OFFSET_ZERO); in test_London_getOffset() 135 assertEquals(test.getOffset(createInstant(2008, 2, 1, ZoneOffset.UTC)), OFFSET_ZERO); in test_London_getOffset() 136 assertEquals(test.getOffset(createInstant(2008, 3, 1, ZoneOffset.UTC)), OFFSET_ZERO); in test_London_getOffset() 137 assertEquals(test.getOffset(createInstant(2008, 4, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() 138 assertEquals(test.getOffset(createInstant(2008, 5, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() 139 assertEquals(test.getOffset(createInstant(2008, 6, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() 140 assertEquals(test.getOffset(createInstant(2008, 7, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() 141 assertEquals(test.getOffset(createInstant(2008, 8, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() 142 assertEquals(test.getOffset(createInstant(2008, 9, 1, ZoneOffset.UTC)), OFFSET_PONE); in test_London_getOffset() [all …]
|
D | TCKFixedZoneRules.java | 113 assertEquals(test.getOffset(INSTANT), expectedOffset); in test_getOffset_Instant() 114 assertEquals(test.getOffset((Instant) null), expectedOffset); in test_getOffset_Instant() 119 assertEquals(test.getOffset(LDT), expectedOffset); in test_getOffset_LocalDateTime() 120 assertEquals(test.getOffset((LocalDateTime) null), expectedOffset); in test_getOffset_LocalDateTime()
|
/libcore/luni/src/test/java/libcore/java/io/ |
D | OldObjectStreamFieldTest.java | 141 .getOffset() != osfArray[1].getOffset()); in test_getOffset() 145 expectedOffsets[i], osfArray[i].getOffset()); in test_getOffset() 153 assertEquals("Test 1: Unexpected offset value.", 42, f.getOffset()); in test_setOffsetI() 155 assertEquals("Test 2: Unexpected offset value.", 2008, f.getOffset()); in test_setOffsetI()
|
/libcore/luni/src/test/java/libcore/java/util/ |
D | TimeZoneTest.java | 67 assertEquals(7200000L, tz.getOffset(firstTransitionTimeMillis)); in testPreHistoricInDaylightTime() 71 assertEquals(3600000L, tz.getOffset(beforeFirstTransitionTimeMillis)); in testPreHistoricInDaylightTime() 89 assertEquals(-28800000, tz.getOffset(date.getTime())); in testPreHistoricInDaylightTime_old() 95 assertEquals(-28800000, tz.getOffset(date.getTime())); in testPreHistoricInDaylightTime_old() 134 assertEquals(expectedOffsetSeconds, tz.getOffset(epochMillis) / 1000); in assertNonDaylightOffset() 155 int currentOffset = tz.getOffset(new Date(0).getTime()); in testMinimalTransitionZones() 156 assertEquals(currentOffset, tz.getOffset(new Date(Integer.MIN_VALUE).getTime())); in testMinimalTransitionZones() 157 assertEquals(currentOffset, tz.getOffset(new Date(Integer.MAX_VALUE).getTime())); in testMinimalTransitionZones() 165 long offset = timeZone.getOffset(time); in testHelsinkiOverflow() 367 int actualOffset = tz.getOffset(lowerTimeMillis); in testOverflowing32BitUnixDates() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/ |
D | ObjectStreamFieldTest.java | 105 .getOffset() != osfArray[1].getOffset()); in test_getOffset() 107 0, osfArray[0].getOffset()); in test_getOffset() 109 .getOffset()); in test_getOffset() 111 osfArray[2].getOffset()); in test_getOffset() 221 assertEquals(0, objectStreamClass.getField("d").getOffset()); in test_isUnshared() 222 assertEquals(1, objectStreamClass.getField("i").getOffset()); in test_isUnshared() 223 assertEquals(2, objectStreamClass.getField("s").getOffset()); in test_isUnshared()
|
/libcore/luni/src/main/java/libcore/util/ |
D | ZoneInfo.java | 102 public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { in getOffset() method in ZoneInfo 103 return mDelegate.getOffset(era, year, month, day, dayOfWeek, millis); in getOffset() 107 public int getOffset(long when) { in getOffset() method in ZoneInfo 108 return mDelegate.getOffset(when); in getOffset()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
D | TimeZoneTest.java | 82 -(5 * ONE_HOUR), st1.getOffset(time1)); in test_getOffset_long() 88 -(5 * ONE_HOUR), st1.getOffset(time2)); in test_getOffset_long() 93 -(5 * ONE_HOUR), tz1.getOffset(time1)); in test_getOffset_long() 95 -(4 * ONE_HOUR), tz1.getOffset(time2)); in test_getOffset_long() 100 (3 * ONE_HOUR), tz1.getOffset(time1)); in test_getOffset_long() 102 (3 * ONE_HOUR), tz1.getOffset(time2)); in test_getOffset_long()
|
D | SimpleTimeZoneTest.java | 300 assertTrue("Incorrect offset returned", st1.getOffset( in test_getOffsetIIIIII() 306 .getOffset(GregorianCalendar.AD, 1998, Calendar.JUNE, 11, in test_getOffsetIIIIII() 313 assertEquals(fourHours, st1.getOffset(1, 2099, 01, 1, 5, 0)); in test_getOffsetIIIIII() 316 st1.getOffset(-1, 2099, 01, 1, 5, 0); in test_getOffsetIIIIII() 323 st1.getOffset(1, 2099, 15, 1, 5, 0); in test_getOffsetIIIIII() 330 st1.getOffset(1, 2099, 01, 100, 5, 0); in test_getOffsetIIIIII() 337 st1.getOffset(1, 2099, 01, 1, 50, 0); in test_getOffsetIIIIII() 344 st1.getOffset(1, 2099, 01, 1, 5, -10); in test_getOffsetIIIIII() 806 assertTrue("Incorrect offset returned", st1.getOffset(cal.getTimeInMillis()) == in test_getOffsetJ() 812 .getOffset(cal.getTimeInMillis())); in test_getOffsetJ() [all …]
|
/libcore/ojluni/src/main/java/java/text/ |
D | CollationElementIterator.java | 245 public int getOffset() in getOffset() method in CollationElementIterator 248 return icuIterator.getOffset(); in getOffset()
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | ChronoZonedDateTimeImpl.java | 172 ZoneOffset offset = rules.getOffset(instant); in ofInstant() 226 public ZoneOffset getOffset() { in getOffset() method in ChronoZonedDateTimeImpl 247 if (offset.equals(getOffset()) == false) { in withLaterOffsetAtOverlap() 378 …return toLocalDateTime().hashCode() ^ getOffset().hashCode() ^ Integer.rotateLeft(getZone().hashCo… in hashCode() 383 String str = toLocalDateTime().toString() + getOffset().toString(); in toString() 384 if (getOffset() != getZone()) { in toString()
|
D | ChronoZonedDateTime.java | 196 return getOffset().getTotalSeconds(); in get() 208 case OFFSET_SECONDS: return getOffset().getTotalSeconds(); in getLong() 268 ZoneOffset getOffset(); in getOffset() method 487 return (R) getOffset(); in query() 548 secs -= getOffset().getTotalSeconds(); in toEpochSecond()
|
/libcore/ojluni/src/test/java/time/test/java/time/zone/ |
D | TestFixedZoneRules.java | 89 assertEquals(test.getOffset((Instant) null), OFFSET_PONE); in test_data_nullInput() 90 assertEquals(test.getOffset((LocalDateTime) null), OFFSET_PONE); in test_data_nullInput()
|
/libcore/ojluni/src/main/java/java/time/ |
D | OffsetDateTime.java | 168 if (datetime1.getOffset().equals(datetime2.getOffset())) { in compareInstant() 241 return ofInstant(now, clock.getZone().getRules().getOffset(now)); in now() 321 ZoneOffset offset = rules.getOffset(instant); in ofInstant() 596 return getOffset().getTotalSeconds(); in get() 631 case OFFSET_SECONDS: return getOffset().getTotalSeconds(); in getLong() 646 public ZoneOffset getOffset() { in getOffset() method in OffsetDateTime 1540 return (R) getOffset(); in query() 1592 .with(OFFSET_SECONDS, getOffset().getTotalSeconds()); in adjustInto()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/net/ |
D | DatagramPacketTest.java | 61 assertEquals("Wrong offset", 2, dp.getOffset()); in test_Constructor$BII() 74 assertEquals("Wrong offset", 2, dp.getOffset()); in test_Constructor$BIILjava_net_InetAddressI() 122 assertEquals("Incorrect length returned", 3, dp.getOffset()); in test_getOffset() 276 assertEquals("Offset not set correctly", 1, thePacket.getOffset()); in test_Constructor$BIILjava_net_SocketAddress()
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
D | TCKZoneOffset.java | 488 assertEquals(offset.getRules().getOffset((Instant) null), offset); in test_getRules() 497 assertEquals(offset.getRules().getOffset((LocalDateTime) null), offset); in test_getRules() 595 assertEquals(zonedDateTime_target.getOffset(), zonedDateTime_result.getOffset()); 599 assertEquals(base, offsetDateTime_result.getOffset()); 609 assertEquals(base, offsetDateTime_result.getOffset()); 614 assertEquals(zonedDateTime_target.getOffset(), zonedDateTime_result.getOffset());
|
D | TCKZonedDateTime.java | 287 assertEquals(test.getOffset(), ZoneOffset.UTC); 316 assertEquals(test.getOffset(), ZoneOffset.UTC); 332 assertEquals(test.getOffset(), offset); 348 assertEquals(test.getOffset(), offset); 511 assertEquals(test.getOffset(), OFFSET_MIN); 528 assertEquals(test.getOffset(), OFFSET_MAX); 545 assertEquals(test.getOffset(), OFFSET_MIN); 562 assertEquals(test.getOffset(), OFFSET_MAX); 835 ZoneOffset offset = zone.getRules().getOffset(localDateTime); 986 assertEquals(TEST_DATE_TIME.query(TemporalQueries.offset()), TEST_DATE_TIME.getOffset()); [all …]
|
/libcore/ojluni/src/main/java/sun/util/calendar/ |
D | AbstractCalendar.java | 133 zoneOffset = zi.getOffset(millis); in getCalendarDate() 201 zoneOffset = zi.getOffset(ms - zi.getRawOffset()); in getTime() 213 zoneOffset = zi.getOffset(ms - zi.getRawOffset()); in getTime()
|
/libcore/support/src/test/java/tests/support/ |
D | Support_TimeZone.java | 74 public int getOffset(int p1, int p2, int p3, int p4, int p5, int p6) { in getOffset() method in Support_TimeZone
|
/libcore/ojluni/src/main/java/java/util/ |
D | SimpleTimeZone.java | 538 public int getOffset(long date) { in getOffset() method in SimpleTimeZone 567 offset = getOffset(cal, cdate, year, date); in getOffsets() 604 public int getOffset(int era, int year, int month, int day, int dayOfWeek, in getOffset() method in SimpleTimeZone 669 return getOffset(cal, cdate, y, time); in getOffset() 672 private int getOffset(BaseCalendar cal, BaseCalendar.Date cdate, int year, long time) { in getOffset() method in SimpleTimeZone 862 return (getOffset(date.getTime()) != rawOffset); in inDaylightTime()
|
/libcore/ojluni/src/main/java/sun/nio/ch/ |
D | DatagramSocketAdaptor.java | 146 p.getOffset(), in send() 214 p.getOffset(), in receive() 218 p.setLength(bb.position() - p.getOffset()); in receive()
|
/libcore/luni/src/test/java/libcore/java/time/ |
D | ZonedDateTimeTest.java | 107 assertEquals("offset" + message, expectedOffset, zonedDateTime.getOffset()); in checkOfInstant() 176 assertEquals("offset" + message, expectedOffset, zonedDateTime.getOffset()); in checkOfLocal()
|