Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 1,298 for init (0.12 sec)

  1. android/guava-testlib/test/com/google/common/testing/anotherpackage/ForwardingWrapperTesterTest.java

        }
      }
    
      private interface Adder {
        int add(int a, int b);
      }
    
      private static class ForwardingArithmetic implements Arithmetic {
        private final Arithmetic arithmetic;
    
        public ForwardingArithmetic(Arithmetic arithmetic) {
          this.arithmetic = arithmetic;
        }
    
        @Override
        public int add(int a, int b) {
          return arithmetic.add(a, b);
        }
    
        @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 15.7K bytes
    - Viewed (0)
  2. guava/src/com/google/common/cache/CacheBuilderSpec.java

      }
    
      /**
       * Converts an expiration duration/unit pair into a single Long for hashing and equality. Uses
       * nanos to match CacheBuilder implementation.
       */
      @CheckForNull
      private static Long durationInNanos(long duration, @CheckForNull TimeUnit unit) {
        return (unit == null) ? null : unit.toNanos(duration);
      }
    
      /** Base class for parsing integers. */
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Aug 22 14:27:44 GMT 2022
    - 18.1K bytes
    - Viewed (0)
  3. guava/src/com/google/common/collect/JdkBackedImmutableMap.java

          }
        }
        if (duplicates != null) {
          @SuppressWarnings({"rawtypes", "unchecked"})
          Entry<K, V>[] newEntryArray = new Entry[n - dupCount];
          for (int inI = 0, outI = 0; inI < n; inI++) {
            Entry<K, V> entry = requireNonNull(entryArray[inI]);
            K key = entry.getKey();
            if (duplicates.containsKey(key)) {
              V value = duplicates.get(key);
              if (value == null) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Nov 30 21:54:06 GMT 2023
    - 4.8K bytes
    - Viewed (0)
  4. android/guava-testlib/src/com/google/common/util/concurrent/testing/SameThreadScheduledExecutorService.java

        }
    
        @Override
        public V get(long timeout, TimeUnit unit)
            throws InterruptedException, ExecutionException, TimeoutException {
          Preconditions.checkNotNull(unit, "unit must not be null!");
          return get();
        }
    
        @Override
        public long getDelay(TimeUnit unit) {
          Preconditions.checkNotNull(unit, "unit must not be null!");
          return 0;
        }
    
        @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Oct 06 00:47:57 GMT 2021
    - 6.4K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/base/Ascii.java

        int length = s1.length();
        if (s1 == s2) {
          return true;
        }
        if (length != s2.length()) {
          return false;
        }
        for (int i = 0; i < length; i++) {
          char c1 = s1.charAt(i);
          char c2 = s2.charAt(i);
          if (c1 == c2) {
            continue;
          }
          int alphaIndex = getAlphaIndex(c1);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Jul 19 15:43:07 GMT 2021
    - 21.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/Monitor.java

       *
       * @return whether the monitor was entered
       */
      @SuppressWarnings("GoodTime") // should accept a java.time.Duration
      public boolean enter(long time, TimeUnit unit) {
        final long timeoutNanos = toSafeNanos(time, unit);
        final ReentrantLock lock = this.lock;
        if (!fair && lock.tryLock()) {
          return true;
        }
        boolean interrupted = Thread.interrupted();
        try {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 18:22:01 GMT 2023
    - 38.6K bytes
    - Viewed (0)
  7. guava-tests/test/com/google/common/reflect/ImmutableTypeToInstanceMapTest.java

                .put(Integer.class, 0)
                .put(int.class, 1)
                .build();
        assertEquals(2, map.size());
    
        assertEquals(0, (int) map.getInstance(Integer.class));
        assertEquals(0, (int) map.getInstance(TypeToken.of(Integer.class)));
        assertEquals(1, (int) map.getInstance(int.class));
        assertEquals(1, (int) map.getInstance(TypeToken.of(int.class)));
      }
    
      public void testParameterizedType() {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:15:24 GMT 2024
    - 6.8K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/io/FileBackedOutputStreamTest.java

      }
    
      private void testThreshold(
          int fileThreshold, int dataSize, boolean singleByte, boolean resetOnFinalize)
          throws IOException {
        byte[] data = newPreFilledByteArray(dataSize);
        FileBackedOutputStream out = new FileBackedOutputStream(fileThreshold, resetOnFinalize);
        ByteSource source = out.asByteSource();
        int chunk1 = Math.min(dataSize, fileThreshold);
        int chunk2 = dataSize - chunk1;
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 5.5K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/util/concurrent/testing/TestingExecutors.java

        }
    
        @Override
        public boolean awaitTermination(long timeout, TimeUnit unit) {
          return true;
        }
    
        @Override
        public void execute(Runnable runnable) {}
    
        @Override
        public <V> ListenableScheduledFuture<V> schedule(
            Callable<V> callable, long delay, TimeUnit unit) {
          return NeverScheduledFuture.create();
        }
    
        @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri May 26 22:04:00 GMT 2023
    - 6.7K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java

      }
    
      /** get and set for out of bound indices throw IndexOutOfBoundsException */
      public void testIndexing() {
        AtomicDoubleArray aa = new AtomicDoubleArray(SIZE);
        for (int index : new int[] {-1, SIZE}) {
          assertThrows(IndexOutOfBoundsException.class, () -> aa.get(index));
          assertThrows(IndexOutOfBoundsException.class, () -> aa.set(index, 1.0));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 10K bytes
    - Viewed (0)
Back to top