Searched refs:iterable (Results 1 - 19 of 19) sorted by relevance

/external/guava/src/com/google/common/collect/
H A DIterables.java56 /** Returns an unmodifiable view of {@code iterable}. */
57 public static <T> Iterable<T> unmodifiableIterable(final Iterable<T> iterable) argument
59 checkNotNull(iterable);
62 return Iterators.unmodifiableIterator(iterable.iterator());
65 return iterable.toString();
72 * Returns the number of elements in {@code iterable}.
74 public static int size(Iterable<?> iterable) { argument
75 return (iterable instanceof Collection)
76 ? ((Collection<?>) iterable).size()
77 : Iterators.size(iterable
84 contains(Iterable<?> iterable, @Nullable Object element) argument
200 toString(Iterable<?> iterable) argument
211 getOnlyElement(Iterable<T> iterable) argument
222 getOnlyElement( Iterable<T> iterable, @Nullable T defaultValue) argument
236 toArray(Iterable<? extends T> iterable, Class<T> type) argument
267 frequency(Iterable<?> iterable, @Nullable Object element) argument
294 cycle(final Iterable<T> iterable) argument
457 partition( final Iterable<T> iterable, final int size) argument
485 paddedPartition( final Iterable<T> iterable, final int size) argument
538 any( Iterable<T> iterable, Predicate<? super T> predicate) argument
547 all( Iterable<T> iterable, Predicate<? super T> predicate) argument
559 find(Iterable<T> iterable, Predicate<? super T> predicate) argument
575 indexOf( Iterable<T> iterable, Predicate<? super T> predicate) argument
607 get(Iterable<T> iterable, int position) argument
633 getLast(Iterable<T> iterable) argument
663 consumingIterable(final Iterable<T> iterable) argument
718 isEmpty(Iterable<T> iterable) argument
742 remove(Iterable<?> iterable, @Nullable Object o) argument
[all...]
H A DReverseNaturalOrdering.java56 @Override public <E extends Comparable> E min(Iterable<E> iterable) { argument
57 return NaturalOrdering.INSTANCE.max(iterable);
68 @Override public <E extends Comparable> E max(Iterable<E> iterable) { argument
69 return NaturalOrdering.INSTANCE.min(iterable);
H A DReverseOrdering.java54 @Override public <E extends T> E min(Iterable<E> iterable) { argument
55 return forwardOrder.max(iterable);
66 @Override public <E extends T> E max(Iterable<E> iterable) { argument
67 return forwardOrder.min(iterable);
H A DOrdering.java264 * the {@code comparators} iterable at the time it was provided to this
334 * order". If the end of one iterable is reached, but not the other, the
335 * shorter iterable is considered to be less than the longer one. For example,
395 * Returns a copy of the given iterable sorted by this ordering. The input is
403 * @param iterable the elements to be copied and sorted
406 public <E extends T> List<E> sortedCopy(Iterable<E> iterable) { argument
407 List<E> list = Lists.newArrayList(iterable);
413 * Returns {@code true} if each element in {@code iterable} after the first is
415 * ordering. Note that this is always true when the iterable has fewer than
418 public boolean isOrdered(Iterable<? extends T> iterable) { argument
439 isStrictlyOrdered(Iterable<? extends T> iterable) argument
463 max(Iterable<E> iterable) argument
523 min(Iterable<E> iterable) argument
[all...]
H A DComparatorOrdering.java48 @Override public <E extends T> List<E> sortedCopy(Iterable<E> iterable) { argument
49 List<E> list = Lists.newArrayList(iterable);
H A DNaturalOrdering.java58 Iterable<E> iterable) {
59 List<E> list = Lists.newArrayList(iterable);
57 sortedCopy( Iterable<E> iterable) argument
H A DCollections2.java71 * Converts an iterable into a collection. If the iterable is already a
73 * created with the contents of the iterable in the same iteration order.
75 static <E> Collection<E> toCollection(Iterable<E> iterable) { argument
76 return (iterable instanceof Collection)
77 ? (Collection<E>) iterable : Lists.newArrayList(iterable);
H A DImmutableSortedSet.java383 private static <T> Object[] newObjectArray(Iterable<T> iterable) { argument
384 Collection<T> collection = (iterable instanceof Collection)
385 ? (Collection<T>) iterable : Lists.newArrayList(iterable);
H A DImmutableSet.java253 Iterable<? extends E> iterable, int count) {
254 // count is always the (nonzero) number of elements in the iterable
262 for (E element : iterable) {
281 // The iterable contained only duplicates of the same element.
284 // Resize the table when the iterable includes too many duplicates.
252 create( Iterable<? extends E> iterable, int count) argument
H A DIterators.java361 * iterable}.
365 * element, which is no longer in {@code iterable}. The iterator's
366 * {@code hasNext()} method returns {@code true} until {@code iterable} is
373 public static <T> Iterator<T> cycle(final Iterable<T> iterable) { argument
374 checkNotNull(iterable);
381 iterator = iterable.iterator();
559 * iterator} divided into partitions (the final iterable may have
H A DSets.java116 * exception on an empty collection, and it may be called on any iterable, not
119 public static <E extends Enum<E>> EnumSet<E> newEnumSet(Iterable<E> iterable, argument
125 * iterable is null but elementType is not, noneOf() will throw a
131 * elementType, the problem argument, is harmful, while checking iterable,
134 checkNotNull(iterable);
136 Iterables.addAll(set, iterable);
/external/webkit/WebKitTools/Scripts/webkitpy/commands/
H A Dopenbugs.py51 def _find_bugs_in_iterable(self, iterable):
52 return sum([self._find_bugs_in_string(string) for string in iterable], [])
/external/webkit/WebKitTools/simplejson/
H A D__init__.py153 iterable = _default_encoder.iterencode(obj)
157 iterable = cls(skipkeys=skipkeys, ensure_ascii=ensure_ascii,
162 for chunk in iterable:
/external/guava/src/com/google/common/base/
H A DJoiner.java113 return appendTo(appendable, iterable(first, second, rest));
149 return appendTo(builder, iterable(first, second, rest));
174 return join(iterable(first, second, rest));
323 private static Iterable<Object> iterable( method in class:Joiner
H A DPredicates.java96 * predicate is found. It defensively copies the iterable passed in, so future
135 * true predicate is found. It defensively copies the iterable passed in, so
548 static <T> List<T> defensiveCopy(Iterable<T> iterable) { argument
550 for (T element : iterable) {
/external/webkit/WebKitTools/Scripts/webkitpy/layout_tests/layout_package/
H A Dtest_expectations.py330 iterable = [x + "\n" for x in
334 if iterable[-1] == "\n":
335 return iterable[:-1]
336 return iterable
606 """For each test in an expectations iterable, generate the
/external/webkit/SunSpider/tests/parse-only/
H A Dprototype-1.6.0.3.js812 function $A(iterable) {
813 if (!iterable) return [];
814 if (iterable.toArray) return iterable.toArray();
815 var length = iterable.length || 0, results = new Array(length);
816 while (length--) results[length] = iterable[length];
821 $A = function(iterable) {
822 if (!iterable) return [];
826 if (!(typeof iterable === 'function' && typeof iterable
[all...]
H A Dconcat-jquery-mootools-prototype.js4532 function $A(iterable){
4533 if (iterable.item){
4534 var l = iterable.length, array = new Array(l);
4535 while (l--) array[l] = iterable[l];
4538 return Array.prototype.slice.call(iterable);
4561 function $each(iterable, fn, bind){
4562 var type = $type(iterable);
4563 ((type == 'arguments' || type == 'collection' || type == 'array') ? Array : Hash).each(iterable, fn, bind);
9191 function $A(iterable) {
9192 if (!iterable) retur
[all...]
H A Dmootools-1.2.2-core-nc.js156 function $A(iterable){
157 if (iterable.item){
158 var l = iterable.length, array = new Array(l);
159 while (l--) array[l] = iterable[l];
162 return Array.prototype.slice.call(iterable);
185 function $each(iterable, fn, bind){
186 var type = $type(iterable);
187 ((type == 'arguments' || type == 'collection' || type == 'array') ? Array : Hash).each(iterable, fn, bind);

Completed in 116 milliseconds