Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 458 for sizeof (0.17 sec)

  1. guava-testlib/src/com/google/common/collect/testing/SpliteratorTester.java

              format(
                  "estimated size of spliterator after trySplit (%s) is larger than original size (%s)",
                  spliterator.estimateSize(), originalSize));
        }
        if (trySplit != null) {
          if (trySplit.estimateSize() > originalSize) {
            fail(
                format(
                    "estimated size of trySplit result (%s) is larger than original size (%s)",
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 18:19:31 GMT 2024
    - 11.9K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/testers/CollectionToStringTester.java

      @CollectionFeature.Require(absent = NON_STANDARD_TOSTRING)
      public void testToString_size0() {
        assertEquals("emptyCollection.toString should return []", "[]", collection.toString());
      }
    
      @CollectionSize.Require(ONE)
      @CollectionFeature.Require(absent = NON_STANDARD_TOSTRING)
      public void testToString_size1() {
        assertEquals(
            "size1Collection.toString should return [{element}]",
            "[" + e0() + "]",
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Jan 09 20:10:38 GMT 2018
    - 3K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/ImmutableSetTest.java

        ImmutableSet.Builder<String> builder = ImmutableSet.builderWithExpectedSize(4);
        builder.add("a");
        assertEquals(1, builder.size);
        builder.add("a");
        assertEquals(1, builder.size);
        builder.add("b", "c", "d");
        assertEquals(4, builder.size);
        Object[] table = builder.hashTable;
        assertNotNull(table);
        assertSame(table, ((RegularImmutableSet<String>) builder.build()).table);
      }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 13.7K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/RegularImmutableMap.java

      // Max size is halved due to indexing into double-sized alternatingKeysAndValues
      private static final int BYTE_MAX_SIZE = 1 << (Byte.SIZE - 1); // 2^7 = 128
      private static final int SHORT_MAX_SIZE = 1 << (Short.SIZE - 1); // 2^15 = 32_768
    
      private static final int BYTE_MASK = (1 << Byte.SIZE) - 1; // 2^8 - 1 = 255
      private static final int SHORT_MASK = (1 << Short.SIZE) - 1; // 2^16 - 1 = 65_535
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Apr 15 22:32:14 GMT 2024
    - 22.7K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/HashBasedTable.java

        return new HashBasedTable<>(new LinkedHashMap<R, Map<C, V>>(), new Factory<C, V>(0));
      }
    
      /**
       * Creates an empty {@code HashBasedTable} with the specified map sizes.
       *
       * @param expectedRows the expected number of distinct row keys
       * @param expectedCellsPerRow the expected number of column key / value mappings in each row
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Jan 24 17:47:51 GMT 2022
    - 4K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/primitives/ImmutableIntArray.java

          }
          // We could delegate to super now but it would still box too much
          if (!(object instanceof List)) {
            return false;
          }
          List<?> that = (List<?>) object;
          if (this.size() != that.size()) {
            return false;
          }
          int i = parent.start;
          // Since `that` is very likely RandomAccess we could avoid allocating this iterator...
          for (Object element : that) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 16:34:24 GMT 2023
    - 18.9K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/Collections2.java

            sb.append(o);
          }
        }
        return sb.append(']').toString();
      }
    
      /** Returns best-effort-sized StringBuilder based on the given collection size. */
      static StringBuilder newStringBuilderForCollection(int size) {
        checkNonnegative(size, "size");
        return new StringBuilder((int) Math.min(size * 8L, Ints.MAX_POWER_OF_TWO));
      }
    
      /**
    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)
  8. android/guava/src/com/google/common/primitives/ImmutableDoubleArray.java

          }
          // We could delegate to super now but it would still box too much
          if (!(object instanceof List)) {
            return false;
          }
          List<?> that = (List<?>) object;
          if (this.size() != that.size()) {
            return false;
          }
          int i = parent.start;
          // Since `that` is very likely RandomAccess we could avoid allocating this iterator...
          for (Object element : that) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 16:34:24 GMT 2023
    - 19.6K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/collect/ImmutableListCreationBenchmark.java

        }
        return dummy;
      }
    
      @Benchmark
      int preSizedBuilderAdd(int reps) {
        int size = this.size;
        int dummy = 0;
        for (int rep = 0; rep < reps; rep++) {
          ImmutableList.Builder<Object> builder = new ImmutableList.Builder<>(size);
          for (int i = 0; i < size; i++) {
            builder.add(OBJECT);
          }
          dummy += builder.build().size();
        }
        return dummy;
      }
    
      @Benchmark
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.3K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java

        new NullPointerTester().testAllPublicInstanceMethods(new AtomicDoubleArray(1));
      }
    
      /** constructor creates array of given size with all elements zero */
      public void testConstructor() {
        AtomicDoubleArray aa = new AtomicDoubleArray(SIZE);
        for (int i = 0; i < SIZE; i++) {
          assertBitEquals(0.0, aa.get(i));
        }
      }
    
      /** constructor with null array throws NPE */
      public void testConstructor2NPE() {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 14.5K bytes
    - Viewed (0)
Back to top