/external/protobuf/java/util/src/main/java/com/google/protobuf/util/ |
D | TimeUtil.java | 105 if (timestamp.getNanos() < 0 || timestamp.getNanos() >= NANOS_PER_SECOND) { in toString() 108 if (timestamp.getNanos() != 0) { in toString() 110 result.append(formatNanos(timestamp.getNanos())); in toString() 200 int nanos = duration.getNanos(); in toString() 283 return timestamp.getSeconds() * MILLIS_PER_SECOND + timestamp.getNanos() in toMillis() 293 return duration.getSeconds() * MILLIS_PER_SECOND + duration.getNanos() in toMillis() 321 return timestamp.getSeconds() * MICROS_PER_SECOND + timestamp.getNanos() in toMicros() 331 return duration.getSeconds() * MICROS_PER_SECOND + duration.getNanos() in toMicros() 355 return timestamp.getSeconds() * NANOS_PER_SECOND + timestamp.getNanos(); in toNanos() 362 return duration.getSeconds() * NANOS_PER_SECOND + duration.getNanos(); in toNanos() [all …]
|
/external/opencensus-java/api/src/main/java/io/opencensus/common/ |
D | Timestamp.java | 106 public abstract int getNanos(); in getNanos() method in Timestamp 130 return plus(duration.getSeconds(), duration.getNanos()); in addDuration() 143 int durationNanos = getNanos() - timestamp.getNanos(); in subtractTimestamp() 168 return TimeUtils.compareLongs(getNanos(), otherTimestamp.getNanos()); in compareTo() 179 long nanoAdjustment = getNanos() + nanosToAdd; // safe int + NANOS_PER_SECOND in plus()
|
D | Duration.java | 99 return TimeUnit.SECONDS.toMillis(getSeconds()) + TimeUnit.NANOSECONDS.toMillis(getNanos()); in toMillis() 116 public abstract int getNanos(); in getNanos() method in Duration 132 return TimeUtils.compareLongs(getNanos(), otherDuration.getNanos()); in compareTo()
|
/external/junit/src/main/java/org/junit/rules/ |
D | Stopwatch.java | 99 return unit.convert(getNanos(), TimeUnit.NANOSECONDS); in runtime() 126 private long getNanos() { in getNanos() method in Stopwatch 158 Stopwatch.this.finished(getNanos(), description); in finished() 163 Stopwatch.this.succeeded(getNanos(), description); in succeeded() 168 Stopwatch.this.failed(getNanos(), e, description); in failed() 173 Stopwatch.this.skipped(getNanos(), e, description); in skipped()
|
/external/opencensus-java/testing/src/main/java/io/opencensus/testing/common/ |
D | TestClock.java | 91 return getNanos(currentTime); in nowNanos() 95 getNanos(time); in validateNanos() 100 private static long getNanos(Timestamp time) { in getNanos() method in TestClock 102 LongMath.checkedMultiply(time.getSeconds(), NUM_NANOS_PER_SECOND), time.getNanos()); in getNanos()
|
/external/protobuf/java/util/src/test/java/com/google/protobuf/util/ |
D | TimeUtilTest.java | 50 assertEquals(0, start.getNanos()); in testTimestampStringFormat() 52 assertEquals(999999999, end.getNanos()); in testTimestampStringFormat() 58 assertEquals(0, value.getNanos()); in testTimestampStringFormat() 64 assertEquals(999000000, value.getNanos()); in testTimestampStringFormat() 104 || result.getNanos() != values[index].getNanos()) { in run() 263 assertEquals(100000000, duration.getNanos()); in testDurationStringFormat() 265 assertEquals(100000, duration.getNanos()); in testDurationStringFormat() 267 assertEquals(100, duration.getNanos()); in testDurationStringFormat() 273 assertEquals(999999999, duration.getNanos()); in testDurationStringFormat() 276 assertEquals(-999999999, duration.getNanos()); in testDurationStringFormat()
|
/external/apache-harmony/sql/src/test/java/org/apache/harmony/sql/tests/java/sql/ |
D | TimestampTest.java | 206 assertEquals(NANOS_ARRAY[i], theTimestamp.getNanos()); in testSetTimelong() 350 assertEquals(theReturnNanos[i], theReturn.getNanos()); in testValueOfString1() 431 assertEquals(NANOS_ARRAY[i], theTimestamp.getNanos()); in testGetNanos() 448 assertEquals(NANOS_ARRAY2[i], theTimestamp.getNanos()); in testSetNanosint() 457 int originalNanos = theTimestamp.getNanos(); in testSetNanosint() 465 assertEquals(originalNanos, theTimestamp.getNanos()); in testSetNanosint() 545 theTest.setNanos(theTest.getNanos() + 1); in testBeforeTimestamp() 576 theTimestamp.setNanos(theTimestamp.getNanos() + 1); in testAfterTimestamp()
|
/external/opencensus-java/api/src/test/java/io/opencensus/common/ |
D | DurationTest.java | 35 assertThat(Duration.create(24, 42).getNanos()).isEqualTo(42); in testDurationCreate() 37 assertThat(Duration.create(-24, -42).getNanos()).isEqualTo(-42); in testDurationCreate() 39 assertThat(Duration.create(315576000000L, 999999999).getNanos()).isEqualTo(999999999); in testDurationCreate() 41 assertThat(Duration.create(-315576000000L, -999999999).getNanos()).isEqualTo(-999999999); in testDurationCreate()
|
D | TimestampTest.java | 35 assertThat(Timestamp.create(24, 42).getNanos()).isEqualTo(42); in timestampCreate() 37 assertThat(Timestamp.create(-24, 42).getNanos()).isEqualTo(42); in timestampCreate() 39 assertThat(Timestamp.create(315576000000L, 999999999).getNanos()).isEqualTo(999999999); in timestampCreate() 41 assertThat(Timestamp.create(-315576000000L, 999999999).getNanos()).isEqualTo(999999999); in timestampCreate()
|
/external/opencensus-java/exporters/trace/ocagent/src/test/java/io/opencensus/exporter/trace/ocagent/ |
D | TraceProtoUtilsTest.java | 172 .setNanos(eventTimestamp1.getNanos()) in toSpanProto() 185 .setNanos(eventTimestamp3.getNanos()) in toSpanProto() 198 .setNanos(eventTimestamp2.getNanos()) in toSpanProto() 210 .setNanos(eventTimestamp1.getNanos()) in toSpanProto() 235 .setNanos(startTimestamp.getNanos()) in toSpanProto() 240 .setNanos(endTimestamp.getNanos()) in toSpanProto()
|
/external/opencensus-java/exporters/trace/stackdriver/src/test/java/io/opencensus/exporter/trace/stackdriver/ |
D | StackdriverV2ExporterHandlerProtoTest.java | 214 .setNanos(eventTimestamp1.getNanos()) in generateSpan() 228 .setNanos(eventTimestamp3.getNanos()) in generateSpan() 241 .setNanos(eventTimestamp2.getNanos()) in generateSpan() 253 .setNanos(eventTimestamp1.getNanos()) in generateSpan() 278 .setNanos(startTimestamp.getNanos()) in generateSpan() 283 .setNanos(endTimestamp.getNanos()) in generateSpan()
|
/external/opencensus-java/exporters/trace/instana/src/main/java/io/opencensus/exporter/trace/instana/ |
D | InstanaExporterHandler.java | 106 return SECONDS.toMillis(timestamp.getSeconds()) + NANOSECONDS.toMillis(timestamp.getNanos()); in toMillis() 111 return SECONDS.toMillis(duration.getSeconds()) + NANOSECONDS.toMillis(duration.getNanos()); in toMillis()
|
/external/opencensus-java/contrib/zpages/src/main/java/io/opencensus/contrib/zpages/ |
D | TracezZPageHandler.java | 309 long microsField = TimeUnit.NANOSECONDS.toMicros(span.getStartTimestamp().getNanos()); in emitSingleSpan() 370 + TimeUnit.NANOSECONDS.toMillis(event.getTimestamp().getNanos())); in emitSingleSpan() 371 microsField = TimeUnit.NANOSECONDS.toMicros(event.getTimestamp().getNanos()); in emitSingleSpan() 572 return TimeUnit.SECONDS.toNanos(duration.getSeconds()) + duration.getNanos(); in durationToNanos()
|
D | RpczZPageHandler.java | 456 return duration.getNanos() / NANOS_PER_SECOND + duration.getSeconds(); in toDoubleSeconds()
|
D | StatszZPageHandler.java | 367 + timestamp.getNanos() / NANOS_PER_MILLISECOND)); in toDate()
|
/external/opencensus-java/exporters/trace/zipkin/src/main/java/io/opencensus/exporter/trace/zipkin/ |
D | ZipkinExporterHandler.java | 170 return SECONDS.toMicros(timestamp.getSeconds()) + NANOSECONDS.toMicros(timestamp.getNanos()); in toEpochMicros()
|
/external/opencensus-java/api/src/main/java/io/opencensus/stats/ |
D | ViewData.java | 152 .addDuration(Duration.create(-duration.getSeconds(), -duration.getNanos())), in create()
|
/external/opencensus-java/exporters/trace/jaeger/src/main/java/io/opencensus/exporter/trace/jaeger/ |
D | JaegerExporterHandler.java | 271 : SECONDS.toMicros(timestamp.getSeconds()) + NANOSECONDS.toMicros(timestamp.getNanos()); in timestampToMicros()
|
/external/opencensus-java/impl_core/src/main/java/io/opencensus/implcore/stats/ |
D | MutableViewData.java | 429 return timestamp.addDuration(Duration.create(-duration.getSeconds(), -duration.getNanos())); in subtractDuration()
|
/external/opencensus-java/exporters/trace/ocagent/src/main/java/io/opencensus/exporter/trace/ocagent/ |
D | TraceProtoUtils.java | 284 .setNanos(timestamp.getNanos()) in toTimestampProto()
|
/external/opencensus-java/exporters/stats/stackdriver/src/main/java/io/opencensus/exporter/stats/stackdriver/ |
D | StackdriverExportUtils.java | 450 .setNanos(censusTimestamp.getNanos())
|
/external/opencensus-java/exporters/trace/stackdriver/src/main/java/io/opencensus/exporter/trace/stackdriver/ |
D | StackdriverV2ExporterHandler.java | 424 .setNanos(timestamp.getNanos()) in toTimestampProto()
|