Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for safeContains (0.07 sec)

  1. android/guava/src/com/google/common/collect/AbstractTable.java

          if (o instanceof Cell) {
            Cell<?, ?, ?> cell = (Cell<?, ?, ?>) o;
            Map<C, V> row = safeGet(rowMap(), cell.getRowKey());
            return row != null
                && Collections2.safeContains(
                    row.entrySet(), immutableEntry(cell.getColumnKey(), cell.getValue()));
          }
          return false;
        }
    
        @Override
        public boolean remove(@Nullable Object o) {
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Sat Aug 09 01:14:59 UTC 2025
    - 6K bytes
    - Viewed (0)
  2. guava/src/com/google/common/collect/AbstractTable.java

          if (o instanceof Cell) {
            Cell<?, ?, ?> cell = (Cell<?, ?, ?>) o;
            Map<C, V> row = safeGet(rowMap(), cell.getRowKey());
            return row != null
                && Collections2.safeContains(
                    row.entrySet(), immutableEntry(cell.getColumnKey(), cell.getValue()));
          }
          return false;
        }
    
        @Override
        public boolean remove(@Nullable Object o) {
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 6.7K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/Collections2.java

      }
    
      /**
       * Delegates to {@link Collection#contains}. Returns {@code false} if the {@code contains} method
       * throws a {@code ClassCastException} or {@code NullPointerException}.
       */
      static boolean safeContains(Collection<?> collection, @Nullable Object object) {
        checkNotNull(collection);
        try {
          return collection.contains(object);
        } catch (ClassCastException | NullPointerException e) {
          return false;
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Sat Aug 09 01:14:59 UTC 2025
    - 22.6K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/ConcurrentHashMultiset.java

          @Override
          protected Set<E> delegate() {
            return delegate;
          }
    
          @Override
          public boolean contains(@Nullable Object object) {
            return object != null && Collections2.safeContains(delegate, object);
          }
    
          @Override
          public boolean containsAll(Collection<?> collection) {
            return standardContainsAll(collection);
          }
    
          @Override
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Dec 08 22:42:14 UTC 2025
    - 22.3K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/AbstractMapBasedMultimap.java

          }
    
          // The following methods are included for performance.
    
          @Override
          public boolean contains(@Nullable Object o) {
            return Collections2.safeContains(submap.entrySet(), o);
          }
    
          @Override
          public boolean remove(@Nullable Object o) {
            if (!contains(o)) {
              return false;
            }
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 48.4K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/Iterables.java

       */
      public static boolean contains(Iterable<?> iterable, @Nullable Object element) {
        if (iterable instanceof Collection) {
          Collection<?> collection = (Collection<?>) iterable;
          return Collections2.safeContains(collection, element);
        }
        return Iterators.contains(iterable.iterator(), element);
      }
    
      /**
       * Removes, from an iterable, every element that belongs to the provided collection.
       *
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 16 18:35:28 UTC 2025
    - 43.8K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/Iterables.java

       */
      public static boolean contains(Iterable<?> iterable, @Nullable Object element) {
        if (iterable instanceof Collection) {
          Collection<?> collection = (Collection<?>) iterable;
          return Collections2.safeContains(collection, element);
        }
        return Iterators.contains(iterable.iterator(), element);
      }
    
      /**
       * Removes, from an iterable, every element that belongs to the provided collection.
       *
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 43.6K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/Maps.java

          return getOrDefault(key, null);
        }
    
        @Override
        public @Nullable V getOrDefault(@Nullable Object key, @Nullable V defaultValue) {
          if (Collections2.safeContains(backingSet(), key)) {
            @SuppressWarnings("unchecked") // unsafe, but Javadoc warns about it
            K k = (K) key;
            return function.apply(k);
          } else {
            return defaultValue;
          }
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Nov 17 22:50:48 UTC 2025
    - 163.5K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/Maps.java

        @Override
        public boolean containsKey(@Nullable Object key) {
          return backingSet().contains(key);
        }
    
        @Override
        public @Nullable V get(@Nullable Object key) {
          if (Collections2.safeContains(backingSet(), key)) {
            @SuppressWarnings("unchecked") // unsafe, but Javadoc warns about it
            K k = (K) key;
            return function.apply(k);
          } else {
            return null;
          }
        }
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 23 17:50:58 UTC 2025
    - 157.6K bytes
    - Viewed (0)
Back to top