Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for uri (0.12 sec)

  1. okhttp-testing-support/src/main/kotlin/okhttp3/FakeProxySelector.kt

    import java.net.SocketAddress
    import java.net.URI
    
    class FakeProxySelector : ProxySelector() {
      val proxies: MutableList<Proxy> = mutableListOf()
    
      fun addProxy(proxy: Proxy): FakeProxySelector {
        proxies.add(proxy)
        return this
      }
    
      override fun select(uri: URI): List<Proxy> {
        // Don't handle 'socket' schemes, which the RI's Socket class may request (for SOCKS).
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.3K bytes
    - Viewed (0)
  2. samples/slack/src/main/java/okhttp3/slack/SlackApi.java

        HttpUrl.Builder builder = baseUrl.newBuilder("/oauth/authorize")
            .addQueryParameter("client_id", clientId)
            .addQueryParameter("scope", scopes)
            .addQueryParameter("redirect_uri", redirectUrl.toString())
            .addQueryParameter("state", state.base64());
    
        if (team != null) {
          builder.addQueryParameter("team", team);
        }
    
        return builder.build();
      }
    
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Jul 06 19:30:55 GMT 2018
    - 4.4K bytes
    - Viewed (1)
  3. okhttp/src/main/kotlin/okhttp3/internal/proxy/NullProxySelector.kt

    import java.net.SocketAddress
    import java.net.URI
    
    /**
     * A proxy selector that always returns the [Proxy.NO_PROXY].
     */
    object NullProxySelector : ProxySelector() {
      override fun select(uri: URI?): List<Proxy> {
        requireNotNull(uri) { "uri must not be null" }
        return listOf(Proxy.NO_PROXY)
      }
    
      override fun connectFailed(
        uri: URI?,
        sa: SocketAddress?,
        ioe: IOException?,
      ) {
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.1K bytes
    - Viewed (0)
  4. container-tests/src/test/java/okhttp3/containers/BasicProxyTest.kt

     */
    package okhttp3.containers
    
    import assertk.assertThat
    import assertk.assertions.contains
    import assertk.assertions.isEqualTo
    import java.net.HttpURLConnection
    import java.net.Proxy
    import java.net.URI
    import javax.net.ssl.HttpsURLConnection
    import okhttp3.HttpUrl.Companion.toHttpUrl
    import okhttp3.OkHttpClient
    import okhttp3.Protocol
    import okhttp3.Request
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Apr 05 03:30:42 GMT 2024
    - 5.9K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/SocksProxyTest.kt

        server.enqueue(MockResponse.Builder().body("abc").build())
        val proxySelector: ProxySelector =
          object : ProxySelector() {
            override fun select(uri: URI) = listOf(socksProxy.proxy())
    
            override fun connectFailed(
              uri: URI,
              socketAddress: SocketAddress,
              e: IOException,
            ) = error("unexpected call")
          }
        val client =
          clientTestRule.newClientBuilder()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/UrlComponentEncodingTesterJvm.kt

        val uri = httpUrl.toUri()
        val toAndFromUri = uri.toHttpUrlOrNull()
        val uriStripped = uriStrippedCodePoints.indexOf(codePointString) != -1
        if (uriStripped) {
          if (uri.toString() != component.urlString("")) {
            fail("Encoding $component $codePoint using $encoding")
          }
          return
        }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.5K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/connection/RouteSelector.kt

          if (proxy != null) return listOf(proxy)
    
          // If the URI lacks a host (as in "http://</"), don't call the ProxySelector.
          val uri = url.toUri()
          if (uri.host == null) return immutableListOf(Proxy.NO_PROXY)
    
          // Try each of the ProxySelector choices until one connection succeeds.
          val proxiesOrNull = address.proxySelector.select(uri)
          if (proxiesOrNull.isNullOrEmpty()) return immutableListOf(Proxy.NO_PROXY)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Mar 06 17:33:38 GMT 2024
    - 7.2K bytes
    - Viewed (0)
  8. build.gradle.kts

          }
          if (project.file("Module.md").exists()) {
            includes.from(project.file("Module.md"))
          }
          externalDocumentationLink {
            url.set(URI.create("https://square.github.io/okio/3.x/okio/").toURL())
            packageListUrl.set(URI.create("https://square.github.io/okio/3.x/okio/okio/package-list").toURL())
          }
        }
      }
    
      plugins.withId("com.vanniktech.maven.publish.base") {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 18 01:32:42 GMT 2024
    - 8.9K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/url/-Url.kt

    internal const val PATH_SEGMENT_ENCODE_SET = " \"<>^`{}|/\\?#"
    internal const val PATH_SEGMENT_ENCODE_SET_URI = "[]"
    internal const val QUERY_ENCODE_SET = " \"'<>#"
    internal const val QUERY_COMPONENT_REENCODE_SET = " \"'<>#&="
    internal const val QUERY_COMPONENT_ENCODE_SET = " !\"#$&'(),/:;<=>?@[]\\^`{|}~"
    internal const val QUERY_COMPONENT_ENCODE_SET_URI = "\\^`{|}"
    internal const val FORM_ENCODE_SET = " !\"#$&'()+,/:;<=>?@[\\]^`{|}~"
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 09 12:33:05 GMT 2024
    - 7.3K bytes
    - Viewed (0)
  10. mkdocs.yml

    repo_name: OkHttp
    repo_url: https://github.com/square/okhttp
    site_description: "Square’s meticulous HTTP client for the JVM, Android, and GraalVM"
    site_author: Square, Inc.
    remote_branch: gh-pages
    edit_uri: ""
    
    copyright: 'Copyright &copy; 2022 Block, Inc.'
    
    theme:
      name: 'material'
      favicon: assets/images/icon-square.png
      logo: assets/images/icon-square.png
      palette:
    Others
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Nov 20 15:26:12 GMT 2023
    - 3.8K bytes
    - Viewed (0)
Back to top