Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 29 for Modified (0.2 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/http/HttpHeaders.kt

     * limitations under the License.
     */
    @file:JvmName("HttpHeaders")
    
    package okhttp3.internal.http
    
    import java.io.EOFException
    import java.net.HttpURLConnection.HTTP_NOT_MODIFIED
    import java.net.HttpURLConnection.HTTP_NO_CONTENT
    import java.util.Collections
    import okhttp3.Challenge
    import okhttp3.Cookie
    import okhttp3.CookieJar
    import okhttp3.Headers
    import okhttp3.HttpUrl
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 7.2K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/internal/http/StatusLine.kt

              ?: throw ProtocolException(
                "Unexpected status line: $statusLine",
              )
    
          // Parse an optional response message like "OK" or "Not Modified". If it
          // exists, it is separated from the response code by a space.
          var message = ""
          if (statusLine.length > codeStart + 3) {
            if (statusLine[codeStart + 3] != ' ') {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 09 12:33:05 GMT 2024
    - 3.3K bytes
    - Viewed (0)
  3. docs/features/caching.md

    As recommended by the HTTP RFC the max age of a document is defaulted to 10% of the 
    document's age at the time it was served based on "Last-Modified". Default expiration dates aren't used for URIs 
    containing a query.
    
     - CallStart
     - **CacheHit**
     - CallEnd
     
    ### Cache Miss
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 02:19:09 GMT 2022
    - 3.1K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/CacheCorruptionTest.kt

            headers =
              headersOf(
                "Last-Modified",
                formatDate(-1, TimeUnit.HOURS)!!,
                "Expires",
                formatDate(1, TimeUnit.HOURS)!!,
              ),
            body = "ABC.1",
          ),
        )
        server.enqueue(
          MockResponse(
            headers =
              headersOf(
                "Last-Modified",
                formatDate(-1, TimeUnit.HOURS)!!,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 6K bytes
    - Viewed (1)
  5. okhttp/src/test/java/okhttp3/CacheTest.kt

            MockResponse.Builder()
              .addHeader("Last-Modified: $lastModifiedDate")
              .addHeader("Date: " + formatDate(-15, TimeUnit.SECONDS))
              .build(),
          )
        assertThat(conditionalRequest.headers["If-Modified-Since"])
          .isEqualTo(lastModifiedDate)
      }
    
      @Test
      fun defaultExpirationDateFullyCachedForMoreThan24Hours() {
        //      last modified: 105 days ago
        //             served:   5 days ago
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 108.6K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

            .clearHeaders()
            .code(HttpURLConnection.HTTP_NOT_MODIFIED)
            .addHeader("Content-Encoding: gzip")
            .build(),
        )
        server.enqueue(
          MockResponse(body = "b"),
        )
        val response1 = getResponse(newRequest("/"))
        assertThat(response1.code).isEqualTo(HttpURLConnection.HTTP_NOT_MODIFIED)
        assertContent("", response1)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 131.7K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt

     *  limitations under the License.
     */
    package okhttp3.internal.cache
    
    import java.io.IOException
    import java.net.HttpURLConnection.HTTP_GATEWAY_TIMEOUT
    import java.net.HttpURLConnection.HTTP_NOT_MODIFIED
    import java.util.concurrent.TimeUnit.MILLISECONDS
    import okhttp3.Cache
    import okhttp3.EventListener
    import okhttp3.Headers
    import okhttp3.Interceptor
    import okhttp3.Protocol
    import okhttp3.Request
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Mar 22 07:09:21 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/internal/cache/CacheStrategy.kt

              conditionValue = etag
            }
    
            lastModified != null -> {
              conditionName = "If-Modified-Since"
              conditionValue = lastModifiedString
            }
    
            servedDate != null -> {
              conditionName = "If-Modified-Since"
              conditionValue = servedDateString
            }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:24:48 GMT 2024
    - 12K bytes
    - Viewed (0)
  9. docs/features/calls.md

    Some requests will have a cached response. When this cached response isn’t fresh, OkHttp can do a _conditional GET_ to download an updated response if it’s newer than what’s cached. This requires headers like `If-Modified-Since` and `If-None-Match` to be added.
    
    ## Rewriting Responses
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 02:19:09 GMT 2022
    - 3.9K bytes
    - Viewed (0)
  10. okhttp-sse/src/main/kotlin/okhttp3/sse/EventSource.kt

        /**
         * Creates a new event source and immediately returns it. Creating an event source initiates an
         * asynchronous process to connect the socket. Once that succeeds or fails, `listener` will be
         * notified. The caller must cancel the returned event source when it is no longer in use.
         */
        fun newEventSource(
          request: Request,
          listener: EventSourceListener,
        ): EventSource
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.4K bytes
    - Viewed (0)
Back to top