- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 173 for sources (3.43 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/cache2/Relay.kt
import okio.ByteString import okio.ByteString.Companion.encodeUtf8 import okio.Source import okio.Timeout /** * Replicates a single upstream source into multiple downstream sources. Each downstream source * returns the same bytes as the upstream source. Downstream sources may read data either as it * is returned by upstream, or after the upstream source has been exhausted. *
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 11.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/cache2/RelayTest.kt
val source2 = relay.newSource()!!.buffer() assertThat(source1.readUtf8(5)).isEqualTo("abcde") assertThat(source2.readUtf8(5)).isEqualTo("abcde") assertThat(source2.readUtf8(5)).isEqualTo("fghij") assertThat(source1.readUtf8(5)).isEqualTo("fghij") assertThat(source1.exhausted()).isTrue() assertThat(source2.exhausted()).isTrue() source1.close() source2.close() assertThat(relay.isClosed).isTrue()
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 11 22:09:35 GMT 2024 - 8.1K bytes - Viewed (0) -
okhttp/build.gradle.kts
} val generateIdnaMappingTable by tasks.creating(JavaExec::class.java) { outputs.dir("$buildDir/generated/sources/idnaMappingTable") mainClass.set("okhttp3.internal.idn.GenerateIdnaMappingTableCode") args("$buildDir/generated/sources/idnaMappingTable") classpath = generateIdnaMappingTableConfiguration } kotlin { sourceSets { getByName("main") {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Jan 04 05:32:07 GMT 2024 - 5.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt
/** Returns the unbuffered stream with the value for [index]. */ fun getSource(index: Int): Source = sources[index] /** Returns the byte length of the value for [index]. */ fun getLength(index: Int): Long = lengths[index] override fun close() { for (source in sources) { source.closeQuietly() } } } /** Edits the values for an entry. */
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 34.7K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/publicsuffix/PublicSuffixListGenerator.kt
val client: OkHttpClient = OkHttpClient(), ) { private val resources = projectRoot / "okhttp/src/main/resources/okhttp3/internal/publicsuffix" private val testResources = projectRoot / "okhttp/src/test/resources/okhttp3/internal/publicsuffix" private val publicSuffixListDotDat = testResources / "public_suffix_list.dat" private val outputFile = resources / PUBLIC_SUFFIX_RESOURCE
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 18 01:24:38 GMT 2024 - 6K bytes - Viewed (0) -
okhttp-sse/src/main/kotlin/okhttp3/sse/EventSource.kt
fun request(): Request /** * Immediately and violently release resources held by this event source. This does nothing if * the event source has already been closed or canceled. */ fun cancel() fun interface Factory { /** * Creates a new event source and immediately returns it. Creating an event source initiates an
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 1.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/SocksProxy.kt
toAddress: InetAddress, source: BufferedSource, sink: BufferedSink, ) { executor.execute { val name = "SocksProxy $fromAddress to $toAddress" threadName(name) { val buffer = Buffer() try { sink.use { source.use { while (true) { val byteCount = source.read(buffer, 8192L)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 11 22:09:35 GMT 2024 - 7.7K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/platform/Platform.kt
/* * Copyright (C) 2012 Square, Inc. * Copyright (C) 2012 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 9.8K bytes - Viewed (1) -
okhttp/src/test/java/okhttp3/ResponseBodyJvmTest.kt
@Test fun sourceSeesBom() { val body = "efbbbf68656c6c6f".decodeHex().toResponseBody() val source = body.source() assertThat(source.readByte() and 0xff).isEqualTo(0xef) assertThat(source.readByte() and 0xff).isEqualTo(0xbb) assertThat(source.readByte() and 0xff).isEqualTo(0xbf) assertThat(source.readUtf8()).isEqualTo("hello") } @Test fun bytesEmpty() { val body = body("")
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 13K bytes - Viewed (0) -
okhttp-brotli/src/main/kotlin/okhttp3/brotli/internal/DecompressionBombChecker.kt
import okio.ForwardingSource import okio.IOException import okio.Source /** Fails decompression if the ratio is too high. */ internal class DecompressionBombChecker( private val maxRatio: Long, ) { private var inputByteCount = 0L private var outputByteCount = 0L fun wrapInput(source: Source): Source { return object : ForwardingSource(source) { override fun read( sink: Buffer,
Plain Text - Registered: Fri Mar 29 11:42:11 GMT 2024 - Last Modified: Mon Jan 29 22:50:20 GMT 2024 - 1.8K bytes - Viewed (0)