Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 66 for Synchronized (7.39 sec)

  1. android/guava-testlib/src/com/google/common/testing/TestLogHandler.java

      @Override
      public void publish(@Nullable LogRecord record) {
        synchronized (lock) {
          if (record != null) {
            list.add(record);
          }
        }
      }
    
      @Override
      public void flush() {}
    
      @Override
      public void close() {}
    
      public void clear() {
        synchronized (lock) {
          list.clear();
        }
      }
    
      /** Returns a snapshot of the logged records. */
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sun Dec 22 03:38:46 UTC 2024
    - 2.8K bytes
    - Viewed (0)
  2. mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/MockWebServer.kt

      fun start(
        inetAddress: InetAddress,
        port: Int,
      ) {
        started = true
        delegate.start(inetAddress, port)
      }
    
      @Synchronized
      @Throws(IOException::class)
      fun shutdown() {
        delegate.close()
      }
    
      @Synchronized override fun after() {
        try {
          shutdown()
        } catch (e: IOException) {
          logger.log(Level.WARNING, "MockWebServer shutdown failed", e)
        }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Jun 18 00:19:42 UTC 2025
    - 4.6K bytes
    - Viewed (0)
  3. src/main/java/org/codelibs/core/timer/TimeoutManager.java

         */
        public synchronized void clear() {
            timeoutTaskList.clear();
        }
    
        /**
         * Adds a {@link TimeoutTarget}.
         *
         * @param timeoutTarget the target
         * @param timeout the timeout duration
         * @param permanent whether the task is permanent
         * @return the {@link TimeoutTask}
         */
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Sat May 10 01:32:17 UTC 2025
    - 7.8K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/util/concurrent/DirectExecutorService.java

        startTask();
        try {
          command.run();
        } finally {
          endTask();
        }
      }
    
      @Override
      public boolean isShutdown() {
        synchronized (lock) {
          return shutdown;
        }
      }
    
      @Override
      public void shutdown() {
        synchronized (lock) {
          shutdown = true;
          if (runningTasks == 0) {
            lock.notifyAll();
          }
        }
      }
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Apr 12 15:07:59 UTC 2025
    - 3.5K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/FutureCallbackTest.java

        }
    
        @Override
        public void onSuccess(String result) {
          synchronized (monitor) {
            assertFalse(wasCalled);
            wasCalled = true;
            assertEquals(value, result);
          }
        }
    
        @Override
        public synchronized void onFailure(Throwable t) {
          synchronized (monitor) {
            assertFalse(wasCalled);
            wasCalled = true;
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Jul 14 14:44:08 UTC 2025
    - 6.7K bytes
    - Viewed (0)
  6. samples/slack/src/main/java/okhttp3/slack/SlackClient.java

      }
    
      /** Set the OAuth session for this client. */
      public synchronized void initOauthSession(OAuthSession session) {
        this.session = session;
        this.notifyAll();
      }
    
      /** Waits for an OAuth session for this client to be set. */
      public synchronized void awaitAccessToken(Timeout timeout) throws InterruptedIOException {
        while (session == null) {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Jan 12 03:31:36 UTC 2019
    - 3.4K bytes
    - Viewed (0)
  7. guava/src/com/google/common/util/concurrent/DirectExecutorService.java

        startTask();
        try {
          command.run();
        } finally {
          endTask();
        }
      }
    
      @Override
      public boolean isShutdown() {
        synchronized (lock) {
          return shutdown;
        }
      }
    
      @Override
      public void shutdown() {
        synchronized (lock) {
          shutdown = true;
          if (runningTasks == 0) {
            lock.notifyAll();
          }
        }
      }
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Apr 12 15:07:59 UTC 2025
    - 3.5K bytes
    - Viewed (0)
  8. okhttp/src/commonJvmAndroid/kotlin/okhttp3/Dispatcher.kt

      /** Returns a snapshot of the calls currently awaiting execution. */
      @Synchronized
      fun queuedCalls(): List<Call> = readyAsyncCalls.map { it.call }.unmodifiable()
    
      /** Returns a snapshot of the calls currently being executed. */
      @Synchronized
      fun runningCalls(): List<Call> = (runningSyncCalls + runningAsyncCalls.map { it.call }).unmodifiable()
    
      @Synchronized
      fun queuedCallsCount(): Int = readyAsyncCalls.size
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed May 28 23:28:25 UTC 2025
    - 8.7K bytes
    - Viewed (0)
  9. samples/slack/src/main/java/okhttp3/slack/OAuthSessionFactory.java

      }
    
      public HttpUrl newAuthorizeUrl(String scopes, String team, Listener listener) {
        if (mockWebServer == null) throw new IllegalStateException();
    
        ByteString state = randomToken();
        synchronized (this) {
          listeners.put(state, listener);
        }
    
        return slackApi.authorizeUrl(scopes, redirectUrl(), state, team);
      }
    
      private ByteString randomToken() {
        byte[] bytes = new byte[16];
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Aug 12 07:26:27 UTC 2021
    - 3.8K bytes
    - Viewed (0)
  10. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/RouteDatabase.kt

      private val _failedRoutes = mutableSetOf<Route>()
    
      val failedRoutes: Set<Route>
        @Synchronized get() = _failedRoutes.toSet()
    
      /** Records a failure connecting to [failedRoute]. */
      @Synchronized fun failed(failedRoute: Route) {
        _failedRoutes.add(failedRoute)
      }
    
      /** Records success connecting to [route]. */
      @Synchronized fun connected(route: Route) {
        _failedRoutes.remove(route)
      }
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Dec 27 13:39:56 UTC 2024
    - 1.5K bytes
    - Viewed (0)
Back to top