Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for safeContains (0.23 sec)

  1. 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, @CheckForNull Object object) {
        checkNotNull(collection);
        try {
          return collection.contains(object);
        } catch (ClassCastException | NullPointerException e) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 22.8K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/AbstractTable.java

          if (o instanceof Cell) {
            Cell<?, ?, ?> cell = (Cell<?, ?, ?>) o;
            Map<C, V> row = Maps.safeGet(rowMap(), cell.getRowKey());
            return row != null
                && Collections2.safeContains(
                    row.entrySet(), Maps.immutableEntry(cell.getColumnKey(), cell.getValue()));
          }
          return false;
        }
    
        @Override
        public boolean remove(@CheckForNull Object o) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Jul 15 15:41:16 GMT 2021
    - 6.1K bytes
    - Viewed (0)
  3. 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, @CheckForNull Object object) {
        checkNotNull(collection);
        try {
          return collection.contains(object);
        } catch (ClassCastException | NullPointerException e) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 23.1K bytes
    - Viewed (0)
  4. guava/src/com/google/common/collect/AbstractTable.java

          if (o instanceof Cell) {
            Cell<?, ?, ?> cell = (Cell<?, ?, ?>) o;
            Map<C, V> row = Maps.safeGet(rowMap(), cell.getRowKey());
            return row != null
                && Collections2.safeContains(
                    row.entrySet(), Maps.immutableEntry(cell.getColumnKey(), cell.getValue()));
          }
          return false;
        }
    
        @Override
        public boolean remove(@CheckForNull Object o) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Jul 15 15:41:16 GMT 2021
    - 6.5K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/ConcurrentHashMultiset.java

          @Override
          protected Set<E> delegate() {
            return delegate;
          }
    
          @Override
          public boolean contains(@CheckForNull Object object) {
            return object != null && Collections2.safeContains(delegate, object);
          }
    
          @Override
          public boolean containsAll(Collection<?> collection) {
            return standardContainsAll(collection);
          }
    
          @Override
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/StandardTable.java

            if (obj instanceof Entry) {
              Entry<?, ?> entry = (Entry<?, ?>) obj;
              return entry.getKey() != null
                  && entry.getValue() instanceof Map
                  && Collections2.safeContains(backingMap.entrySet(), entry);
            }
            return false;
          }
    
          @Override
          public boolean remove(@CheckForNull Object obj) {
            if (obj instanceof Entry) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Oct 13 14:11:58 GMT 2023
    - 29.8K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/ConcurrentHashMultiset.java

          @Override
          protected Set<E> delegate() {
            return delegate;
          }
    
          @Override
          public boolean contains(@CheckForNull Object object) {
            return object != null && Collections2.safeContains(delegate, object);
          }
    
          @Override
          public boolean containsAll(Collection<?> collection) {
            return standardContainsAll(collection);
          }
    
          @Override
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/AbstractMapBasedMultimap.java

          }
    
          // The following methods are included for performance.
    
          @Override
          public boolean contains(@CheckForNull Object o) {
            return Collections2.safeContains(submap.entrySet(), o);
          }
    
          @Override
          public boolean remove(@CheckForNull Object o) {
            if (!contains(o)) {
              return false;
            }
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Fri Oct 13 14:11:58 GMT 2023
    - 48K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/Iterables.java

          Iterable<? extends @Nullable Object> iterable, @CheckForNull 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.
       *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Apr 24 19:38:27 GMT 2024
    - 42.8K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/AbstractMapBasedMultimap.java

          }
    
          // The following methods are included for performance.
    
          @Override
          public boolean contains(@CheckForNull Object o) {
            return Collections2.safeContains(submap.entrySet(), o);
          }
    
          @Override
          public boolean remove(@CheckForNull Object o) {
            if (!contains(o)) {
              return false;
            }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Oct 13 14:11:58 GMT 2023
    - 46.6K bytes
    - Viewed (0)
Back to top