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

Side by Side Diff: corelib/src/list.dart

Issue 9561005: The setRange methods works on non-extensible arrays. Document it as such. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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 | « no previous file | no next file » | 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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 /** 5 /**
6 * A [List] is an indexable collection with a length. It can be of 6 * A [List] is an indexable collection with a length. It can be of
7 * fixed size or extendable. 7 * fixed size or extendable.
8 */ 8 */
9 interface List<E> extends Collection<E> default ListFactory<E> { 9 interface List<E> extends Collection<E> default ListFactory<E> {
10 10
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 * Returns an empty list if [length] is 0. 114 * Returns an empty list if [length] is 0.
115 * Throws an [IllegalArgumentException] if [length] is negative. 115 * Throws an [IllegalArgumentException] if [length] is negative.
116 * Throws an [IndexOutOfRangeException] if [start] or 116 * Throws an [IndexOutOfRangeException] if [start] or
117 * [:start + length:] are out of range. 117 * [:start + length:] are out of range.
118 */ 118 */
119 List<E> getRange(int start, int length); 119 List<E> getRange(int start, int length);
120 120
121 /** 121 /**
122 * Copies [length] elements of the [from] array, starting 122 * Copies [length] elements of the [from] array, starting
123 * from [startFrom], into [:this:], starting at [start]. 123 * from [startFrom], into [:this:], starting at [start].
124 * Throws an [UnsupportedOperationException] if the list is
125 * not extendable.
126 * If [length] is 0, this method does not do anything. 124 * If [length] is 0, this method does not do anything.
127 * Throws an [IllegalArgumentException] if [length] is negative. 125 * Throws an [IllegalArgumentException] if [length] is negative.
128 * Throws an [IndexOutOfRangeException] if [start] or 126 * Throws an [IndexOutOfRangeException] if [start] or
129 * [:start + length:] are out of range for [:this:], or if 127 * [:start + length:] are out of range for [:this:], or if
130 * [startFrom] is out of range for [from]. 128 * [startFrom] is out of range for [from].
131 */ 129 */
132 void setRange(int start, int length, List<E> from, [int startFrom]); 130 void setRange(int start, int length, List<E> from, [int startFrom]);
133 131
134 /** 132 /**
135 * Removes the range in the list starting from [start] to 133 * Removes the range in the list starting from [start] to
(...skipping 14 matching lines...) Expand all
150 * not extendable. 148 * not extendable.
151 * If [length] is 0, this method does not do anything. 149 * If [length] is 0, this method does not do anything.
152 * If [start] is the length of the array, this method inserts the 150 * If [start] is the length of the array, this method inserts the
153 * range at the end of the array. 151 * range at the end of the array.
154 * Throws an [IllegalArgumentException] if [length] is negative. 152 * Throws an [IllegalArgumentException] if [length] is negative.
155 * Throws an [IndexOutOfRangeException] if [start] or 153 * Throws an [IndexOutOfRangeException] if [start] or
156 * [:start + length:] are out of range. 154 * [:start + length:] are out of range.
157 */ 155 */
158 void insertRange(int start, int length, [E initialValue]); 156 void insertRange(int start, int length, [E initialValue]);
159 } 157 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698