Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 25 for hasNext (0.26 sec)

  1. okhttp-tls/src/test/java/okhttp3/tls/internal/der/DerTest.kt

            assertThat(header.length).isEqualTo(5L)
            assertThat(derReader.readOctetString()).isEqualTo("Jones".encodeUtf8())
          }
    
          assertThat(derReader.hasNext()).isFalse()
        }
    
        assertThat(derReader.hasNext()).isFalse()
      }
    
      @Test fun `encode tagged implicit prefixed type`() {
        // Type1 ::= VisibleString
        // Type2 ::= [APPLICATION 3] IMPLICIT Type1
        // Type3 ::= [2] Type2
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 31.7K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http2/MockHttp2Peer.kt

        for (i in 0 until frameCount) {
          if (nextOutFrame == null && outFramesIterator.hasNext()) {
            nextOutFrame = outFramesIterator.next()
          }
    
          if (nextOutFrame != null && nextOutFrame.sequence == i) {
            val start = nextOutFrame.start
            var truncated: Boolean
            var end: Long
            if (outFramesIterator.hasNext()) {
              nextOutFrame = outFramesIterator.next()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 11 22:09:35 GMT 2024
    - 8.7K bytes
    - Viewed (0)
  3. okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerAdapter.kt

              for (v in value) {
                toDer(writer, v)
              }
            }
    
            override fun decode(reader: DerReader): List<T> {
              val result = mutableListOf<T>()
              while (reader.hasNext()) {
                result += fromDer(reader)
              }
              return result
            }
          }
    
        return BasicDerAdapter(name, tagClass, tag, codec)
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/connection/RouteSelectorTest.kt

        assertThat(routeSelector.hasNext()).isTrue()
        dns[uriHost] = dns.allocate(2)
        val selection = routeSelector.next()
        assertRoute(selection.next(), address, Proxy.NO_PROXY, dns.lookup(uriHost, 0), uriPort)
        assertRoute(selection.next(), address, Proxy.NO_PROXY, dns.lookup(uriHost, 1), uriPort)
        assertThat(selection.hasNext()).isFalse()
        assertThat(routeSelector.hasNext()).isFalse()
        dns.assertRequests(uriHost)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Mar 06 17:33:38 GMT 2024
    - 20.8K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/connection/RealCall.kt

          exchange?.detachWithViolence()
        }
    
        interceptorScopedExchange = null
      }
    
      fun retryAfterFailure(): Boolean {
        return exchange?.hasFailure == true &&
          exchangeFinder!!.routePlanner.hasNext(exchange?.connection)
      }
    
      /**
       * Returns a string that describes this call. Doesn't include a full URL as that might contain
       * sensitive information.
       */
      private fun toLoggableString(): String {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 17.9K bytes
    - Viewed (2)
  6. okhttp/src/main/kotlin/okhttp3/internal/connection/FastFallbackExchangeFinder.kt

      override fun find(): RealConnection {
        var firstException: IOException? = null
        try {
          while (tcpConnectsInFlight.isNotEmpty() || routePlanner.hasNext()) {
            if (routePlanner.isCanceled()) throw IOException("Canceled")
    
            // Launch a new connection if we're ready to.
            val now = taskRunner.backend.nanoTime()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/connection/RouteSelector.kt

      }
    
      /**
       * Returns true if there's another set of routes to attempt. Every address has at least one route.
       */
      operator fun hasNext(): Boolean = hasNextProxy() || postponedRoutes.isNotEmpty()
    
      @Throws(IOException::class)
      operator fun next(): Selection {
        if (!hasNext()) throw NoSuchElementException()
    
        // Compute the next set of routes to attempt.
        val routes = mutableListOf<Route>()
    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. okhttp/src/test/java/okhttp3/RecordingCallback.kt

      @Synchronized
      fun await(url: HttpUrl): RecordedResponse {
        val timeoutMillis = TimeUnit.NANOSECONDS.toMillis(System.nanoTime()) + TIMEOUT_MILLIS
        while (true) {
          val i = responses.iterator()
          while (i.hasNext()) {
            val recordedResponse = i.next()
            if (recordedResponse.request.url.equals(url)) {
              i.remove()
              return recordedResponse
            }
          }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.1K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/-UtilCommon.kt

      a: Iterable<T>,
      b: Iterable<T>,
    ): List<T> {
      val ia = a.iterator()
      val ib = b.iterator()
    
      return buildList {
        while (ia.hasNext() || ib.hasNext()) {
          if (ia.hasNext()) {
            add(ia.next())
          }
          if (ib.hasNext()) {
            add(ib.next())
          }
        }
      }
    }
    
    // TODO check read only options for creating lists
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 11K bytes
    - Viewed (0)
  10. okhttp/src/main/kotlin/okhttp3/internal/connection/RealRoutePlanner.kt

        }
    
        // If we have a routes left, use 'em.
        if (routeSelection?.hasNext() == true) return true
    
        // If we haven't initialized the route selector yet, assume it'll have at least one route.
        val localRouteSelector = routeSelector ?: return true
    
        // If we do have a route selector, use its routes.
        return localRouteSelector.hasNext()
      }
    
      /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 12K bytes
    - Viewed (0)
Back to top