Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 70 for items (0.15 sec)

  1. android/guava-tests/test/com/google/common/collect/MultisetsCollectionTest.java

            }
            if (elements.length > 1) {
              /*
               * When a test requests a multiset with duplicates, our plan of
               * "add an extra item 0 to A and an extra item 1 to B" really means
               * "add an extra item 0 to A and B," which isn't what we want.
               */
              if (!Objects.equal(elements[0], elements[1])) {
                multiset2.add(elements[1], 2);
              }
            }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 9.3K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/google/MapGenerators.java

              mapEntry("five", collectionOf(5)));
        }
    
        // javac7 can't infer the type parameters correctly in samples()
        private static Collection<Integer> collectionOf(int item) {
          return ImmutableSet.of(item);
        }
    
        @Override
        public Map<String, Collection<Integer>> create(Object... elements) {
          ImmutableMap.Builder<String, Integer> builder = ImmutableMap.builder();
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Feb 26 19:46:10 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  3. guava/src/com/google/common/collect/FluentIterable.java

        checkNotNull(collection);
        Iterable<E> iterable = getDelegate();
        if (iterable instanceof Collection) {
          collection.addAll((Collection<E>) iterable);
        } else {
          for (E item : iterable) {
            collection.add(item);
          }
        }
        return collection;
      }
    
      /**
       * Returns a {@link String} containing all of the elements of this fluent iterable joined with
       * {@code joiner}.
       *
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Tue Jan 30 00:14:39 GMT 2024
    - 35.3K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/primitives/BytesTest.java

        list.set(0, (byte) 4);
        assertThat(newArray).isEqualTo(new byte[] {(byte) 0, (byte) 1, (byte) 2});
        newArray[1] = (byte) 5;
        assertThat((byte) list.get(1)).isEqualTo((byte) 1);
      }
    
      // This test stems from a real bug found by andrewk
      public void testAsList_subList_toArray_roundTrip() {
        byte[] array = {(byte) 0, (byte) 1, (byte) 2, (byte) 3};
        List<Byte> list = Bytes.asList(array);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 06 16:10:08 GMT 2024
    - 16.4K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/primitives/ImmutableLongArray.java

     *
     * <p>Advantages compared to {@code long[]}:
     *
     * <ul>
     *   <li>All the many well-known advantages of immutability (read <i>Effective Java</i>, third
     *       edition, Item 17).
     *   <li>Has the value-based (not identity-based) {@link #equals}, {@link #hashCode}, and {@link
     *       #toString} behavior you expect.
    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)
  6. guava-tests/test/com/google/common/primitives/IntsTest.java

        list.set(0, (int) 4);
        assertThat(newArray).isEqualTo(new int[] {(int) 0, (int) 1, (int) 2});
        newArray[1] = (int) 5;
        assertThat((int) list.get(1)).isEqualTo((int) 1);
      }
    
      // This test stems from a real bug found by andrewk
      public void testAsList_subList_toArray_roundTrip() {
        int[] array = {(int) 0, (int) 1, (int) 2, (int) 3};
        List<Integer> list = Ints.asList(array);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 06 16:10:08 GMT 2024
    - 28.4K bytes
    - Viewed (0)
  7. guava-tests/test/com/google/common/primitives/CharsTest.java

        list.set(0, (char) 4);
        assertThat(newArray).isEqualTo(new char[] {(char) 0, (char) 1, (char) 2});
        newArray[1] = (char) 5;
        assertThat((char) list.get(1)).isEqualTo((char) 1);
      }
    
      // This test stems from a real bug found by andrewk
      public void testAsList_subList_toArray_roundTrip() {
        char[] array = {(char) 0, (char) 1, (char) 2, (char) 3};
        List<Character> list = Chars.asList(array);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 24.7K bytes
    - Viewed (0)
  8. guava/src/com/google/common/collect/Iterables.java

       * Queue#isEmpty} and {@link Queue#remove()}, since {@link Queue}'s iteration order is undefined.
       * Calling {@link Iterator#hasNext()} on a generated iterator from the returned iterable may cause
       * an item to be immediately dequeued for return on a subsequent call to {@link Iterator#next()}.
       *
       * <p>Whether the input {@code iterable} is a {@link Queue} or not, the returned {@code Iterable}
       * is not thread-safe.
       *
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 42.5K bytes
    - Viewed (0)
  9. android/guava-tests/benchmark/com/google/common/util/concurrent/MonitorBasedPriorityBlockingQueue.java

            monitor.leave();
          }
        }
      }
    
      /**
       * Saves the state to a stream (that is, serializes it). This merely wraps default serialization
       * within the monitor. The serialization strategy for items is left to underlying Queue. Note that
       * locking is not needed on deserialization, so readObject is not defined, just relying on
       * default.
       */
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Apr 19 19:24:36 GMT 2023
    - 19.5K bytes
    - Viewed (0)
  10. guava-testlib/src/com/google/common/testing/ClassSanityTester.java

        // Each group is a List of items, each item has a list of factory args.
        final List<List<List<Object>>> argGroups = Lists.newArrayList();
        argGroups.add(ImmutableList.of(args, equalArgs));
        EqualsTester tester =
            new EqualsTester(
                new ItemReporter() {
                  @Override
                  String reportItem(Item<?> item) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 08 17:31:55 GMT 2024
    - 33K bytes
    - Viewed (0)
Back to top