Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for uppercase (0.21 sec)

  1. okhttp/src/test/java/okhttp3/InterceptorTest.kt

            original!!.writeTo(bufferedSink)
            bufferedSink.emit()
          }
        }
      }
    
      private fun uppercase(original: BufferedSink): Sink {
        return object : ForwardingSink(original) {
          override fun write(
            source: Buffer,
            byteCount: Long,
          ) {
            original.writeUtf8(source.readUtf8(byteCount).uppercase())
          }
        }
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Jan 14 10:20:09 GMT 2024
    - 27.8K bytes
    - Viewed (0)
  2. okhttp-testing-support/src/main/kotlin/okhttp3/UppercaseRequestInterceptor.kt

    import okio.buffer
    
    /** Rewrites the request body sent to the server to be all uppercase.  */
    class UppercaseRequestInterceptor : Interceptor {
      @Throws(IOException::class)
      override fun intercept(chain: Chain): Response {
        return chain.proceed(uppercaseRequest(chain.request()))
      }
    
      /** Returns a request that transforms `request` to be all uppercase.  */
      private fun uppercaseRequest(request: Request): Request {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.9K bytes
    - Viewed (0)
  3. okhttp-testing-support/src/main/kotlin/okhttp3/UppercaseResponseInterceptor.kt

    import java.io.IOException
    import okhttp3.Interceptor.Chain
    import okio.Buffer
    import okio.BufferedSource
    import okio.ForwardingSource
    import okio.buffer
    
    /** Rewrites the response body returned from the server to be all uppercase.  */
    class UppercaseResponseInterceptor : Interceptor {
      @Throws(IOException::class)
      override fun intercept(chain: Chain): Response {
        return uppercaseResponse(chain.proceed(chain.request()))
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.8K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/ws/WebSocketExtensionsTest.kt

      fun absentValue() {
        assertThat(parse("permessage-deflate; server_max_window_bits")).isEqualTo(
          WebSocketExtensions(perMessageDeflate = true, unknownValues = true),
        )
      }
    
      @Test
      fun uppercase() {
        assertThat(parse("PERMESSAGE-DEFLATE; SERVER_NO_CONTEXT_TAKEOVER; CLIENT_NO_CONTEXT_TAKEOVER"))
          .isEqualTo(
            WebSocketExtensions(
              perMessageDeflate = true,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 8.3K bytes
    - Viewed (0)
  5. okhttp/src/test/resources/web-platform-test-urltestdata.txt

    \#\u03B2  s:http h:example.org p:/foo/bar f:#\u03B2
    data:text/html,test#test  s:data p:text/html,test f:#test
    
    # Based on http://trac.webkit.org/browser/trunk/LayoutTests/fast/url/file.html
    
    # Basic canonicalization, uppercase should be converted to lowercase
    file:c:\\foo\\bar.html file:///tmp/mock/path s:file p:/c:/foo/bar.html
    
    # Spaces should fail
    \s\sFile:c|////foo\\bar.html  s:file p:/c:////foo/bar.html
    
    # This should fail
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Dec 20 23:27:07 GMT 2023
    - 14.3K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/HttpUrlTest.kt

          .isEqualTo("http://%25:%25@host/%25?%25#%25")
        assertThat(url.resolve("").toString()).isEqualTo("http://%25:%25@host/%25?%25")
      }
    
      /**
       * Although HttpUrl prefers percent-encodings in uppercase, it should preserve the exact structure
       * of the original encoding.
       */
      @Test
      fun rawEncodingRetained() {
        val urlString = "http://%6d%6D:%6d%6D@host/%6d%6D?%6d%6D#%6d%6D"
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 67.9K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/UrlComponentEncodingTester.kt

            val percentEncoded = Buffer()
            for (i in 0 until utf8.size) {
              percentEncoded.writeUtf8("%")
                .writeUtf8(ByteString.of(utf8[i]).hex().uppercase())
            }
            return percentEncoded.readUtf8()
          }
        },
    
        /** URLs that contain this character in this component are invalid.  */
        FORBIDDEN,
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/MediaTypeTest.kt

     *
     * This test includes tests from [Guava's](https://code.google.com/p/guava-libraries/)
     * MediaTypeTest.
     */
    open class MediaTypeTest {
      open fun MediaType.charsetName(): String? = parameter("charset")?.uppercase()
    
      protected open fun parse(string: String): MediaType = string.toMediaTypeOrNull()!!
    
      protected open fun assertInvalid(
        string: String,
        exceptionMessage: String?,
      ) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 7.5K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/http2/Hpack.kt

              } else {
                evictToRecoverBytes(dynamicTableByteCount - maxDynamicTableByteCount)
              }
            }
          }
        }
    
      /**
       * An HTTP/2 response cannot contain uppercase header characters and must be treated as
       * malformed.
       */
      @Throws(IOException::class)
      fun checkLowercase(name: ByteString): ByteString {
        for (i in 0 until name.size) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 22.5K bytes
    - Viewed (1)
Back to top