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

Side by Side Diff: lib/core/queue.dart

Issue 11273041: Make first and last getters. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update status files with co19 issue number. Created 8 years, 1 month 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 | « lib/core/list.dart ('k') | lib/core/sequences.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) 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 [Queue] is a collection that can be manipulated at both ends. One 6 * A [Queue] is a collection that can be manipulated at both ends. One
7 * can iterate over the elements of a queue through [forEach] or with 7 * can iterate over the elements of a queue through [forEach] or with
8 * an [Iterator]. 8 * an [Iterator].
9 */ 9 */
10 abstract class Queue<E> extends Collection<E> { 10 abstract class Queue<E> extends Collection<E> {
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 /** 50 /**
51 * Adds all elements of [collection] at the end of the queue. The 51 * Adds all elements of [collection] at the end of the queue. The
52 * length of the queue is extended by the length of [collection]. 52 * length of the queue is extended by the length of [collection].
53 */ 53 */
54 void addAll(Collection<E> collection); 54 void addAll(Collection<E> collection);
55 55
56 /** 56 /**
57 * Returns the first element of the queue. Throws an 57 * Returns the first element of the queue. Throws an
58 * [EmptyQueueException] exception if this queue is empty. 58 * [EmptyQueueException] exception if this queue is empty.
59 */ 59 */
60 E first(); 60 E get first;
61 61
62 /** 62 /**
63 * Returns the last element of the queue. Throws an 63 * Returns the last element of the queue. Throws an
64 * [EmptyQueueException] exception if this queue is empty. 64 * [EmptyQueueException] exception if this queue is empty.
65 */ 65 */
66 E last(); 66 E get last;
67 67
68 /** 68 /**
69 * Removes all elements in the queue. The size of the queue becomes zero. 69 * Removes all elements in the queue. The size of the queue becomes zero.
70 */ 70 */
71 void clear(); 71 void clear();
72 } 72 }
OLDNEW
« no previous file with comments | « lib/core/list.dart ('k') | lib/core/sequences.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698