Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for forJavaName (0.54 sec)

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

        val cs = forJavaName("FakeCipherSuite_instancesAreInterned")
        System.gc() // Unless cs references the String instance, it may now be garbage collected.
        assertThat(forJavaName(java.lang.String(cs.javaName) as String))
          .isSameAs(cs)
      }
    
      @Test
      fun equals() {
        assertThat(forJavaName("cipher")).isEqualTo(forJavaName("cipher"))
        assertThat(forJavaName("cipherB")).isNotEqualTo(forJavaName("cipherA"))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 8.2K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/Handshake.kt

              }
              else -> CipherSuite.forJavaName(cipherSuiteString)
            }
    
          val tlsVersionString = checkNotNull(protocol) { "tlsVersion == null" }
          if ("NONE" == tlsVersionString) throw IOException("tlsVersion == NONE")
          val tlsVersion = TlsVersion.forJavaName(tlsVersionString)
    
          val peerCertificatesCopy =
            try {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 6.8K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/TlsVersion.kt

        message = "moved to val",
        replaceWith = ReplaceWith(expression = "javaName"),
        level = DeprecationLevel.ERROR,
      )
      fun javaName(): String = javaName
    
      companion object {
        @JvmStatic
        fun forJavaName(javaName: String): TlsVersion {
          return when (javaName) {
            "TLSv1.3" -> TLS_1_3
            "TLSv1.2" -> TLS_1_2
            "TLSv1.1" -> TLS_1_1
            "TLSv1" -> TLS_1_0
            "SSLv3" -> SSL_3_0
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.5K bytes
    - Viewed (1)
  4. docs/changelogs/upgrading_to_okhttp_4.md

    the same but `.kt` files now need `Companion` in the import.
    
    This works with OkHttp 3.x:
    
    ```kotlin
    import okhttp3.CipherSuite.forJavaName
    ```
    
    But OkHttp 4.x needs a `Companion`:
    
    ```kotlin
    import okhttp3.CipherSuite.Companion.forJavaName
    ```
    
    In the unlikely event that you have a lot of these, run this:
    
    ```bash
    sed -i "" \
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 16:58:16 GMT 2022
    - 10.9K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/SessionReuseTest.kt

        if (tlsVersion == TlsVersion.TLS_1_3.javaName) {
          assumeTrue(PlatformVersion.majorVersion != 8)
        }
    
        val sessionIds = mutableListOf<String>()
    
        enableTls()
    
        val tlsVersion = TlsVersion.forJavaName(tlsVersion)
        val spec =
          ConnectionSpec.Builder(ConnectionSpec.MODERN_TLS)
            .tlsVersions(tlsVersion)
            .build()
    
        var reuseSession = false
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 6K bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/ConnectionSpec.kt

       * enabled cipher suites should be used.
       */
      @get:JvmName("cipherSuites")
      val cipherSuites: List<CipherSuite>?
        get() {
          return cipherSuitesAsString?.map { CipherSuite.forJavaName(it) }
        }
    
      @JvmName("-deprecated_cipherSuites")
      @Deprecated(
        message = "moved to val",
        replaceWith = ReplaceWith(expression = "cipherSuites"),
        level = DeprecationLevel.ERROR,
      )
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 13.4K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/Cache.kt

              val cipherSuiteString = source.readUtf8LineStrict()
              val cipherSuite = CipherSuite.forJavaName(cipherSuiteString)
              val peerCertificates = readCertificateList(source)
              val localCertificates = readCertificateList(source)
              val tlsVersion =
                if (!source.exhausted()) {
                  TlsVersion.forJavaName(source.readUtf8LineStrict())
                } else {
                  TlsVersion.SSL_3_0
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 26.8K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

      }
    
      @Test
      fun cipherSuite() {
        var cipherSuite: CipherSuite = CipherSuite.TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
        cipherSuite = CipherSuite.forJavaName("")
        val javaName: String = cipherSuite.javaName
      }
    
      @Test
      fun connection() {
        val connection =
          object : Connection {
            override fun route(): Route = TODO()
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 01 14:21:25 GMT 2024
    - 46.5K bytes
    - Viewed (4)
  9. okhttp/api/okhttp.api

    	public static final fun forJavaName (Ljava/lang/String;)Lokhttp3/CipherSuite;
    	public final fun javaName ()Ljava/lang/String;
    	public fun toString ()Ljava/lang/String;
    }
    
    public final class okhttp3/CipherSuite$Companion {
    	public final fun forJavaName (Ljava/lang/String;)Lokhttp3/CipherSuite;
    }
    
    public abstract interface class okhttp3/Connection {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:41:01 GMT 2024
    - 70.2K bytes
    - Viewed (0)
  10. okhttp/src/main/kotlin/okhttp3/CipherSuite.kt

         *     name for older cipher suites because the prefix is `SSL_` instead of `TLS_`.
         */
        @JvmStatic
        @Synchronized fun forJavaName(javaName: String): CipherSuite {
          var result: CipherSuite? = INSTANCES[javaName]
          if (result == null) {
            result = INSTANCES[secondaryName(javaName)]
    
            if (result == null) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 39.9K bytes
    - Viewed (1)
Back to top