Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 176 for require (0.72 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/-ResponseCommon.kt

      }
    
    private fun checkSupportResponse(
      name: String,
      response: Response?,
    ) {
      response?.apply {
        require(networkResponse == null) { "$name.networkResponse != null" }
        require(cacheResponse == null) { "$name.cacheResponse != null" }
        require(priorResponse == null) { "$name.priorResponse != null" }
      }
    }
    
    fun Response.Builder.commonPriorResponse(priorResponse: Response?) =
      apply {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:24:48 GMT 2024
    - 5.2K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/CacheControl.kt

          apply {
            val maxAgeSeconds = maxAge.inWholeSeconds
            require(maxAgeSeconds >= 0) { "maxAge < 0: $maxAgeSeconds" }
            this.maxAgeSeconds = maxAgeSeconds.commonClampToInt()
          }
    
        fun maxStale(maxStale: Duration) =
          apply {
            val maxStaleSeconds = maxStale.inWholeSeconds
            require(maxStaleSeconds >= 0) { "maxStale < 0: $maxStaleSeconds" }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:41:01 GMT 2024
    - 10K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/connection/RealConnectionPool.kt

        require(keepAliveDuration > 0L) { "keepAliveDuration <= 0: $keepAliveDuration" }
      }
    
      fun idleConnectionCount(): Int {
        return connections.count {
          it.withLock { it.calls.isEmpty() }
        }
      }
    
      fun connectionCount(): Int {
        return connections.size
      }
    
      /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 16.2K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Writer.kt

        flags: Int,
      ) {
        if (type != TYPE_WINDOW_UPDATE && logger.isLoggable(FINE)) {
          logger.fine(frameLog(false, streamId, length, type, flags))
        }
        require(length <= maxFrameSize) { "FRAME_SIZE_ERROR length > $maxFrameSize: $length" }
        require(streamId and 0x80000000.toInt() == 0) { "reserved bit set: $streamId" }
        sink.writeMedium(length)
        sink.writeByte(type and 0xff)
        sink.writeByte(flags and 0xff)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 11.3K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/Cookie.kt

          // seconds are not supported by this syntax.
          require(year >= 1601)
          require(month != -1)
          require(dayOfMonth in 1..31)
          require(hour in 0..23)
          require(minute in 0..59)
          require(second in 0..59)
    
          GregorianCalendar(UTC).apply {
            isLenient = false
            set(Calendar.YEAR, year)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 06 04:12:05 GMT 2024
    - 23.1K bytes
    - Viewed (0)
  6. okhttp-testing-support/src/main/kotlin/okhttp3/internal/concurrent/TaskFaker.kt

      ) : SerialTask {
        override fun start() {
          taskRunner.assertThreadHoldsLock()
          require(currentTask == this)
          activeThreads++
    
          tasksExecutor.execute {
            taskRunner.assertThreadDoesntHoldLock()
            require(currentTask == this)
            try {
              runnable.run()
              require(currentTask == this) { "unexpected current task: $currentTask" }
            } finally {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 29 00:33:04 GMT 2024
    - 12.6K bytes
    - Viewed (0)
  7. .cm/complex_changes.cm

      - commit
      - comment_added
    
    automations:
    
      # If a PR is very complex, require 2 approvals
      complex_changes:
        if:
          - {{ ('complex_changes' | isEnabledAutomation(pr)) }}
          - {{ branch | estimatedReviewTime >= 40 }}
          - {{ files | length >= 35 }}
          - {{ includes_src_changes }}
        run:
          - action: set-required-approvals@v1
            args:
              approvals: 2
    
    Plain Text
    - Registered: Wed May 01 11:36:15 GMT 2024
    - Last Modified: Fri Apr 12 13:42:16 GMT 2024
    - 1.7K bytes
    - Viewed (0)
  8. analysis/analysis-api-fe10/src/org/jetbrains/kotlin/analysis/api/descriptors/components/KtFe10ScopeProvider.kt

        }
    
        override fun getFileScope(fileSymbol: KtFileSymbol): KtScope {
            require(fileSymbol is KtFe10FileSymbol)
            return KtFe10FileScope(fileSymbol.psi, analysisContext, token)
        }
    
        override fun getPackageScope(packageSymbol: KtPackageSymbol): KtScope {
            require(packageSymbol is KtFe10PackageSymbol)
    Plain Text
    - Registered: Fri May 03 08:18:13 GMT 2024
    - Last Modified: Thu Apr 25 18:05:58 GMT 2024
    - 12.6K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt

        if (flushHeaders) {
          connection.flush()
        }
      }
    
      fun enqueueTrailers(trailers: Headers) {
        this.withLock {
          check(!sink.finished) { "already finished" }
          require(trailers.size != 0) { "trailers.size() == 0" }
          this.sink.trailers = trailers
        }
      }
    
      fun readTimeout(): Timeout = readTimeout
    
      fun writeTimeout(): Timeout = writeTimeout
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 23.2K bytes
    - Viewed (1)
  10. okhttp/src/test/java/okhttp3/FakeRoutePlanner.kt

      override fun isCanceled() = canceled
    
      override fun plan(): FakePlan {
        // Return deferred plans preferentially. These don't require addPlan().
        if (deferredPlans.isNotEmpty()) return deferredPlans.removeFirst() as FakePlan
    
        if (nextPlanIndex >= plans.size && autoGeneratePlans) addPlan()
    
        require(nextPlanIndex < plans.size) {
          "not enough plans! call addPlan() or set autoGeneratePlans=true in the test to set this up"
        }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 24 04:40:49 GMT 2024
    - 6.2K bytes
    - Viewed (0)
Back to top