Searched refs:binarySearch (Results 1 - 25 of 48) sorted by relevance

12

/external/apache-harmony/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/
H A DArraysTest.java110 * @tests java.util.Arrays#binarySearch(byte[], byte)
113 // Test for method int java.util.Arrays.binarySearch(byte [], byte)
116 Arrays.binarySearch(byteArray, counter) == counter);
118 -1, Arrays.binarySearch(intArray, (byte) -1));
121 Arrays.binarySearch(intArray, (byte) arraySize) == -(arraySize + 1));
127 Arrays.binarySearch(byteArray, (byte) (counter - 50)) == counter);
131 * @tests java.util.Arrays#binarySearch(char[], char)
134 // Test for method int java.util.Arrays.binarySearch(char [], char)
138 Arrays.binarySearch(charArray, (char) (counter + 1)) == counter);
140 -1, Arrays.binarySearch(charArra
[all...]
H A DArrays2Test.java33 * @tests java.util.Arrays#binarySearch(double[], double)
42 int result = Arrays.binarySearch(specials, specials[i]);
47 -4, Arrays.binarySearch(specials, -1d));
49 -8, Arrays.binarySearch(specials, 1d));
53 * @tests java.util.Arrays#binarySearch(float[], float)
62 int result = Arrays.binarySearch(specials, specials[i]);
67 -4, Arrays.binarySearch(specials, -1f));
69 -8, Arrays.binarySearch(specials, 1f));
368 assertEquals(0, Arrays.binarySearch(strings, "a",
370 assertEquals(0, Arrays.binarySearch(string
[all...]
H A DCollections2Test.java54 * @tests java.util.Collections#binarySearch(java.util.List,
62 int index = Collections.binarySearch(lst, new Integer(2), null);
67 * @tests java.util.Collections#binarySearch(java.util.List,
74 assertEquals(-1, Collections.binarySearch(localList, new Object()));
77 Collections.binarySearch(localList, new Integer(1));
/external/guava/guava/src/com/google/common/collect/
H A DComparatorOrdering.java44 @Override public int binarySearch(List<? extends T> sortedList, T key) { method in class:ComparatorOrdering
45 return Collections.binarySearch(sortedList, key, comparator);
H A DNaturalOrdering.java49 @Override public int binarySearch( method in class:NaturalOrdering
51 return Collections.binarySearch((List) sortedList, key);
H A DRegularImmutableSortedSet.java76 return binarySearch(o) >= 0;
128 private int binarySearch(Object key) { method in class:RegularImmutableSortedSet
129 // TODO(kevinb): split this into binarySearch(E) and
139 return Collections.binarySearch(elements, key, unsafeComparator);
203 index = SortedLists.binarySearch(
206 index = SortedLists.binarySearch(
223 index = SortedLists.binarySearch(
226 index = SortedLists.binarySearch(
258 position = SortedLists.binarySearch(elements, (E) target, comparator(),
H A DSortedLists.java169 * {@link java.util.Collections#binarySearch(List, Object)} when the key isn't present, since
186 * <p>Equivalent to {@link #binarySearch(List, Function, Object, Comparator, KeyPresentBehavior,
189 public static <E extends Comparable> int binarySearch(List<? extends E> list, E e, method in class:SortedLists
192 return binarySearch(
199 * <p>Equivalent to {@link #binarySearch(List, Function, Object, Comparator, KeyPresentBehavior,
202 public static <E, K extends Comparable> int binarySearch(List<E> list, method in class:SortedLists
205 return binarySearch(
218 * {@link #binarySearch(List, Object, Comparator, KeyPresentBehavior, KeyAbsentBehavior)} using
221 public static <E, K> int binarySearch( method in class:SortedLists
228 return binarySearch(
255 public static <E> int binarySearch(List<? extends E> list, @Nullable E key, method in class:SortedLists
[all...]
H A DRegularImmutableSortedMultiset.java144 int index = SortedLists.binarySearch(
157 index = SortedLists.binarySearch(
161 index = SortedLists.binarySearch(
175 index = SortedLists.binarySearch(
179 index = SortedLists.binarySearch(
H A DOrdering.java487 * {@link Collections#binarySearch(List, Object, Comparator) Searches}
494 public int binarySearch(List<? extends T> sortedList, @Nullable T key) { method in class:Ordering
495 return Collections.binarySearch(sortedList, key, this);
/external/smali/dexlib/src/main/java/org/jf/dexlib/Util/
H A DSparseIntArray.java64 int i = binarySearch(mKeys, 0, mSize, key);
77 int i = binarySearch(mKeys, 0, mSize, key);
99 int i = binarySearch(mKeys, 0, mSize, key);
164 return binarySearch(mKeys, 0, mSize, key);
220 private static int binarySearch(int[] a, int start, int len, int key) { method in class:SparseIntArray
H A DSparseArray.java71 int i = binarySearch(mKeys, 0, mSize, key);
84 int i = binarySearch(mKeys, 0, mSize, key);
134 int i = binarySearch(mKeys, 0, mSize, key);
151 i = ~binarySearch(mKeys, 0, mSize, key);
241 return binarySearch(mKeys, 0, mSize, key);
335 private static int binarySearch(int[] a, int start, int len, int key) { method in class:SparseArray
/external/apache-harmony/annotation/src/test/java/org/apache/harmony/annotation/tests/java/lang/annotation/
H A DRetentionPolicyTest.java58 assertTrue(Arrays.binarySearch(values, RetentionPolicy.RUNTIME) >= 0);
H A DElementTypeTest.java63 assertTrue(Arrays.binarySearch(values, ElementType.METHOD) >= 0);
/external/guava/guava-tests/test/com/google/common/collect/
H A DSortedListsTest.java102 SortedLists.binarySearch(LIST_WITHOUT_DUPS, key, presentBehavior, absentBehavior),
114 SortedLists.binarySearch(LIST_WITH_DUPS, key, presentBehavior, absentBehavior),
/external/jdiff/src/jdiff/
H A DClassDiff.java100 int idx = Collections.binarySearch(newClass.implements_, oldInterface);
113 int idx = Collections.binarySearch(oldClass.implements_, newInterface);
H A DAPIComparator.java59 int idx = Collections.binarySearch(newAPI.packages_, oldPkg);
88 int idx = Collections.binarySearch(oldAPI.packages_, newPkg);
166 int idx = Collections.binarySearch(newPkg.classes_, oldClass);
194 int idx = Collections.binarySearch(oldPkg.classes_, newClass);
374 int idx = Collections.binarySearch(newClass.ctors_, oldCtor);
423 int idx = Collections.binarySearch(oldClass.ctors_, newCtor);
474 // NOTE: there was a problem with the binarySearch for
479 // int idx = Collections.binarySearch(newClass.methods_, oldMethod);
497 // has changed, because the binarySearch did not find it.
534 // See note above about searching an array instead of binarySearch
[all...]
H A DComments.java199 int idx = Collections.binarySearch(comments.commentsList_, key);
448 int idx = Collections.binarySearch(newComments.commentsList_, oldComment);
/external/webkit/Source/JavaScriptCore/wtf/
H A DStdLibExtras.h130 inline ArrayType* binarySearch(ArrayType* array, size_t size, KeyType key) function in namespace:WTF
164 using WTF::binarySearch;
/external/replicaisland/src/com/replica/replicaisland/
H A DSpriteAnimation.java62 int index = Arrays.binarySearch(mFrameStartTimes, cycleTime);
H A DFixedSizeArray.java202 index = Arrays.binarySearch(contents, object, comparator);
204 index = Arrays.binarySearch(contents, object);
206 // Arrays.binarySearch() returns a negative insertion index if the object isn't found,
/external/webkit/Source/JavaScriptCore/dfg/
H A DDFGGraph.h97 BasicBlock* block = binarySearch<BasicBlock, unsigned, BasicBlock::getBytecodeBegin>(begin, m_blocks.size(), bytecodeBegin);
/external/libphonenumber/java/src/com/android/i18n/phonenumbers/geocoding/
H A DAreaCodeMap.java160 currentIndex = binarySearch(0, currentIndex, phonePrefix);
179 private int binarySearch(int start, int end, long value) { method in class:AreaCodeMap
/external/eclipse-basebuilder/basebuilder-3.6.2/org.eclipse.releng.basebuilder/plugins/org.eclipse.test.performance.ui/src/org/eclipse/test/internal/performance/results/db/
H A DDB_Results.java406 return Arrays.binarySearch(BUILDS, name, Util.BUILD_DATE_COMPARATOR);
597 DEFAULT_DIM_INDEX = Arrays.binarySearch(DIMENSIONS, DEFAULT_DIM.getId());
633 DEFAULT_DIM_INDEX = Arrays.binarySearch(DIMENSIONS, DEFAULT_DIM.getId());
943 return Arrays.binarySearch(CONFIGS, config);
1188 int idx = Arrays.binarySearch(BUILDS, build, Util.BUILD_DATE_COMPARATOR);
1230 int idx = Arrays.binarySearch(CONFIGS, config);
1250 int idx = Arrays.binarySearch(COMPONENTS, component);
1270 int idx = Arrays.binarySearch(DIMENSIONS, id);
1290 int idx = Arrays.binarySearch(VMS, vm);
/external/webkit/Source/JavaScriptCore/bytecode/
H A DCodeBlock.h179 // valueAtPosition helpers for the binarySearch algorithm.
250 return *(binarySearch<StructureStubInfo, void*, getStructureStubInfoReturnLocation>(m_structureStubInfos.begin(), m_structureStubInfos.size(), returnAddress.value()));
255 return *(binarySearch<CallLinkInfo, void*, getCallLinkInfoReturnLocation>(m_callLinkInfos.begin(), m_callLinkInfos.size(), returnAddress.value()));
260 return *(binarySearch<MethodCallLinkInfo, void*, getMethodCallLinkInfoReturnLocation>(m_methodCallLinkInfos.begin(), m_methodCallLinkInfos.size(), returnAddress.value()));
270 return binarySearch<CallReturnOffsetToBytecodeOffset, unsigned, getCallReturnOffset>(callIndices.begin(), callIndices.size(), getJITCode().offsetOf(returnAddress.value()))->bytecodeOffset;
/external/apache-http/src/org/apache/http/conn/ssl/
H A DAbstractVerifier.java197 int x = Arrays.binarySearch(BAD_COUNTRY_2LDS, s);

Completed in 2565 milliseconds

12