Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 681 for Barray (0.17 sec)

  1. guava-tests/benchmark/com/google/common/math/LongMathRoundingBenchmark.java

      RoundingMode mode;
    
      private static final long[] positive = new long[ARRAY_SIZE];
      private static final long[] nonzero = new long[ARRAY_SIZE];
      private static final long[] longs = new long[ARRAY_SIZE];
    
      @BeforeExperiment
      void setUp() {
        for (int i = 0; i < ARRAY_SIZE; i++) {
          positive[i] = randomPositiveBigInteger(Long.SIZE - 2).longValue();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.6K bytes
    - Viewed (0)
  2. android/guava-tests/benchmark/com/google/common/math/BigIntegerMathBenchmark.java

    public class BigIntegerMathBenchmark {
      private static final int[] factorials = new int[ARRAY_SIZE];
      private static final int[] slowFactorials = new int[ARRAY_SIZE];
      private static final int[] binomials = new int[ARRAY_SIZE];
    
      @Param({"50", "1000", "10000"})
      int factorialBound;
    
      @BeforeExperiment
      void setUp() {
        for (int i = 0; i < ARRAY_SIZE; i++) {
          factorials[i] = RANDOM_SOURCE.nextInt(factorialBound);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.3K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/collect/testing/AbstractMapTester.java

        }
      }
    
      /** @return an array of the proper size with {@code null} as the key of the middle element. */
      protected Entry<K, V>[] createArrayWithNullKey() {
        Entry<K, V>[] array = createSamplesArray();
        int nullKeyLocation = getNullLocation();
        Entry<K, V> oldEntry = array[nullKeyLocation];
        array[nullKeyLocation] = entry(null, oldEntry.getValue());
        return array;
      }
    
      protected V getValueForNullKey() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 7.5K bytes
    - Viewed (0)
  4. guava-tests/benchmark/com/google/common/collect/HashMultisetAddPresentBenchmark.java

    public class HashMultisetAddPresentBenchmark {
      private static final int ARRAY_MASK = 0x0ffff;
      private static final int ARRAY_SIZE = 0x10000;
      List<Multiset<Integer>> multisets = new ArrayList<>(0x10000);
      int[] queries = new int[ARRAY_SIZE];
    
      @BeforeExperiment
      void setUp() {
        Random random = new Random();
        multisets.clear();
        for (int i = 0; i < ARRAY_SIZE; i++) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.6K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/AtomicsTest.java

      public void testNewReferenceArray_withStringArray() throws Exception {
        String[] array = {"foo", "bar", "baz"};
        AtomicReferenceArray<String> refArray = Atomics.newReferenceArray(array);
        for (int i = 0; i < array.length; ++i) {
          assertEquals(array[i], refArray.get(i));
        }
        assertThrows(IndexOutOfBoundsException.class, () -> refArray.get(array.length));
      }
    
      public void testNewReferenceArray_withNullArray() throws Exception {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 2.5K bytes
    - Viewed (1)
  6. android/guava-tests/test/com/google/common/util/concurrent/AtomicsTest.java

      public void testNewReferenceArray_withStringArray() throws Exception {
        String[] array = {"foo", "bar", "baz"};
        AtomicReferenceArray<String> refArray = Atomics.newReferenceArray(array);
        for (int i = 0; i < array.length; ++i) {
          assertEquals(array[i], refArray.get(i));
        }
        assertThrows(IndexOutOfBoundsException.class, () -> refArray.get(array.length));
      }
    
      public void testNewReferenceArray_withNullArray() throws Exception {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 2.5K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/collect/testing/testers/CollectionCreationTester.java

      public void testCreateWithNull_supported() {
        E[] array = createArrayWithNullElement();
        collection = getSubjectGenerator().create(array);
        expectContents(array);
      }
    
      @CollectionFeature.Require(absent = ALLOWS_NULL_VALUES)
      @CollectionSize.Require(absent = ZERO)
      public void testCreateWithNull_unsupported() {
        E[] array = createArrayWithNullElement();
    
        try {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 2.9K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/collect/RegularImmutableSet.java

    @ElementTypesAreNonnullByDefault
    final class RegularImmutableSet<E> extends ImmutableSet<E> {
      private static final Object[] EMPTY_ARRAY = new Object[0];
      static final RegularImmutableSet<Object> EMPTY =
          new RegularImmutableSet<>(EMPTY_ARRAY, 0, EMPTY_ARRAY, 0, 0);
    
      // The first `size` elements are non-null.
      @VisibleForTesting final transient @Nullable Object[] elements;
      private final transient int hashCode;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 3.7K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/TestStringQueueGenerator.java

        return new Strings();
      }
    
      @Override
      public Queue<String> create(Object... elements) {
        String[] array = new String[elements.length];
        int i = 0;
        for (Object e : elements) {
          array[i++] = (String) e;
        }
        return create(array);
      }
    
      protected abstract Queue<String> create(String[] elements);
    
      @Override
      public String[] createArray(int length) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 1.6K bytes
    - Viewed (0)
  10. guava-testlib/src/com/google/common/collect/testing/TestStringListGenerator.java

        return new Strings();
      }
    
      @Override
      public List<String> create(Object... elements) {
        String[] array = new String[elements.length];
        int i = 0;
        for (Object e : elements) {
          array[i++] = (String) e;
        }
        return create(array);
      }
    
      /**
       * Creates a new collection containing the given elements; implement this method instead of {@link
       * #create(Object...)}.
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 1.7K bytes
    - Viewed (0)
Back to top