Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(90)

Side by Side Diff: dart/sdk/lib/core/list.dart

Issue 12296011: Version 0.3.7.4 (Closed) Base URL: http://dart.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « dart/sdk/lib/core/iterable.dart ('k') | dart/sdk/lib/core/string_buffer.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of dart.core; 5 part of dart.core;
6 6
7 /** 7 /**
8 * A [List] is an indexable collection with a length. It can be of 8 * A [List] is an indexable collection with a length. It can be of
9 * fixed size or extendable. 9 * fixed size or extendable.
10 */ 10 */
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 void addLast(E value); 70 void addLast(E value);
71 71
72 /** 72 /**
73 * Appends all elements of the [iterable] to the end of this list. 73 * Appends all elements of the [iterable] to the end of this list.
74 * Extends the length of the list by the number of elements in [iterable]. 74 * Extends the length of the list by the number of elements in [iterable].
75 * Throws an [UnsupportedError] if this list is not extensible. 75 * Throws an [UnsupportedError] if this list is not extensible.
76 */ 76 */
77 void addAll(Iterable<E> iterable); 77 void addAll(Iterable<E> iterable);
78 78
79 /** 79 /**
80 * Returns a reversed fixed-length view of this [List]. 80 * Returns an [Iterable] of the elements of this [List] in reverse order.
81 *
82 * The reversed list has elements in the opposite order of this list.
83 * It is backed by this list, but will stop working if this list
84 * becomes shorter than its current length.
85 */ 81 */
86 List<E> get reversed; 82 Iterable<E> get reversed;
87 83
88 /** 84 /**
89 * Sorts the list according to the order specified by the [compare] function. 85 * Sorts the list according to the order specified by the [compare] function.
90 * 86 *
91 * The [compare] function must act as a [Comparator]. 87 * The [compare] function must act as a [Comparator].
92 * The default [List] implementations use [Comparable.compare] if 88 * The default [List] implementations use [Comparable.compare] if
93 * [compare] is omitted. 89 * [compare] is omitted.
94 */ 90 */
95 void sort([int compare(E a, E b)]); 91 void sort([int compare(E a, E b)]);
96 92
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 * not extendable. 180 * not extendable.
185 * If [length] is 0, this method does not do anything. 181 * If [length] is 0, this method does not do anything.
186 * If [start] is the length of the list, this method inserts the 182 * If [start] is the length of the list, this method inserts the
187 * range at the end of the list. 183 * range at the end of the list.
188 * Throws an [ArgumentError] if [length] is negative. 184 * Throws an [ArgumentError] if [length] is negative.
189 * Throws an [RangeError] if [start] is negative or if 185 * Throws an [RangeError] if [start] is negative or if
190 * [start] is greater than the length of the list. 186 * [start] is greater than the length of the list.
191 */ 187 */
192 void insertRange(int start, int length, [E fill]); 188 void insertRange(int start, int length, [E fill]);
193 } 189 }
OLDNEW
« no previous file with comments | « dart/sdk/lib/core/iterable.dart ('k') | dart/sdk/lib/core/string_buffer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698