Search Options

Results per page
Sort
Preferred Languages
Advance

Results 71 - 80 of 177 for dcast (0.05 sec)

  1. android/guava-tests/test/com/google/common/reflect/ImmutableTypeToInstanceMapTest.java

        ImmutableTypeToInstanceMap<Iterable<?>[]> map =
            ImmutableTypeToInstanceMap.<Iterable<?>[]>builder().put(type, array).build();
        assertEquals(1, map.size());
        // Redundant cast works around a javac bug.
        assertThat((Iterable<?>[]) map.getInstance(type)).asList().containsExactly(array[0]);
      }
    
      public void testWildcardType() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Feb 22 17:15:24 UTC 2024
    - 6.8K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/Tables.java

        @Override
        @CheckForNull
        public V2 get(@CheckForNull Object rowKey, @CheckForNull Object columnKey) {
          // The function is passed a null input only when the table contains a null
          // value.
          // The cast is safe because of the contains() check.
          return contains(rowKey, columnKey)
              ? function.apply(uncheckedCastNullableTToT(fromTable.get(rowKey, columnKey)))
              : null;
        }
    
        @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 16 21:21:17 UTC 2024
    - 26.3K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/primitives/IntArrayAsListTest.java

    import junit.framework.TestCase;
    import junit.framework.TestSuite;
    
    /**
     * Test suite covering {@link Ints#asList(int[])}.
     *
     * @author Kevin Bourrillion
     */
    @GwtCompatible(emulated = true)
    @SuppressWarnings("cast") // redundant casts are intentional and harmless
    public class IntArrayAsListTest extends TestCase {
    
      private static List<Integer> asList(Integer[] values) {
        int[] temp = new int[values.length];
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Jun 01 09:32:35 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/Platform.java

       *
       * - https://github.com/jspecify/jspecify/issues/65
       *
       * - https://github.com/jspecify/jdk/commit/71d826792b8c7ef95d492c50a274deab938f2552
       */
      /*
       * TODO(cpovirk): Is the unchecked cast avoidable? Would System.arraycopy be similarly fast (if
       * likewise not type-checked)? Could our single caller do something different?
       */
      @SuppressWarnings({"nullness", "unchecked"})
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 06 17:52:51 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  5. guava/src/com/google/common/graph/StandardValueGraph.java

          Map<N, GraphConnections<N, V>> nodeConnections,
          long edgeCount) {
        this.isDirected = builder.directed;
        this.allowsSelfLoops = builder.allowsSelfLoops;
        this.nodeOrder = builder.nodeOrder.cast();
        // Prefer the heavier "MapRetrievalCache" for nodes if lookup is expensive.
        this.nodeConnections =
            (nodeConnections instanceof TreeMap)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Jan 22 17:29:38 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/Platform.java

       *
       * - https://github.com/jspecify/jspecify/issues/65
       *
       * - https://github.com/jspecify/jdk/commit/71d826792b8c7ef95d492c50a274deab938f2552
       */
      /*
       * TODO(cpovirk): Is the unchecked cast avoidable? Would System.arraycopy be similarly fast (if
       * likewise not type-checked)? Could our single caller do something different?
       */
      @SuppressWarnings({"nullness", "unchecked"})
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 06 17:52:51 UTC 2024
    - 5.5K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/cache/AbstractCache.java

       *
       * <p>This implementation of {@code getAllPresent} lacks any insight into the internal cache data
       * structure, and is thus forced to return the query keys instead of the cached keys. This is only
       * possible with an unsafe cast which requires {@code keys} to actually be of type {@code K}.
       *
       * @since 11.0
       */
      /*
       * <? extends Object> is mostly the same as <?> to plain Java. But to nullness checkers, they
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jun 15 18:00:07 UTC 2021
    - 9.1K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/base/PreconditionsTest.java

        // With a boxed predicate, no overloads can be selected in phase 1
        // ambiguous without the call to .booleanValue to unbox the Boolean
        checkState(boxedBoolean.booleanValue(), "", 1);
        // ambiguous without the cast to Object because the boxed predicate prevents any overload from
        // being selected in phase 1
        checkState(boxedBoolean, "", (Object) boxedLong);
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Sep 17 18:14:12 UTC 2024
    - 19K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/google/SetGenerators.java

        }
      }
    
      public static class DegeneratedImmutableSetGenerator extends TestStringSetGenerator {
        // Make sure we get what we think we're getting, or else this test
        // is pointless
        @SuppressWarnings("cast")
        @Override
        protected Set<String> create(String[] elements) {
          return (ImmutableSet<String>) ImmutableSet.of(elements[0], elements[0]);
        }
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 15.6K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/graph/ElementOrder.java

          case SORTED:
            return Maps.newTreeMap(comparator());
        }
        throw new AssertionError();
      }
    
      @SuppressWarnings("unchecked")
      <T1 extends T> ElementOrder<T1> cast() {
        return (ElementOrder<T1>) this;
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 16 17:21:56 UTC 2024
    - 6.7K bytes
    - Viewed (0)
Back to top