- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for readUtf8LineStrict (0.08 sec)
-
okhttp-sse/src/main/kotlin/okhttp3/sse/internal/ServerSentEventReader.kt
} in 8..9 -> { id = source.readUtf8LineStrict().takeIf { it.isNotEmpty() } } in 10..12 -> { id = null // 'id' on a line of its own. } in 13..14 -> { type = source.readUtf8LineStrict().takeIf { it.isNotEmpty() } } in 15..17 -> {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 11:47:47 UTC 2025 - 4.3K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/Cache.kt
val urlLine = source.readUtf8LineStrict() // Choice here is between failing with a correct RuntimeException // or mostly silently with an IOException url = urlLine.toHttpUrlOrNull() ?: throw IOException("Cache corruption for $urlLine").also { Platform.get().log("cache corruption", WARN, it) } requestMethod = source.readUtf8LineStrict()
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 26.9K bytes - Viewed (0) -
okhttp/src/commonTest/kotlin/okhttp3/internal/publicsuffix/PublicSuffixDatabaseTest.kt
val buffer = Buffer() FileSystem.SYSTEM.read(pathForTests) { val length = readInt() buffer.write(this, length.toLong()) } while (!buffer.exhausted()) { var publicSuffix = buffer.readUtf8LineStrict() if (publicSuffix.contains("*")) { // A wildcard rule, let's replace the wildcard with a value. publicSuffix = publicSuffix.replace("\\*".toRegex(), "square") }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Tue May 27 22:00:49 UTC 2025 - 8.5K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/cache/DiskLruCache.kt
@Throws(IOException::class) private fun readJournal() { fileSystem.read(journalFile) { val magic = readUtf8LineStrict() val version = readUtf8LineStrict() val appVersionString = readUtf8LineStrict() val valueCountString = readUtf8LineStrict() val blank = readUtf8LineStrict() if (MAGIC != magic || VERSION_1 != version || appVersion.toString() != appVersionString ||
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed May 28 23:28:25 UTC 2025 - 34.7K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http1/HeadersReader.kt
val source: BufferedSource, ) { private var headerLimit = HEADER_LIMIT.toLong() /** Read a single line counted against the header size limit. */ fun readLine(): String { val line = source.readUtf8LineStrict(headerLimit) headerLimit -= line.length.toLong() return line } /** Reads headers or trailers. */ fun readHeaders(): Headers { val result = Headers.Builder() while (true) {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 1.4K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/publicsuffix/PublicSuffixListGenerator.kt
var totalRuleBytes = 0 var totalExceptionRuleBytes = 0 fileSystem.source(publicSuffixListDotDat).buffer().use { source -> while (!source.exhausted()) { var rule: ByteString = source.readUtf8LineStrict().toRule() ?: continue if (rule.startsWith(EXCEPTION_RULE_MARKER)) { rule = rule.substring(1) // We use '\n' for end of value. totalExceptionRuleBytes += rule.size + 1
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Aug 06 05:33:11 UTC 2025 - 6.1K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt
try { val requestLineString = socket.source.readUtf8LineStrict() if (requestLineString.isEmpty()) { throw ProtocolException("no request because the stream is exhausted") } request = decodeRequestLine(requestLineString) while (true) { val header = socket.source.readUtf8LineStrict() if (header.isEmpty()) { break }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 02 20:36:00 UTC 2025 - 40.3K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http1/Http1ExchangeCodec.kt
// Read the suffix of the previous chunk. if (bytesRemainingInChunk != NO_CHUNK_YET) { socket.source.readUtf8LineStrict() } try { bytesRemainingInChunk = socket.source.readHexadecimalUnsignedLong() val extensions = socket.source.readUtf8LineStrict().trim() if (bytesRemainingInChunk < 0L || extensions.isNotEmpty() && !extensions.startsWith(";")) {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Thu Jul 31 04:18:40 UTC 2025 - 17.5K bytes - Viewed (7)