Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 150 for substring (0.22 sec)

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

      }
    
      @Test
      fun truncatedMetadataEntry() {
        val response =
          testCorruptingCache {
            corruptMetadata {
              // truncate metadata to 1/4 of length
              it.substring(0, it.length / 4)
            }
          }
    
        assertThat(response.body.string()).isEqualTo("ABC.2") // not cached
        assertThat(cache.requestCount()).isEqualTo(2)
        assertThat(cache.networkCount()).isEqualTo(2)
    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)
  2. okhttp/src/main/kotlin/okhttp3/internal/http/StatusLine.kt

          // Parse response code like "200". Always 3 digits.
          if (statusLine.length < codeStart + 3) {
            throw ProtocolException("Unexpected status line: $statusLine")
          }
          val code =
            statusLine.substring(codeStart, codeStart + 3).toIntOrNull()
              ?: throw ProtocolException(
                "Unexpected status line: $statusLine",
              )
    
          // Parse an optional response message like "OK" or "Not Modified". If it
    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. mockwebserver/src/main/kotlin/mockwebserver3/RecordedRequest.kt

        }
    
        if (requestLine.isNotEmpty()) {
          val methodEnd = requestLine.indexOf(' ')
          val pathEnd = requestLine.indexOf(' ', methodEnd + 1)
          this.method = requestLine.substring(0, methodEnd)
          var path = requestLine.substring(methodEnd + 1, pathEnd)
          if (!path.startsWith("/")) {
            path = "/"
          }
          this.path = path
    
          val scheme = if (socket is SSLSocket) "https" else "http"
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 23 14:31:42 GMT 2024
    - 3.8K bytes
    - Viewed (1)
  4. okhttp/src/main/kotlin/okhttp3/internal/-RequestCommon.kt

      // Silently replace web socket URLs with HTTP URLs.
      return when {
        url.startsWith("ws:", ignoreCase = true) -> {
          "http:${url.substring(3)}"
        }
        url.startsWith("wss:", ignoreCase = true) -> {
          "https:${url.substring(4)}"
        }
        else -> url
      }
    }
    
    fun Request.Builder.commonHeader(
      name: String,
      value: String,
    ) = apply {
      headers[name] = value
    }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4.1K bytes
    - Viewed (0)
  5. maven-core/src/test/java/org/apache/maven/project/LegacyLocalRepositoryManager.java

            String result;
            int idx = filename.indexOf('.');
            if (idx < 0) {
                result = filename + '-' + repositoryKey;
            } else {
                result = filename.substring(0, idx) + '-' + repositoryKey + filename.substring(idx);
            }
            return result;
        }
    
        public LocalArtifactResult find(RepositorySystemSession session, LocalArtifactRequest request) {
    Java
    - Registered: Sun Apr 28 03:35:10 GMT 2024
    - Last Modified: Wed Feb 28 07:40:37 GMT 2024
    - 5.4K bytes
    - Viewed (0)
  6. maven-compat/src/test/java/org/apache/maven/project/LegacyLocalRepositoryManager.java

            String result;
            int idx = filename.indexOf('.');
            if (idx < 0) {
                result = filename + '-' + repositoryKey;
            } else {
                result = filename.substring(0, idx) + '-' + repositoryKey + filename.substring(idx);
            }
            return result;
        }
    
        public LocalArtifactResult find(RepositorySystemSession session, LocalArtifactRequest request) {
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Thu Apr 25 05:46:50 GMT 2024
    - 5.4K bytes
    - Viewed (0)
  7. docs_src/generate_clients/tutorial004.js

              const tag = operation.tags[0]
              const operationId = operation.operationId
              const toRemove = `${tag}-`
              if (operationId.startsWith(toRemove)) {
                const newOperationId = operationId.substring(toRemove.length)
                operation.operationId = newOperationId
              }
            }
          }
        }
    
        await fs.promises.writeFile(
          filePath,
          JSON.stringify(openapiContent, null, 2),
    JavaScript
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Mar 14 11:40:05 GMT 2024
    - 1K bytes
    - Viewed (0)
  8. src/main/webapp/js/admin/plugins/form-validator/jsconf.js

    a.each(b.validate||b.validation||{},function(b,d){var e;e="#"===b[0]?a(b):"."===b[0]?c.find(b):c.find('*[name="'+b+'"]'),e.attr("data-validation",d.validation),a.each(d,function(a,b){"validation"!==a&&b!==!1&&(b===!0&&(b="true"),"_"===a[0]?(a=a.substring(1),b===!1?e.removeAttr(a):e.attr(a,b)):e.valAttr(a,b))})}),a.validate(b)}}(a)});...
    JavaScript
    - Registered: Mon May 06 08:04:11 GMT 2024
    - Last Modified: Mon Jan 01 05:12:47 GMT 2018
    - 867 bytes
    - Viewed (0)
  9. maven-compat/src/main/java/org/apache/maven/usability/plugin/ExpressionDocumenter.java

            String myClasspathEntry = myResource.getPath();
    
            myClasspathEntry = myClasspathEntry.substring(0, myClasspathEntry.length() - (myResourcePath.length() + 2));
    
            if (myClasspathEntry.startsWith("file:")) {
                myClasspathEntry = myClasspathEntry.substring("file:".length());
            }
    
            URL docResource;
            try {
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Wed Sep 06 11:28:54 GMT 2023
    - 5.2K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/internal/http2/HuffmanTest.kt

    class HuffmanTest {
      @Test
      fun roundTripForRequestAndResponse() {
        val s = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"
        for (i in s.indices) {
          assertRoundTrip(s.substring(0, i).encodeUtf8())
        }
        val random = Random(123456789L)
        val buf = ByteArray(4096)
        random.nextBytes(buf)
        assertRoundTrip(buf.toByteString())
      }
    
      private fun assertRoundTrip(data: ByteString) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Jan 04 05:32:07 GMT 2024
    - 1.8K bytes
    - Viewed (0)
Back to top