- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 62 for nanotime1 (0.15 sec)
-
mockwebserver-deprecated/src/test/java/okhttp3/mockwebserver/MockWebServerTest.kt
) val startNanos = System.nanoTime() val connection = server.url("/").toUrl().openConnection() connection.setDoOutput(true) connection.getOutputStream().write("ABCDEF".toByteArray(StandardCharsets.UTF_8)) val inputStream = connection.getInputStream() assertThat(inputStream.read()).isEqualTo(-1) val elapsedNanos = System.nanoTime() - startNanos
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 21.9K bytes - Viewed (0) -
mockwebserver/src/test/java/mockwebserver3/MockWebServerTest.kt
.build(), ) val startNanos = System.nanoTime() val connection = server.url("/").toUrl().openConnection() connection.doOutput = true connection.getOutputStream().write("ABCDEF".toByteArray(UTF_8)) val inputStream = connection.getInputStream() assertThat(inputStream.read()).isEqualTo(-1) val elapsedNanos = System.nanoTime() - startNanos
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 23.5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
if (profileTests) runTestProfiled(); else super.runTest(); } protected void runTestProfiled() throws Throwable { long t0 = System.nanoTime(); try { super.runTest(); } finally { long elapsedMillis = (System.nanoTime() - t0) / (1000L * 1000L); if (elapsedMillis >= profileThreshold) System.out.printf("%n%s: %d%n", toString(), elapsedMillis); } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 37.9K bytes - Viewed (0) -
okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/LoggingEventListener.kt
class LoggingEventListener private constructor( private val logger: HttpLoggingInterceptor.Logger, ) : EventListener() { private var startNs: Long = 0 override fun callStart(call: Call) { startNs = System.nanoTime() logWithTime("callStart: ${call.request()}") } override fun proxySelectStart( call: Call, url: HttpUrl, ) { logWithTime("proxySelectStart: $url") }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Apr 01 11:07:32 UTC 2024 - 5.4K bytes - Viewed (0) -
docs/features/events.md
return new PrintingEventListener(callId, System.nanoTime()); } }; final long callId; final long callStartNanos; public PrintingEventListener(long callId, long callStartNanos) { this.callId = callId; this.callStartNanos = callStartNanos; } private void printEvent(String name) { long elapsedNanos = System.nanoTime() - callStartNanos;
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 06 02:19:09 UTC 2022 - 7.7K bytes - Viewed (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/ClientRuleEventListener.kt
) : EventListener(), EventListener.Factory { private var startNs: Long? = null override fun create(call: Call): EventListener = this override fun callStart(call: Call) { startNs = System.nanoTime() logWithTime("callStart: ${call.request()}") delegate.callStart(call) } override fun proxySelectStart( call: Call, url: HttpUrl, ) { logWithTime("proxySelectStart: $url")
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 6K bytes - Viewed (0) -
okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/HttpLoggingInterceptor.kt
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 06 09:14:38 UTC 2024 - 11.2K bytes - Viewed (0) -
docs/features/interceptors.md
Request request = chain.request(); long t1 = System.nanoTime(); logger.info(String.format("Sending request %s on %s%n%s", request.url(), chain.connection(), request.headers())); Response response = chain.proceed(request); long t2 = System.nanoTime(); logger.info(String.format("Received response for %s in %.1fms%n%s",
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 06 02:19:09 UTC 2022 - 8.1K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/PrintEvents.java
return new PrintingEventListener(callId, System.nanoTime()); } }; final long callId; final long callStartNanos; PrintingEventListener(long callId, long callStartNanos) { this.callId = callId; this.callStartNanos = callStartNanos; } private void printEvent(String name) { long elapsedNanos = System.nanoTime() - callStartNanos;
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 16 23:20:49 UTC 2020 - 6.1K bytes - Viewed (0) -
guava/src/com/google/common/collect/Queues.java
Preconditions.checkNotNull(buffer); /* * This code performs one System.nanoTime() more than necessary, and in return, the time to * execute Queue#drainTo is not added *on top* of waiting for the timeout (which could make * the timeout arbitrarily inaccurate, given a queue that is slow to drain). */ long deadline = System.nanoTime() + unit.toNanos(timeout); int added = 0; while (added < numElements) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 26 14:11:14 UTC 2024 - 18.2K bytes - Viewed (0)