Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 31 for cookiejar (0.22 sec)

  1. okhttp/src/main/kotlin/okhttp3/CookieJar.kt

       */
      fun loadForRequest(url: HttpUrl): List<Cookie>
    
      companion object {
        /** A cookie jar that never accepts any cookies. */
        @JvmField
        val NO_COOKIES: CookieJar = NoCookies()
    
        private class NoCookies : CookieJar {
          override fun saveFromResponse(
            url: HttpUrl,
            cookies: List<Cookie>,
          ) {
          }
    
          override fun loadForRequest(url: HttpUrl): List<Cookie> {
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.4K bytes
    - Viewed (0)
  2. okhttp-java-net-cookiejar/api/okhttp-java-net-cookiejar.api

    public final class okhttp3/java/net/cookiejar/JavaNetCookieJar : okhttp3/CookieJar {
    	public fun <init> (Ljava/net/CookieHandler;)V
    	public fun loadForRequest (Lokhttp3/HttpUrl;)Ljava/util/List;
    	public fun saveFromResponse (Lokhttp3/HttpUrl;Ljava/util/List;)V
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Nov 20 16:20:29 GMT 2023
    - 264 bytes
    - Viewed (0)
  3. okhttp-urlconnection/src/main/kotlin/okhttp3/JavaNetCookieJar.kt

     *
     * This implementation delegates everything to [okhttp3.java.net.cookiejar.JavaNetCookieJar], which
     * conforms to the package-naming limitations of JPMS.
     *
     * Callers should prefer to use [okhttp3.java.net.cookiejar.JavaNetCookieJar] directly.
     */
    class JavaNetCookieJar private constructor(
      delegate: okhttp3.java.net.cookiejar.JavaNetCookieJar,
    ) : CookieJar by delegate {
      constructor(cookieHandler: CookieHandler) : this(
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.3K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/CookiesTest.kt

        val cookieManager = CookieManager(null, CookiePolicy.ACCEPT_ORIGINAL_SERVER)
        val cookieJar = JavaNetCookieJar(cookieManager)
        val url = "https://www.squareup.com/".toHttpUrl()
        cookieJar.saveFromResponse(url, listOf(parse(url, "a=android; Domain=squareup.com")!!))
        val actualCookies = cookieJar.loadForRequest(url)
        assertThat(actualCookies.size).isEqualTo(1)
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 13K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/http/BridgeInterceptor.kt

     * request. Then it proceeds to call the network. Finally it builds a user response from the network
     * response.
     */
    class BridgeInterceptor(private val cookieJar: CookieJar) : Interceptor {
      @Throws(IOException::class)
      override fun intercept(chain: Interceptor.Chain): Response {
        val userRequest = chain.request()
        val requestBuilder = userRequest.newBuilder()
    
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4.2K bytes
    - Viewed (2)
  6. okhttp-java-net-cookiejar/build.gradle.kts

      id("com.vanniktech.maven.publish.base")
      id("binary-compatibility-validator")
    }
    
    project.applyOsgi(
      "Export-Package: okhttp3.java.net.cookiejar",
      "Automatic-Module-Name: okhttp3.java.net.cookiejar",
      "Bundle-SymbolicName: com.squareup.okhttp3.java.net.cookiejar"
    )
    
    dependencies {
      api(projects.okhttp)
      compileOnly(libs.findbugs.jsr305)
      compileOnly(libs.animalsniffer.annotations)
    }
    
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Nov 20 16:20:29 GMT 2023
    - 621 bytes
    - Viewed (0)
  7. okhttp-java-net-cookiejar/src/main/kotlin/okhttp3/java/net/cookiejar/JavaNetCookieJar.kt

     * limitations under the License.
     */
    @file:Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
    
    package okhttp3.java.net.cookiejar
    
    import java.io.IOException
    import java.net.CookieHandler
    import java.net.HttpCookie
    import java.util.Collections
    import okhttp3.Cookie
    import okhttp3.CookieJar
    import okhttp3.HttpUrl
    import okhttp3.internal.cookieToString
    import okhttp3.internal.delimiterOffset
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Sat Apr 06 04:10:43 GMT 2024
    - 3.8K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/OkHttpClient.kt

         * outgoing HTTP requests.
         *
         * If unset, [no cookies][CookieJar.NO_COOKIES] will be accepted nor provided.
         */
        fun cookieJar(cookieJar: CookieJar) =
          apply {
            this.cookieJar = cookieJar
          }
    
        /** Sets the response cache to be used to read and write cached responses. */
        fun cache(cache: Cache?) =
          apply {
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Sat Apr 06 04:21:33 GMT 2024
    - 52K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/http/HttpHeaders.kt

      if (tokenSize == -1L) tokenSize = size
    
      return when {
        tokenSize != 0L -> readUtf8(tokenSize)
        else -> null
      }
    }
    
    fun CookieJar.receiveHeaders(
      url: HttpUrl,
      headers: Headers,
    ) {
      if (this === CookieJar.NO_COOKIES) return
    
      val cookies = Cookie.parseAll(url, headers)
      if (cookies.isEmpty()) return
    
      saveFromResponse(url, cookies)
    }
    
    /**
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 7.2K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

        builder = builder.secure()
        builder = builder.httpOnly()
        builder = builder.sameSite("None")
        val cookie: Cookie = builder.build()
      }
    
      @Test
      fun cookieJar() {
        val cookieJar =
          object : CookieJar {
            override fun saveFromResponse(
              url: HttpUrl,
              cookies: List<Cookie>,
            ) = TODO()
    
    Plain Text
    - Registered: Fri Apr 19 11:42:09 GMT 2024
    - Last Modified: Mon Apr 01 14:21:25 GMT 2024
    - 46.5K bytes
    - Viewed (4)
Back to top