Search Options

Results per page
Sort
Preferred Languages
Advance

Results 151 - 160 of 195 for index (0.1 sec)

  1. android/guava-tests/test/com/google/common/io/ByteSourceTest.java

        source.append(newPreFilledByteArray(5, 10));
    
        // The stream reports no bytes... importantly, it doesn't read the byte at index 5 when it
        // should be reading the byte at index 10.
        // We could use a custom InputStream instead to make the read start at index 10, but since this
        // is a racy situation anyway, this behavior seems reasonable.
        assertEquals(-1, in.read());
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue May 07 15:26:58 UTC 2024
    - 15.4K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/testers/ListSubListTester.java

        assertEquals(list.get(0), head.get(0));
        assertEquals(list.get(size - 2), head.get(size - 2));
        for (List<E> subList : Arrays.asList(copy, head, tail)) {
          for (int index : Arrays.asList(-1, subList.size())) {
            try {
              subList.get(index);
              fail("expected IndexOutOfBoundsException");
            } catch (IndexOutOfBoundsException expected) {
            }
          }
        }
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 21 16:49:06 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/collect/testing/testers/ListSubListTester.java

        assertEquals(list.get(0), head.get(0));
        assertEquals(list.get(size - 2), head.get(size - 2));
        for (List<E> subList : Arrays.asList(copy, head, tail)) {
          for (int index : Arrays.asList(-1, subList.size())) {
            try {
              subList.get(index);
              fail("expected IndexOutOfBoundsException");
            } catch (IndexOutOfBoundsException expected) {
            }
          }
        }
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 21 16:49:06 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/collect/OrderingTest.java

        AT5(5),
        ;
    
        final int index;
    
        CharAtFunction(int index) {
          this.index = index;
        }
    
        @Override
        public Character apply(String string) {
          return string.charAt(index);
        }
      }
    
      private static Ordering<String> byCharAt(int index) {
        return Ordering.<Character>natural().onResultOf(CharAtFunction.values()[index]);
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Mar 07 18:34:03 UTC 2024
    - 42.5K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/collect/Iterators.java

             * of the array becomes null only when we iterate past it and then clear it.
             */
            I result = requireNonNull(elements[index]);
            elements[index] = null;
            index++;
            return result;
          }
        };
      }
    
      /**
       * Combines two iterators into a single iterator. The returned iterator iterates across the
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 03 14:46:32 UTC 2024
    - 50.2K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/Iterators.java

             * of the array becomes null only when we iterate past it and then clear it.
             */
            I result = requireNonNull(elements[index]);
            elements[index] = null;
            index++;
            return result;
          }
        };
      }
    
      /**
       * Combines two iterators into a single iterator. The returned iterator iterates across the
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 03 14:46:32 UTC 2024
    - 50.2K bytes
    - Viewed (0)
  7. guava/src/com/google/common/collect/RegularImmutableBiMap.java

          }
    
          @Override
          ImmutableList<Entry<V, K>> createAsList() {
            return new ImmutableAsList<Entry<V, K>>() {
              @Override
              public Entry<V, K> get(int index) {
                Entry<K, V> entry = entries[index];
                return Maps.immutableEntry(entry.getValue(), entry.getKey());
              }
    
              @Override
              ImmutableCollection<Entry<V, K>> delegateCollection() {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 22 21:19:52 UTC 2024
    - 11.2K bytes
    - Viewed (0)
  8. android/guava-testlib/src/com/google/common/collect/testing/testers/AbstractListTester.java

          E expected = expectedList.get(i);
          E actual = getList().get(i);
          if (expected != actual && (expected == null || !expected.equals(actual))) {
            fail("mismatch at index " + i + ": " + reportContext(expectedList));
          }
        }
      }
    
      /**
       * Used to delay string formatting until actually required, as it otherwise shows up in the test
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 21 16:49:06 UTC 2024
    - 2.8K bytes
    - Viewed (0)
  9. guava/src/com/google/common/collect/RegularImmutableSet.java

      private final transient int hashCode;
      // the same values as `elements` in hashed positions (plus nulls)
      @VisibleForTesting final transient @Nullable Object[] table;
      // 'and' with an int to get a valid table index.
      private final transient int mask;
    
      RegularImmutableSet(Object[] elements, int hashCode, @Nullable Object[] table, int mask) {
        this.elements = elements;
        this.hashCode = hashCode;
        this.table = table;
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 22 21:19:52 UTC 2024
    - 3.9K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/base/JoinerTest.java

      }
    
      private static class DontStringMeBro implements CharSequence {
        @Override
        public int length() {
          return 3;
        }
    
        @Override
        public char charAt(int index) {
          return "foo".charAt(index);
        }
    
        @Override
        public CharSequence subSequence(int start, int end) {
          return "foo".subSequence(start, end);
        }
    
        @Override
        public String toString() {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri Feb 09 15:49:48 UTC 2024
    - 12.6K bytes
    - Viewed (0)
Back to top