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

Side by Side Diff: sdk/lib/html/dart2js/html_dart2js.dart

Issue 11971016: Create IterableMixinWorkaround and move most of the Collections methods there. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 11 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
OLDNEW
1 library html; 1 library html;
2 2
3 import 'dart:async'; 3 import 'dart:async';
4 import 'dart:collection'; 4 import 'dart:collection';
5 import 'dart:html_common'; 5 import 'dart:html_common';
6 import 'dart:indexed_db'; 6 import 'dart:indexed_db';
7 import 'dart:isolate'; 7 import 'dart:isolate';
8 import 'dart:json' as json; 8 import 'dart:json' as json;
9 import 'dart:math'; 9 import 'dart:math';
10 import 'dart:svg' as svg; 10 import 'dart:svg' as svg;
(...skipping 6438 matching lines...) Expand 10 before | Expand all | Expand 10 after
6449 // for details. All rights reserved. Use of this source code is governed by a 6449 // for details. All rights reserved. Use of this source code is governed by a
6450 // BSD-style license that can be found in the LICENSE file. 6450 // BSD-style license that can be found in the LICENSE file.
6451 6451
6452 6452
6453 /// @domName DOMError; @docsEditable true 6453 /// @domName DOMError; @docsEditable true
6454 class DomError native "*DOMError" { 6454 class DomError native "*DOMError" {
6455 6455
6456 /// @domName DOMError.name; @docsEditable true 6456 /// @domName DOMError.name; @docsEditable true
6457 final String name; 6457 final String name;
6458 } 6458 }
6459 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 6459 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
6460 // for details. All rights reserved. Use of this source code is governed by a 6460 // for details. All rights reserved. Use of this source code is governed by a
6461 // BSD-style license that can be found in the LICENSE file. 6461 // BSD-style license that can be found in the LICENSE file.
6462 6462
6463 6463
6464 /// @domName DOMException 6464 /// @domName DOMException; @docsEditable true
6465 class DomException native "*DOMException" { 6465 class DomException native "*DOMException" {
6466 6466
6467 static const String INDEX_SIZE = 'IndexSizeError';
6468 static const String HIERARCHY_REQUEST = 'HierarchyRequestError';
6469 static const String WRONG_DOCUMENT = 'WrongDocumentError';
6470 static const String INVALID_CHARACTER = 'InvalidCharacterError';
6471 static const String NO_MODIFICATION_ALLOWED = 'NoModificationAllowedError';
6472 static const String NOT_FOUND = 'NotFoundError';
6473 static const String NOT_SUPPORTED = 'NotSupportedError';
6474 static const String INVALID_STATE = 'InvalidStateError';
6475 static const String SYNTAX = 'SyntaxError';
6476 static const String INVALID_MODIFICATION = 'InvalidModificationError';
6477 static const String NAMESPACE = 'NamespaceError';
6478 static const String INVALID_ACCESS = 'InvalidAccessError';
6479 static const String TYPE_MISMATCH = 'TypeMismatchError';
6480 static const String SECURITY = 'SecurityError';
6481 static const String NETWORK = 'NetworkError';
6482 static const String ABORT = 'AbortError';
6483 static const String URL_MISMATCH = 'URLMismatchError';
6484 static const String QUOTA_EXCEEDED = 'QuotaExceededError';
6485 static const String TIMEOUT = 'TimeoutError';
6486 static const String INVALID_NODE_TYPE = 'InvalidNodeTypeError';
6487 static const String DATA_CLONE = 'DataCloneError';
6488
6489 String get name {
6490 var errorName = JS('String', '#.name', this);
6491 // Although Safari nightly has updated the name to SecurityError, Safari 5
6492 // and 6 still return SECURITY_ERR.
6493 if (_Device.isWebKit && errorName == 'SECURITY_ERR') return 'SecurityError';
6494 // Chrome release still uses old string, remove this line when Chrome stable
6495 // also prints out SyntaxError.
6496 if (_Device.isWebKit && errorName == 'SYNTAX_ERR') return 'SyntaxError';
6497 return errorName;
6498 }
6499
6500 /// @domName DOMException.message; @docsEditable true 6467 /// @domName DOMException.message; @docsEditable true
6501 final String message; 6468 final String message;
6502 6469
6503 /// @domName DOMException.toString; @docsEditable true 6470 /// @domName DOMException.toString; @docsEditable true
6504 String toString() native; 6471 String toString() native;
6505
6506 } 6472 }
6507 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 6473 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
6508 // for details. All rights reserved. Use of this source code is governed by a 6474 // for details. All rights reserved. Use of this source code is governed by a
6509 // BSD-style license that can be found in the LICENSE file. 6475 // BSD-style license that can be found in the LICENSE file.
6510 6476
6511 6477
6512 /// @domName DOMImplementation; @docsEditable true 6478 /// @domName DOMImplementation; @docsEditable true
6513 class DomImplementation native "*DOMImplementation" { 6479 class DomImplementation native "*DOMImplementation" {
6514 6480
6515 /// @domName DOMImplementation.createCSSStyleSheet; @docsEditable true 6481 /// @domName DOMImplementation.createCSSStyleSheet; @docsEditable true
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
6571 // From Iterable<DomMimeType>: 6537 // From Iterable<DomMimeType>:
6572 6538
6573 Iterator<DomMimeType> get iterator { 6539 Iterator<DomMimeType> get iterator {
6574 // Note: NodeLists are not fixed size. And most probably length shouldn't 6540 // Note: NodeLists are not fixed size. And most probably length shouldn't
6575 // be cached in both iterator _and_ forEach method. For now caching it 6541 // be cached in both iterator _and_ forEach method. For now caching it
6576 // for consistency. 6542 // for consistency.
6577 return new FixedSizeListIterator<DomMimeType>(this); 6543 return new FixedSizeListIterator<DomMimeType>(this);
6578 } 6544 }
6579 6545
6580 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, DomMimeType)) { 6546 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, DomMimeType)) {
6581 return Collections.reduce(this, initialValue, combine); 6547 return IterableMixinWorkaround.reduce(this, initialValue, combine);
6582 } 6548 }
6583 6549
6584 bool contains(DomMimeType element) => Collections.contains(this, element); 6550 bool contains(DomMimeType element) => IterableMixinWorkaround.contains(this, e lement);
6585 6551
6586 void forEach(void f(DomMimeType element)) => Collections.forEach(this, f); 6552 void forEach(void f(DomMimeType element)) => IterableMixinWorkaround.forEach(t his, f);
6587 6553
6588 String join([String separator]) => Collections.joinList(this, separator); 6554 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
6589 6555
6590 List mappedBy(f(DomMimeType element)) => new MappedList<DomMimeType, dynamic>( this, f); 6556 List mappedBy(f(DomMimeType element)) => IterableMixinWorkaround.mappedByList( this, f);
6591 6557
6592 Iterable<DomMimeType> where(bool f(DomMimeType element)) => new WhereIterable< DomMimeType>(this, f); 6558 Iterable<DomMimeType> where(bool f(DomMimeType element)) => IterableMixinWorka round.where(this, f);
6593 6559
6594 bool every(bool f(DomMimeType element)) => Collections.every(this, f); 6560 bool every(bool f(DomMimeType element)) => IterableMixinWorkaround.every(this, f);
6595 6561
6596 bool any(bool f(DomMimeType element)) => Collections.any(this, f); 6562 bool any(bool f(DomMimeType element)) => IterableMixinWorkaround.any(this, f);
6597 6563
6598 List<DomMimeType> toList() => new List<DomMimeType>.from(this); 6564 List<DomMimeType> toList() => new List<DomMimeType>.from(this);
6599 Set<DomMimeType> toSet() => new Set<DomMimeType>.from(this); 6565 Set<DomMimeType> toSet() => new Set<DomMimeType>.from(this);
6600 6566
6601 bool get isEmpty => this.length == 0; 6567 bool get isEmpty => this.length == 0;
6602 6568
6603 List<DomMimeType> take(int n) => new ListView<DomMimeType>(this, 0, n); 6569 List<DomMimeType> take(int n) => IterableMixinWorkaround.takeList(this, n);
6604 6570
6605 Iterable<DomMimeType> takeWhile(bool test(DomMimeType value)) { 6571 Iterable<DomMimeType> takeWhile(bool test(DomMimeType value)) {
6606 return new TakeWhileIterable<DomMimeType>(this, test); 6572 return IterableMixinWorkaround.takeWhile(this, test);
6607 } 6573 }
6608 6574
6609 List<DomMimeType> skip(int n) => new ListView<DomMimeType>(this, n, null); 6575 List<DomMimeType> skip(int n) => IterableMixinWorkaround.skipList(this, n);
6610 6576
6611 Iterable<DomMimeType> skipWhile(bool test(DomMimeType value)) { 6577 Iterable<DomMimeType> skipWhile(bool test(DomMimeType value)) {
6612 return new SkipWhileIterable<DomMimeType>(this, test); 6578 return IterableMixinWorkaround.skipWhile(this, test);
6613 } 6579 }
6614 6580
6615 DomMimeType firstMatching(bool test(DomMimeType value), { DomMimeType orElse() }) { 6581 DomMimeType firstMatching(bool test(DomMimeType value), { DomMimeType orElse() }) {
6616 return Collections.firstMatching(this, test, orElse); 6582 return IterableMixinWorkaround.firstMatching(this, test, orElse);
6617 } 6583 }
6618 6584
6619 DomMimeType lastMatching(bool test(DomMimeType value), {DomMimeType orElse()}) { 6585 DomMimeType lastMatching(bool test(DomMimeType value), {DomMimeType orElse()}) {
6620 return Collections.lastMatchingInList(this, test, orElse); 6586 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
6621 } 6587 }
6622 6588
6623 DomMimeType singleMatching(bool test(DomMimeType value)) { 6589 DomMimeType singleMatching(bool test(DomMimeType value)) {
6624 return Collections.singleMatching(this, test); 6590 return IterableMixinWorkaround.singleMatching(this, test);
6625 } 6591 }
6626 6592
6627 DomMimeType elementAt(int index) { 6593 DomMimeType elementAt(int index) {
6628 return this[index]; 6594 return this[index];
6629 } 6595 }
6630 6596
6631 // From Collection<DomMimeType>: 6597 // From Collection<DomMimeType>:
6632 6598
6633 void add(DomMimeType value) { 6599 void add(DomMimeType value) {
6634 throw new UnsupportedError("Cannot add to immutable List."); 6600 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
6672 if (this.length > 0) return this[this.length - 1]; 6638 if (this.length > 0) return this[this.length - 1];
6673 throw new StateError("No elements"); 6639 throw new StateError("No elements");
6674 } 6640 }
6675 6641
6676 DomMimeType get single { 6642 DomMimeType get single {
6677 if (length == 1) return this[0]; 6643 if (length == 1) return this[0];
6678 if (length == 0) throw new StateError("No elements"); 6644 if (length == 0) throw new StateError("No elements");
6679 throw new StateError("More than one element"); 6645 throw new StateError("More than one element");
6680 } 6646 }
6681 6647
6682 DomMimeType min([int compare(DomMimeType a, DomMimeType b)]) => Collections.mi n(this, compare); 6648 DomMimeType min([int compare(DomMimeType a, DomMimeType b)]) => IterableMixinW orkaround.min(this, compare);
6683 6649
6684 DomMimeType max([int compare(DomMimeType a, DomMimeType b)]) => Collections.ma x(this, compare); 6650 DomMimeType max([int compare(DomMimeType a, DomMimeType b)]) => IterableMixinW orkaround.max(this, compare);
6685 6651
6686 DomMimeType removeAt(int pos) { 6652 DomMimeType removeAt(int pos) {
6687 throw new UnsupportedError("Cannot removeAt on immutable List."); 6653 throw new UnsupportedError("Cannot removeAt on immutable List.");
6688 } 6654 }
6689 6655
6690 DomMimeType removeLast() { 6656 DomMimeType removeLast() {
6691 throw new UnsupportedError("Cannot removeLast on immutable List."); 6657 throw new UnsupportedError("Cannot removeLast on immutable List.");
6692 } 6658 }
6693 6659
6694 void setRange(int start, int rangeLength, List<DomMimeType> from, [int startFr om]) { 6660 void setRange(int start, int rangeLength, List<DomMimeType> from, [int startFr om]) {
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
6777 // From Iterable<DomPlugin>: 6743 // From Iterable<DomPlugin>:
6778 6744
6779 Iterator<DomPlugin> get iterator { 6745 Iterator<DomPlugin> get iterator {
6780 // Note: NodeLists are not fixed size. And most probably length shouldn't 6746 // Note: NodeLists are not fixed size. And most probably length shouldn't
6781 // be cached in both iterator _and_ forEach method. For now caching it 6747 // be cached in both iterator _and_ forEach method. For now caching it
6782 // for consistency. 6748 // for consistency.
6783 return new FixedSizeListIterator<DomPlugin>(this); 6749 return new FixedSizeListIterator<DomPlugin>(this);
6784 } 6750 }
6785 6751
6786 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, DomPlugin)) { 6752 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, DomPlugin)) {
6787 return Collections.reduce(this, initialValue, combine); 6753 return IterableMixinWorkaround.reduce(this, initialValue, combine);
6788 } 6754 }
6789 6755
6790 bool contains(DomPlugin element) => Collections.contains(this, element); 6756 bool contains(DomPlugin element) => IterableMixinWorkaround.contains(this, ele ment);
6791 6757
6792 void forEach(void f(DomPlugin element)) => Collections.forEach(this, f); 6758 void forEach(void f(DomPlugin element)) => IterableMixinWorkaround.forEach(thi s, f);
6793 6759
6794 String join([String separator]) => Collections.joinList(this, separator); 6760 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
6795 6761
6796 List mappedBy(f(DomPlugin element)) => new MappedList<DomPlugin, dynamic>(this , f); 6762 List mappedBy(f(DomPlugin element)) => IterableMixinWorkaround.mappedByList(th is, f);
6797 6763
6798 Iterable<DomPlugin> where(bool f(DomPlugin element)) => new WhereIterable<DomP lugin>(this, f); 6764 Iterable<DomPlugin> where(bool f(DomPlugin element)) => IterableMixinWorkaroun d.where(this, f);
6799 6765
6800 bool every(bool f(DomPlugin element)) => Collections.every(this, f); 6766 bool every(bool f(DomPlugin element)) => IterableMixinWorkaround.every(this, f );
6801 6767
6802 bool any(bool f(DomPlugin element)) => Collections.any(this, f); 6768 bool any(bool f(DomPlugin element)) => IterableMixinWorkaround.any(this, f);
6803 6769
6804 List<DomPlugin> toList() => new List<DomPlugin>.from(this); 6770 List<DomPlugin> toList() => new List<DomPlugin>.from(this);
6805 Set<DomPlugin> toSet() => new Set<DomPlugin>.from(this); 6771 Set<DomPlugin> toSet() => new Set<DomPlugin>.from(this);
6806 6772
6807 bool get isEmpty => this.length == 0; 6773 bool get isEmpty => this.length == 0;
6808 6774
6809 List<DomPlugin> take(int n) => new ListView<DomPlugin>(this, 0, n); 6775 List<DomPlugin> take(int n) => IterableMixinWorkaround.takeList(this, n);
6810 6776
6811 Iterable<DomPlugin> takeWhile(bool test(DomPlugin value)) { 6777 Iterable<DomPlugin> takeWhile(bool test(DomPlugin value)) {
6812 return new TakeWhileIterable<DomPlugin>(this, test); 6778 return IterableMixinWorkaround.takeWhile(this, test);
6813 } 6779 }
6814 6780
6815 List<DomPlugin> skip(int n) => new ListView<DomPlugin>(this, n, null); 6781 List<DomPlugin> skip(int n) => IterableMixinWorkaround.skipList(this, n);
6816 6782
6817 Iterable<DomPlugin> skipWhile(bool test(DomPlugin value)) { 6783 Iterable<DomPlugin> skipWhile(bool test(DomPlugin value)) {
6818 return new SkipWhileIterable<DomPlugin>(this, test); 6784 return IterableMixinWorkaround.skipWhile(this, test);
6819 } 6785 }
6820 6786
6821 DomPlugin firstMatching(bool test(DomPlugin value), { DomPlugin orElse() }) { 6787 DomPlugin firstMatching(bool test(DomPlugin value), { DomPlugin orElse() }) {
6822 return Collections.firstMatching(this, test, orElse); 6788 return IterableMixinWorkaround.firstMatching(this, test, orElse);
6823 } 6789 }
6824 6790
6825 DomPlugin lastMatching(bool test(DomPlugin value), {DomPlugin orElse()}) { 6791 DomPlugin lastMatching(bool test(DomPlugin value), {DomPlugin orElse()}) {
6826 return Collections.lastMatchingInList(this, test, orElse); 6792 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
6827 } 6793 }
6828 6794
6829 DomPlugin singleMatching(bool test(DomPlugin value)) { 6795 DomPlugin singleMatching(bool test(DomPlugin value)) {
6830 return Collections.singleMatching(this, test); 6796 return IterableMixinWorkaround.singleMatching(this, test);
6831 } 6797 }
6832 6798
6833 DomPlugin elementAt(int index) { 6799 DomPlugin elementAt(int index) {
6834 return this[index]; 6800 return this[index];
6835 } 6801 }
6836 6802
6837 // From Collection<DomPlugin>: 6803 // From Collection<DomPlugin>:
6838 6804
6839 void add(DomPlugin value) { 6805 void add(DomPlugin value) {
6840 throw new UnsupportedError("Cannot add to immutable List."); 6806 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
6878 if (this.length > 0) return this[this.length - 1]; 6844 if (this.length > 0) return this[this.length - 1];
6879 throw new StateError("No elements"); 6845 throw new StateError("No elements");
6880 } 6846 }
6881 6847
6882 DomPlugin get single { 6848 DomPlugin get single {
6883 if (length == 1) return this[0]; 6849 if (length == 1) return this[0];
6884 if (length == 0) throw new StateError("No elements"); 6850 if (length == 0) throw new StateError("No elements");
6885 throw new StateError("More than one element"); 6851 throw new StateError("More than one element");
6886 } 6852 }
6887 6853
6888 DomPlugin min([int compare(DomPlugin a, DomPlugin b)]) => Collections.min(this , compare); 6854 DomPlugin min([int compare(DomPlugin a, DomPlugin b)]) => IterableMixinWorkaro und.min(this, compare);
6889 6855
6890 DomPlugin max([int compare(DomPlugin a, DomPlugin b)]) => Collections.max(this , compare); 6856 DomPlugin max([int compare(DomPlugin a, DomPlugin b)]) => IterableMixinWorkaro und.max(this, compare);
6891 6857
6892 DomPlugin removeAt(int pos) { 6858 DomPlugin removeAt(int pos) {
6893 throw new UnsupportedError("Cannot removeAt on immutable List."); 6859 throw new UnsupportedError("Cannot removeAt on immutable List.");
6894 } 6860 }
6895 6861
6896 DomPlugin removeLast() { 6862 DomPlugin removeLast() {
6897 throw new UnsupportedError("Cannot removeLast on immutable List."); 6863 throw new UnsupportedError("Cannot removeLast on immutable List.");
6898 } 6864 }
6899 6865
6900 void setRange(int start, int rangeLength, List<DomPlugin> from, [int startFrom ]) { 6866 void setRange(int start, int rangeLength, List<DomPlugin> from, [int startFrom ]) {
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
7042 // From Iterable<String>: 7008 // From Iterable<String>:
7043 7009
7044 Iterator<String> get iterator { 7010 Iterator<String> get iterator {
7045 // Note: NodeLists are not fixed size. And most probably length shouldn't 7011 // Note: NodeLists are not fixed size. And most probably length shouldn't
7046 // be cached in both iterator _and_ forEach method. For now caching it 7012 // be cached in both iterator _and_ forEach method. For now caching it
7047 // for consistency. 7013 // for consistency.
7048 return new FixedSizeListIterator<String>(this); 7014 return new FixedSizeListIterator<String>(this);
7049 } 7015 }
7050 7016
7051 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, String)) { 7017 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, String)) {
7052 return Collections.reduce(this, initialValue, combine); 7018 return IterableMixinWorkaround.reduce(this, initialValue, combine);
7053 } 7019 }
7054 7020
7055 // contains() defined by IDL. 7021 // contains() defined by IDL.
7056 7022
7057 void forEach(void f(String element)) => Collections.forEach(this, f); 7023 void forEach(void f(String element)) => IterableMixinWorkaround.forEach(this, f);
7058 7024
7059 String join([String separator]) => Collections.joinList(this, separator); 7025 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
7060 7026
7061 List mappedBy(f(String element)) => new MappedList<String, dynamic>(this, f); 7027 List mappedBy(f(String element)) => IterableMixinWorkaround.mappedByList(this, f);
7062 7028
7063 Iterable<String> where(bool f(String element)) => new WhereIterable<String>(th is, f); 7029 Iterable<String> where(bool f(String element)) => IterableMixinWorkaround.wher e(this, f);
7064 7030
7065 bool every(bool f(String element)) => Collections.every(this, f); 7031 bool every(bool f(String element)) => IterableMixinWorkaround.every(this, f);
7066 7032
7067 bool any(bool f(String element)) => Collections.any(this, f); 7033 bool any(bool f(String element)) => IterableMixinWorkaround.any(this, f);
7068 7034
7069 List<String> toList() => new List<String>.from(this); 7035 List<String> toList() => new List<String>.from(this);
7070 Set<String> toSet() => new Set<String>.from(this); 7036 Set<String> toSet() => new Set<String>.from(this);
7071 7037
7072 bool get isEmpty => this.length == 0; 7038 bool get isEmpty => this.length == 0;
7073 7039
7074 List<String> take(int n) => new ListView<String>(this, 0, n); 7040 List<String> take(int n) => IterableMixinWorkaround.takeList(this, n);
7075 7041
7076 Iterable<String> takeWhile(bool test(String value)) { 7042 Iterable<String> takeWhile(bool test(String value)) {
7077 return new TakeWhileIterable<String>(this, test); 7043 return IterableMixinWorkaround.takeWhile(this, test);
7078 } 7044 }
7079 7045
7080 List<String> skip(int n) => new ListView<String>(this, n, null); 7046 List<String> skip(int n) => IterableMixinWorkaround.skipList(this, n);
7081 7047
7082 Iterable<String> skipWhile(bool test(String value)) { 7048 Iterable<String> skipWhile(bool test(String value)) {
7083 return new SkipWhileIterable<String>(this, test); 7049 return IterableMixinWorkaround.skipWhile(this, test);
7084 } 7050 }
7085 7051
7086 String firstMatching(bool test(String value), { String orElse() }) { 7052 String firstMatching(bool test(String value), { String orElse() }) {
7087 return Collections.firstMatching(this, test, orElse); 7053 return IterableMixinWorkaround.firstMatching(this, test, orElse);
7088 } 7054 }
7089 7055
7090 String lastMatching(bool test(String value), {String orElse()}) { 7056 String lastMatching(bool test(String value), {String orElse()}) {
7091 return Collections.lastMatchingInList(this, test, orElse); 7057 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
7092 } 7058 }
7093 7059
7094 String singleMatching(bool test(String value)) { 7060 String singleMatching(bool test(String value)) {
7095 return Collections.singleMatching(this, test); 7061 return IterableMixinWorkaround.singleMatching(this, test);
7096 } 7062 }
7097 7063
7098 String elementAt(int index) { 7064 String elementAt(int index) {
7099 return this[index]; 7065 return this[index];
7100 } 7066 }
7101 7067
7102 // From Collection<String>: 7068 // From Collection<String>:
7103 7069
7104 void add(String value) { 7070 void add(String value) {
7105 throw new UnsupportedError("Cannot add to immutable List."); 7071 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
7143 if (this.length > 0) return this[this.length - 1]; 7109 if (this.length > 0) return this[this.length - 1];
7144 throw new StateError("No elements"); 7110 throw new StateError("No elements");
7145 } 7111 }
7146 7112
7147 String get single { 7113 String get single {
7148 if (length == 1) return this[0]; 7114 if (length == 1) return this[0];
7149 if (length == 0) throw new StateError("No elements"); 7115 if (length == 0) throw new StateError("No elements");
7150 throw new StateError("More than one element"); 7116 throw new StateError("More than one element");
7151 } 7117 }
7152 7118
7153 String min([int compare(String a, String b)]) => Collections.min(this, compare ); 7119 String min([int compare(String a, String b)]) => IterableMixinWorkaround.min(t his, compare);
7154 7120
7155 String max([int compare(String a, String b)]) => Collections.max(this, compare ); 7121 String max([int compare(String a, String b)]) => IterableMixinWorkaround.max(t his, compare);
7156 7122
7157 String removeAt(int pos) { 7123 String removeAt(int pos) {
7158 throw new UnsupportedError("Cannot removeAt on immutable List."); 7124 throw new UnsupportedError("Cannot removeAt on immutable List.");
7159 } 7125 }
7160 7126
7161 String removeLast() { 7127 String removeLast() {
7162 throw new UnsupportedError("Cannot removeLast on immutable List."); 7128 throw new UnsupportedError("Cannot removeLast on immutable List.");
7163 } 7129 }
7164 7130
7165 void setRange(int start, int rangeLength, List<String> from, [int startFrom]) { 7131 void setRange(int start, int rangeLength, List<String> from, [int startFrom]) {
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
7268 bool any(bool f(Element element)) { 7234 bool any(bool f(Element element)) {
7269 for (Element element in this) { 7235 for (Element element in this) {
7270 if (f(element)) { 7236 if (f(element)) {
7271 return true; 7237 return true;
7272 } 7238 }
7273 } 7239 }
7274 return false; 7240 return false;
7275 } 7241 }
7276 7242
7277 String join([String separator]) { 7243 String join([String separator]) {
7278 return Collections.joinList(this, separator); 7244 return IterableMixinWorkaround.joinList(this, separator);
7279 } 7245 }
7280 7246
7281 List mappedBy(f(Element element)) { 7247 List mappedBy(f(Element element)) {
7282 return new MappedList<Element, dynamic>(this, f); 7248 return IterableMixinWorkaround.mappedByList(this, f);
7283 } 7249 }
7284 7250
7285 Iterable<Element> where(bool f(Element element)) 7251 Iterable<Element> where(bool f(Element element)) {
7286 => new WhereIterable(this, f); 7252 return IterableMixinWorkaround.where(this, f);
7253 }
7287 7254
7288 bool get isEmpty { 7255 bool get isEmpty {
7289 return _element.$dom_firstElementChild == null; 7256 return _element.$dom_firstElementChild == null;
7290 } 7257 }
7291 7258
7292 List<Element> take(int n) { 7259 List<Element> take(int n) {
7293 return new ListView<Element>(this, 0, n); 7260 return IterableMixinWorkaround.takeList(this, n);
7294 } 7261 }
7295 7262
7296 Iterable<Element> takeWhile(bool test(Element value)) { 7263 Iterable<Element> takeWhile(bool test(Element value)) {
7297 return new TakeWhileIterable<Element>(this, test); 7264 return IterableMixinWorkaround.takeWhile(this, test);
7298 } 7265 }
7299 7266
7300 List<Element> skip(int n) { 7267 List<Element> skip(int n) {
7301 return new ListView<Element>(this, n, null); 7268 return IterableMixinWorkaround.skipList(this, n);
7302 } 7269 }
7303 7270
7304 Iterable<Element> skipWhile(bool test(Element value)) { 7271 Iterable<Element> skipWhile(bool test(Element value)) {
7305 return new SkipWhileIterable<Element>(this, test); 7272 return IterableMixinWorkaround.skipWhile(this, test);
7306 } 7273 }
7307 7274
7308 Element firstMatching(bool test(Element value), {Element orElse()}) { 7275 Element firstMatching(bool test(Element value), {Element orElse()}) {
7309 return Collections.firstMatching(this, test, orElse); 7276 return IterableMixinWorkaround.firstMatching(this, test, orElse);
7310 } 7277 }
7311 7278
7312 Element lastMatching(bool test(Element value), {Element orElse()}) { 7279 Element lastMatching(bool test(Element value), {Element orElse()}) {
7313 return Collections.lastMatchingInList(this, test, orElse); 7280 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
7314 } 7281 }
7315 7282
7316 Element singleMatching(bool test(Element value)) { 7283 Element singleMatching(bool test(Element value)) {
7317 return Collections.singleMatching(this, test); 7284 return IterableMixinWorkaround.singleMatching(this, test);
7318 } 7285 }
7319 7286
7320 Element elementAt(int index) { 7287 Element elementAt(int index) {
7321 return this[index]; 7288 return this[index];
7322 } 7289 }
7323 7290
7324 int get length { 7291 int get length {
7325 return _childElements.length; 7292 return _childElements.length;
7326 } 7293 }
7327 7294
(...skipping 24 matching lines...) Expand all
7352 _element.$dom_appendChild(element); 7319 _element.$dom_appendChild(element);
7353 } 7320 }
7354 } 7321 }
7355 7322
7356 void sort([int compare(Element a, Element b)]) { 7323 void sort([int compare(Element a, Element b)]) {
7357 throw new UnsupportedError('TODO(jacobr): should we impl?'); 7324 throw new UnsupportedError('TODO(jacobr): should we impl?');
7358 } 7325 }
7359 7326
7360 dynamic reduce(dynamic initialValue, 7327 dynamic reduce(dynamic initialValue,
7361 dynamic combine(dynamic previousValue, Element element)) { 7328 dynamic combine(dynamic previousValue, Element element)) {
7362 return Collections.reduce(this, initialValue, combine); 7329 return IterableMixinWorkaround.reduce(this, initialValue, combine);
7363 } 7330 }
7364 7331
7365 void setRange(int start, int rangeLength, List from, [int startFrom = 0]) { 7332 void setRange(int start, int rangeLength, List from, [int startFrom = 0]) {
7366 throw new UnimplementedError(); 7333 throw new UnimplementedError();
7367 } 7334 }
7368 7335
7369 void removeRange(int start, int rangeLength) { 7336 void removeRange(int start, int rangeLength) {
7370 throw new UnimplementedError(); 7337 throw new UnimplementedError();
7371 } 7338 }
7372 7339
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
7420 if (result == null) throw new StateError("No elements"); 7387 if (result == null) throw new StateError("No elements");
7421 return result; 7388 return result;
7422 } 7389 }
7423 7390
7424 Element get single { 7391 Element get single {
7425 if (length > 1) throw new StateError("More than one element"); 7392 if (length > 1) throw new StateError("More than one element");
7426 return first; 7393 return first;
7427 } 7394 }
7428 7395
7429 Element min([int compare(Element a, Element b)]) { 7396 Element min([int compare(Element a, Element b)]) {
7430 return Collections.min(this, compare); 7397 return IterableMixinWorkaround.min(this, compare);
7431 } 7398 }
7432 7399
7433 Element max([int compare(Element a, Element b)]) { 7400 Element max([int compare(Element a, Element b)]) {
7434 return Collections.max(this, compare); 7401 return IterableMixinWorkaround.max(this, compare);
7435 } 7402 }
7436 } 7403 }
7437 7404
7438 // TODO(jacobr): this is an inefficient implementation but it is hard to see 7405 // TODO(jacobr): this is an inefficient implementation but it is hard to see
7439 // a better option given that we cannot quite force NodeList to be an 7406 // a better option given that we cannot quite force NodeList to be an
7440 // ElementList as there are valid cases where a NodeList JavaScript object 7407 // ElementList as there are valid cases where a NodeList JavaScript object
7441 // contains Node objects that are not Elements. 7408 // contains Node objects that are not Elements.
7442 class _FrozenElementList implements List { 7409 class _FrozenElementList implements List {
7443 final List<Node> _nodeList; 7410 final List<Node> _nodeList;
7444 7411
7445 _FrozenElementList._wrap(this._nodeList); 7412 _FrozenElementList._wrap(this._nodeList);
7446 7413
7447 bool contains(Element element) { 7414 bool contains(Element element) {
7448 for (Element el in this) { 7415 for (Element el in this) {
7449 if (el == element) return true; 7416 if (el == element) return true;
7450 } 7417 }
7451 return false; 7418 return false;
7452 } 7419 }
7453 7420
7454 void forEach(void f(Element element)) { 7421 void forEach(void f(Element element)) {
7455 for (Element el in this) { 7422 for (Element el in this) {
7456 f(el); 7423 f(el);
7457 } 7424 }
7458 } 7425 }
7459 7426
7460 String join([String separator]) { 7427 String join([String separator]) {
7461 return Collections.joinList(this, separator); 7428 return IterableMixinWorkaround.joinList(this, separator);
7462 } 7429 }
7463 7430
7464 List mappedBy(f(Element element)) { 7431 List mappedBy(f(Element element)) {
7465 return new MappedList<Element, dynamic>(this, f); 7432 return IterableMixinWorkaround.mappedByList(this, f);
7466 } 7433 }
7467 7434
7468 Iterable<Element> where(bool f(Element element)) 7435 Iterable<Element> where(bool f(Element element)) {
7469 => new WhereIterable(this, f); 7436 return IterableMixinWorkaround.where(this, f);
7437 }
7470 7438
7471 bool every(bool f(Element element)) { 7439 bool every(bool f(Element element)) {
7472 for(Element element in this) { 7440 for(Element element in this) {
7473 if (!f(element)) { 7441 if (!f(element)) {
7474 return false; 7442 return false;
7475 } 7443 }
7476 }; 7444 };
7477 return true; 7445 return true;
7478 } 7446 }
7479 7447
7480 bool any(bool f(Element element)) { 7448 bool any(bool f(Element element)) {
7481 for(Element element in this) { 7449 for(Element element in this) {
7482 if (f(element)) { 7450 if (f(element)) {
7483 return true; 7451 return true;
7484 } 7452 }
7485 }; 7453 };
7486 return false; 7454 return false;
7487 } 7455 }
7488 7456
7489 List<Element> toList() => new List<Element>.from(this); 7457 List<Element> toList() => new List<Element>.from(this);
7490 Set<Element> toSet() => new Set<Element>.from(this); 7458 Set<Element> toSet() => new Set<Element>.from(this);
7491 7459
7492 List<Element> take(int n) { 7460 List<Element> take(int n) {
7493 return new ListView<Element>(this, 0, n); 7461 return IterableMixinWorkaround.takeList(this, n);
7494 } 7462 }
7495 7463
7496 Iterable<Element> takeWhile(bool test(Element value)) { 7464 Iterable<Element> takeWhile(bool test(Element value)) {
7497 return new TakeWhileIterable<Element>(this, test); 7465 return IterableMixinWorkaround.takeWhile(this, test);
7498 } 7466 }
7499 7467
7500 List<Element> skip(int n) { 7468 List<Element> skip(int n) {
7501 return new ListView<Element>(this, n, null); 7469 return IterableMixinWorkaround.skipList(this, n);
7502 } 7470 }
7503 7471
7504 Iterable<Element> skipWhile(bool test(Element value)) { 7472 Iterable<Element> skipWhile(bool test(Element value)) {
7505 return new SkipWhileIterable<Element>(this, test); 7473 return IterableMixinWorkaround.skipWhile(this, test);
7506 } 7474 }
7507 7475
7508 Element firstMatching(bool test(Element value), {Element orElse()}) { 7476 Element firstMatching(bool test(Element value), {Element orElse()}) {
7509 return Collections.firstMatching(this, test, orElse); 7477 return IterableMixinWorkaround.firstMatching(this, test, orElse);
7510 } 7478 }
7511 7479
7512 Element lastMatching(bool test(Element value), {Element orElse()}) { 7480 Element lastMatching(bool test(Element value), {Element orElse()}) {
7513 return Collections.lastMatchingInList(this, test, orElse); 7481 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
7514 } 7482 }
7515 7483
7516 Element singleMatching(bool test(Element value)) { 7484 Element singleMatching(bool test(Element value)) {
7517 return Collections.singleMatching(this, test); 7485 return IterableMixinWorkaround.singleMatching(this, test);
7518 } 7486 }
7519 7487
7520 Element elementAt(int index) { 7488 Element elementAt(int index) {
7521 return this[index]; 7489 return this[index];
7522 } 7490 }
7523 7491
7524 bool get isEmpty => _nodeList.isEmpty; 7492 bool get isEmpty => _nodeList.isEmpty;
7525 7493
7526 int get length => _nodeList.length; 7494 int get length => _nodeList.length;
7527 7495
(...skipping 20 matching lines...) Expand all
7548 void addAll(Iterable<Element> iterable) { 7516 void addAll(Iterable<Element> iterable) {
7549 throw new UnsupportedError(''); 7517 throw new UnsupportedError('');
7550 } 7518 }
7551 7519
7552 void sort([int compare(Element a, Element b)]) { 7520 void sort([int compare(Element a, Element b)]) {
7553 throw new UnsupportedError(''); 7521 throw new UnsupportedError('');
7554 } 7522 }
7555 7523
7556 dynamic reduce(dynamic initialValue, 7524 dynamic reduce(dynamic initialValue,
7557 dynamic combine(dynamic previousValue, Element element)) { 7525 dynamic combine(dynamic previousValue, Element element)) {
7558 return Collections.reduce(this, initialValue, combine); 7526 return IterableMixinWorkaround.reduce(this, initialValue, combine);
7559 } 7527 }
7560 7528
7561 void setRange(int start, int rangeLength, List from, [int startFrom = 0]) { 7529 void setRange(int start, int rangeLength, List from, [int startFrom = 0]) {
7562 throw new UnsupportedError(''); 7530 throw new UnsupportedError('');
7563 } 7531 }
7564 7532
7565 void removeRange(int start, int rangeLength) { 7533 void removeRange(int start, int rangeLength) {
7566 throw new UnsupportedError(''); 7534 throw new UnsupportedError('');
7567 } 7535 }
7568 7536
(...skipping 22 matching lines...) Expand all
7591 throw new UnsupportedError(''); 7559 throw new UnsupportedError('');
7592 } 7560 }
7593 7561
7594 Element get first => _nodeList.first; 7562 Element get first => _nodeList.first;
7595 7563
7596 Element get last => _nodeList.last; 7564 Element get last => _nodeList.last;
7597 7565
7598 Element get single => _nodeList.single; 7566 Element get single => _nodeList.single;
7599 7567
7600 Element min([int compare(Element a, Element b)]) { 7568 Element min([int compare(Element a, Element b)]) {
7601 return Collections.min(this, compare); 7569 return IterableMixinWorkaround.min(this, compare);
7602 } 7570 }
7603 7571
7604 Element max([int compare(Element a, Element b)]) { 7572 Element max([int compare(Element a, Element b)]) {
7605 return Collections.max(this, compare); 7573 return IterableMixinWorkaround.max(this, compare);
7606 } 7574 }
7607 } 7575 }
7608 7576
7609 class _FrozenElementListIterator implements Iterator<Element> { 7577 class _FrozenElementListIterator implements Iterator<Element> {
7610 final _FrozenElementList _list; 7578 final _FrozenElementList _list;
7611 int _index = -1; 7579 int _index = -1;
7612 Element _current; 7580 Element _current;
7613 7581
7614 _FrozenElementListIterator(this._list); 7582 _FrozenElementListIterator(this._list);
7615 7583
(...skipping 1834 matching lines...) Expand 10 before | Expand all | Expand 10 after
9450 // From Iterable<File>: 9418 // From Iterable<File>:
9451 9419
9452 Iterator<File> get iterator { 9420 Iterator<File> get iterator {
9453 // Note: NodeLists are not fixed size. And most probably length shouldn't 9421 // Note: NodeLists are not fixed size. And most probably length shouldn't
9454 // be cached in both iterator _and_ forEach method. For now caching it 9422 // be cached in both iterator _and_ forEach method. For now caching it
9455 // for consistency. 9423 // for consistency.
9456 return new FixedSizeListIterator<File>(this); 9424 return new FixedSizeListIterator<File>(this);
9457 } 9425 }
9458 9426
9459 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, File)) { 9427 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, File)) {
9460 return Collections.reduce(this, initialValue, combine); 9428 return IterableMixinWorkaround.reduce(this, initialValue, combine);
9461 } 9429 }
9462 9430
9463 bool contains(File element) => Collections.contains(this, element); 9431 bool contains(File element) => IterableMixinWorkaround.contains(this, element) ;
9464 9432
9465 void forEach(void f(File element)) => Collections.forEach(this, f); 9433 void forEach(void f(File element)) => IterableMixinWorkaround.forEach(this, f) ;
9466 9434
9467 String join([String separator]) => Collections.joinList(this, separator); 9435 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
9468 9436
9469 List mappedBy(f(File element)) => new MappedList<File, dynamic>(this, f); 9437 List mappedBy(f(File element)) => IterableMixinWorkaround.mappedByList(this, f );
9470 9438
9471 Iterable<File> where(bool f(File element)) => new WhereIterable<File>(this, f) ; 9439 Iterable<File> where(bool f(File element)) => IterableMixinWorkaround.where(th is, f);
9472 9440
9473 bool every(bool f(File element)) => Collections.every(this, f); 9441 bool every(bool f(File element)) => IterableMixinWorkaround.every(this, f);
9474 9442
9475 bool any(bool f(File element)) => Collections.any(this, f); 9443 bool any(bool f(File element)) => IterableMixinWorkaround.any(this, f);
9476 9444
9477 List<File> toList() => new List<File>.from(this); 9445 List<File> toList() => new List<File>.from(this);
9478 Set<File> toSet() => new Set<File>.from(this); 9446 Set<File> toSet() => new Set<File>.from(this);
9479 9447
9480 bool get isEmpty => this.length == 0; 9448 bool get isEmpty => this.length == 0;
9481 9449
9482 List<File> take(int n) => new ListView<File>(this, 0, n); 9450 List<File> take(int n) => IterableMixinWorkaround.takeList(this, n);
9483 9451
9484 Iterable<File> takeWhile(bool test(File value)) { 9452 Iterable<File> takeWhile(bool test(File value)) {
9485 return new TakeWhileIterable<File>(this, test); 9453 return IterableMixinWorkaround.takeWhile(this, test);
9486 } 9454 }
9487 9455
9488 List<File> skip(int n) => new ListView<File>(this, n, null); 9456 List<File> skip(int n) => IterableMixinWorkaround.skipList(this, n);
9489 9457
9490 Iterable<File> skipWhile(bool test(File value)) { 9458 Iterable<File> skipWhile(bool test(File value)) {
9491 return new SkipWhileIterable<File>(this, test); 9459 return IterableMixinWorkaround.skipWhile(this, test);
9492 } 9460 }
9493 9461
9494 File firstMatching(bool test(File value), { File orElse() }) { 9462 File firstMatching(bool test(File value), { File orElse() }) {
9495 return Collections.firstMatching(this, test, orElse); 9463 return IterableMixinWorkaround.firstMatching(this, test, orElse);
9496 } 9464 }
9497 9465
9498 File lastMatching(bool test(File value), {File orElse()}) { 9466 File lastMatching(bool test(File value), {File orElse()}) {
9499 return Collections.lastMatchingInList(this, test, orElse); 9467 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
9500 } 9468 }
9501 9469
9502 File singleMatching(bool test(File value)) { 9470 File singleMatching(bool test(File value)) {
9503 return Collections.singleMatching(this, test); 9471 return IterableMixinWorkaround.singleMatching(this, test);
9504 } 9472 }
9505 9473
9506 File elementAt(int index) { 9474 File elementAt(int index) {
9507 return this[index]; 9475 return this[index];
9508 } 9476 }
9509 9477
9510 // From Collection<File>: 9478 // From Collection<File>:
9511 9479
9512 void add(File value) { 9480 void add(File value) {
9513 throw new UnsupportedError("Cannot add to immutable List."); 9481 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
9551 if (this.length > 0) return this[this.length - 1]; 9519 if (this.length > 0) return this[this.length - 1];
9552 throw new StateError("No elements"); 9520 throw new StateError("No elements");
9553 } 9521 }
9554 9522
9555 File get single { 9523 File get single {
9556 if (length == 1) return this[0]; 9524 if (length == 1) return this[0];
9557 if (length == 0) throw new StateError("No elements"); 9525 if (length == 0) throw new StateError("No elements");
9558 throw new StateError("More than one element"); 9526 throw new StateError("More than one element");
9559 } 9527 }
9560 9528
9561 File min([int compare(File a, File b)]) => Collections.min(this, compare); 9529 File min([int compare(File a, File b)]) => IterableMixinWorkaround.min(this, c ompare);
9562 9530
9563 File max([int compare(File a, File b)]) => Collections.max(this, compare); 9531 File max([int compare(File a, File b)]) => IterableMixinWorkaround.max(this, c ompare);
9564 9532
9565 File removeAt(int pos) { 9533 File removeAt(int pos) {
9566 throw new UnsupportedError("Cannot removeAt on immutable List."); 9534 throw new UnsupportedError("Cannot removeAt on immutable List.");
9567 } 9535 }
9568 9536
9569 File removeLast() { 9537 File removeLast() {
9570 throw new UnsupportedError("Cannot removeLast on immutable List."); 9538 throw new UnsupportedError("Cannot removeLast on immutable List.");
9571 } 9539 }
9572 9540
9573 void setRange(int start, int rangeLength, List<File> from, [int startFrom]) { 9541 void setRange(int start, int rangeLength, List<File> from, [int startFrom]) {
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after
9925 // From Iterable<num>: 9893 // From Iterable<num>:
9926 9894
9927 Iterator<num> get iterator { 9895 Iterator<num> get iterator {
9928 // Note: NodeLists are not fixed size. And most probably length shouldn't 9896 // Note: NodeLists are not fixed size. And most probably length shouldn't
9929 // be cached in both iterator _and_ forEach method. For now caching it 9897 // be cached in both iterator _and_ forEach method. For now caching it
9930 // for consistency. 9898 // for consistency.
9931 return new FixedSizeListIterator<num>(this); 9899 return new FixedSizeListIterator<num>(this);
9932 } 9900 }
9933 9901
9934 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, num)) { 9902 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, num)) {
9935 return Collections.reduce(this, initialValue, combine); 9903 return IterableMixinWorkaround.reduce(this, initialValue, combine);
9936 } 9904 }
9937 9905
9938 bool contains(num element) => Collections.contains(this, element); 9906 bool contains(num element) => IterableMixinWorkaround.contains(this, element);
9939 9907
9940 void forEach(void f(num element)) => Collections.forEach(this, f); 9908 void forEach(void f(num element)) => IterableMixinWorkaround.forEach(this, f);
9941 9909
9942 String join([String separator]) => Collections.joinList(this, separator); 9910 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
9943 9911
9944 List mappedBy(f(num element)) => new MappedList<num, dynamic>(this, f); 9912 List mappedBy(f(num element)) => IterableMixinWorkaround.mappedByList(this, f) ;
9945 9913
9946 Iterable<num> where(bool f(num element)) => new WhereIterable<num>(this, f); 9914 Iterable<num> where(bool f(num element)) => IterableMixinWorkaround.where(this , f);
9947 9915
9948 bool every(bool f(num element)) => Collections.every(this, f); 9916 bool every(bool f(num element)) => IterableMixinWorkaround.every(this, f);
9949 9917
9950 bool any(bool f(num element)) => Collections.any(this, f); 9918 bool any(bool f(num element)) => IterableMixinWorkaround.any(this, f);
9951 9919
9952 List<num> toList() => new List<num>.from(this); 9920 List<num> toList() => new List<num>.from(this);
9953 Set<num> toSet() => new Set<num>.from(this); 9921 Set<num> toSet() => new Set<num>.from(this);
9954 9922
9955 bool get isEmpty => this.length == 0; 9923 bool get isEmpty => this.length == 0;
9956 9924
9957 List<num> take(int n) => new ListView<num>(this, 0, n); 9925 List<num> take(int n) => IterableMixinWorkaround.takeList(this, n);
9958 9926
9959 Iterable<num> takeWhile(bool test(num value)) { 9927 Iterable<num> takeWhile(bool test(num value)) {
9960 return new TakeWhileIterable<num>(this, test); 9928 return IterableMixinWorkaround.takeWhile(this, test);
9961 } 9929 }
9962 9930
9963 List<num> skip(int n) => new ListView<num>(this, n, null); 9931 List<num> skip(int n) => IterableMixinWorkaround.skipList(this, n);
9964 9932
9965 Iterable<num> skipWhile(bool test(num value)) { 9933 Iterable<num> skipWhile(bool test(num value)) {
9966 return new SkipWhileIterable<num>(this, test); 9934 return IterableMixinWorkaround.skipWhile(this, test);
9967 } 9935 }
9968 9936
9969 num firstMatching(bool test(num value), { num orElse() }) { 9937 num firstMatching(bool test(num value), { num orElse() }) {
9970 return Collections.firstMatching(this, test, orElse); 9938 return IterableMixinWorkaround.firstMatching(this, test, orElse);
9971 } 9939 }
9972 9940
9973 num lastMatching(bool test(num value), {num orElse()}) { 9941 num lastMatching(bool test(num value), {num orElse()}) {
9974 return Collections.lastMatchingInList(this, test, orElse); 9942 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
9975 } 9943 }
9976 9944
9977 num singleMatching(bool test(num value)) { 9945 num singleMatching(bool test(num value)) {
9978 return Collections.singleMatching(this, test); 9946 return IterableMixinWorkaround.singleMatching(this, test);
9979 } 9947 }
9980 9948
9981 num elementAt(int index) { 9949 num elementAt(int index) {
9982 return this[index]; 9950 return this[index];
9983 } 9951 }
9984 9952
9985 // From Collection<num>: 9953 // From Collection<num>:
9986 9954
9987 void add(num value) { 9955 void add(num value) {
9988 throw new UnsupportedError("Cannot add to immutable List."); 9956 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
10026 if (this.length > 0) return this[this.length - 1]; 9994 if (this.length > 0) return this[this.length - 1];
10027 throw new StateError("No elements"); 9995 throw new StateError("No elements");
10028 } 9996 }
10029 9997
10030 num get single { 9998 num get single {
10031 if (length == 1) return this[0]; 9999 if (length == 1) return this[0];
10032 if (length == 0) throw new StateError("No elements"); 10000 if (length == 0) throw new StateError("No elements");
10033 throw new StateError("More than one element"); 10001 throw new StateError("More than one element");
10034 } 10002 }
10035 10003
10036 num min([int compare(num a, num b)]) => Collections.min(this, compare); 10004 num min([int compare(num a, num b)]) => IterableMixinWorkaround.min(this, comp are);
10037 10005
10038 num max([int compare(num a, num b)]) => Collections.max(this, compare); 10006 num max([int compare(num a, num b)]) => IterableMixinWorkaround.max(this, comp are);
10039 10007
10040 num removeAt(int pos) { 10008 num removeAt(int pos) {
10041 throw new UnsupportedError("Cannot removeAt on immutable List."); 10009 throw new UnsupportedError("Cannot removeAt on immutable List.");
10042 } 10010 }
10043 10011
10044 num removeLast() { 10012 num removeLast() {
10045 throw new UnsupportedError("Cannot removeLast on immutable List."); 10013 throw new UnsupportedError("Cannot removeLast on immutable List.");
10046 } 10014 }
10047 10015
10048 void setRange(int start, int rangeLength, List<num> from, [int startFrom]) { 10016 void setRange(int start, int rangeLength, List<num> from, [int startFrom]) {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
10099 // From Iterable<num>: 10067 // From Iterable<num>:
10100 10068
10101 Iterator<num> get iterator { 10069 Iterator<num> get iterator {
10102 // Note: NodeLists are not fixed size. And most probably length shouldn't 10070 // Note: NodeLists are not fixed size. And most probably length shouldn't
10103 // be cached in both iterator _and_ forEach method. For now caching it 10071 // be cached in both iterator _and_ forEach method. For now caching it
10104 // for consistency. 10072 // for consistency.
10105 return new FixedSizeListIterator<num>(this); 10073 return new FixedSizeListIterator<num>(this);
10106 } 10074 }
10107 10075
10108 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, num)) { 10076 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, num)) {
10109 return Collections.reduce(this, initialValue, combine); 10077 return IterableMixinWorkaround.reduce(this, initialValue, combine);
10110 } 10078 }
10111 10079
10112 bool contains(num element) => Collections.contains(this, element); 10080 bool contains(num element) => IterableMixinWorkaround.contains(this, element);
10113 10081
10114 void forEach(void f(num element)) => Collections.forEach(this, f); 10082 void forEach(void f(num element)) => IterableMixinWorkaround.forEach(this, f);
10115 10083
10116 String join([String separator]) => Collections.joinList(this, separator); 10084 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
10117 10085
10118 List mappedBy(f(num element)) => new MappedList<num, dynamic>(this, f); 10086 List mappedBy(f(num element)) => IterableMixinWorkaround.mappedByList(this, f) ;
10119 10087
10120 Iterable<num> where(bool f(num element)) => new WhereIterable<num>(this, f); 10088 Iterable<num> where(bool f(num element)) => IterableMixinWorkaround.where(this , f);
10121 10089
10122 bool every(bool f(num element)) => Collections.every(this, f); 10090 bool every(bool f(num element)) => IterableMixinWorkaround.every(this, f);
10123 10091
10124 bool any(bool f(num element)) => Collections.any(this, f); 10092 bool any(bool f(num element)) => IterableMixinWorkaround.any(this, f);
10125 10093
10126 List<num> toList() => new List<num>.from(this); 10094 List<num> toList() => new List<num>.from(this);
10127 Set<num> toSet() => new Set<num>.from(this); 10095 Set<num> toSet() => new Set<num>.from(this);
10128 10096
10129 bool get isEmpty => this.length == 0; 10097 bool get isEmpty => this.length == 0;
10130 10098
10131 List<num> take(int n) => new ListView<num>(this, 0, n); 10099 List<num> take(int n) => IterableMixinWorkaround.takeList(this, n);
10132 10100
10133 Iterable<num> takeWhile(bool test(num value)) { 10101 Iterable<num> takeWhile(bool test(num value)) {
10134 return new TakeWhileIterable<num>(this, test); 10102 return IterableMixinWorkaround.takeWhile(this, test);
10135 } 10103 }
10136 10104
10137 List<num> skip(int n) => new ListView<num>(this, n, null); 10105 List<num> skip(int n) => IterableMixinWorkaround.skipList(this, n);
10138 10106
10139 Iterable<num> skipWhile(bool test(num value)) { 10107 Iterable<num> skipWhile(bool test(num value)) {
10140 return new SkipWhileIterable<num>(this, test); 10108 return IterableMixinWorkaround.skipWhile(this, test);
10141 } 10109 }
10142 10110
10143 num firstMatching(bool test(num value), { num orElse() }) { 10111 num firstMatching(bool test(num value), { num orElse() }) {
10144 return Collections.firstMatching(this, test, orElse); 10112 return IterableMixinWorkaround.firstMatching(this, test, orElse);
10145 } 10113 }
10146 10114
10147 num lastMatching(bool test(num value), {num orElse()}) { 10115 num lastMatching(bool test(num value), {num orElse()}) {
10148 return Collections.lastMatchingInList(this, test, orElse); 10116 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
10149 } 10117 }
10150 10118
10151 num singleMatching(bool test(num value)) { 10119 num singleMatching(bool test(num value)) {
10152 return Collections.singleMatching(this, test); 10120 return IterableMixinWorkaround.singleMatching(this, test);
10153 } 10121 }
10154 10122
10155 num elementAt(int index) { 10123 num elementAt(int index) {
10156 return this[index]; 10124 return this[index];
10157 } 10125 }
10158 10126
10159 // From Collection<num>: 10127 // From Collection<num>:
10160 10128
10161 void add(num value) { 10129 void add(num value) {
10162 throw new UnsupportedError("Cannot add to immutable List."); 10130 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
10200 if (this.length > 0) return this[this.length - 1]; 10168 if (this.length > 0) return this[this.length - 1];
10201 throw new StateError("No elements"); 10169 throw new StateError("No elements");
10202 } 10170 }
10203 10171
10204 num get single { 10172 num get single {
10205 if (length == 1) return this[0]; 10173 if (length == 1) return this[0];
10206 if (length == 0) throw new StateError("No elements"); 10174 if (length == 0) throw new StateError("No elements");
10207 throw new StateError("More than one element"); 10175 throw new StateError("More than one element");
10208 } 10176 }
10209 10177
10210 num min([int compare(num a, num b)]) => Collections.min(this, compare); 10178 num min([int compare(num a, num b)]) => IterableMixinWorkaround.min(this, comp are);
10211 10179
10212 num max([int compare(num a, num b)]) => Collections.max(this, compare); 10180 num max([int compare(num a, num b)]) => IterableMixinWorkaround.max(this, comp are);
10213 10181
10214 num removeAt(int pos) { 10182 num removeAt(int pos) {
10215 throw new UnsupportedError("Cannot removeAt on immutable List."); 10183 throw new UnsupportedError("Cannot removeAt on immutable List.");
10216 } 10184 }
10217 10185
10218 num removeLast() { 10186 num removeLast() {
10219 throw new UnsupportedError("Cannot removeLast on immutable List."); 10187 throw new UnsupportedError("Cannot removeLast on immutable List.");
10220 } 10188 }
10221 10189
10222 void setRange(int start, int rangeLength, List<num> from, [int startFrom]) { 10190 void setRange(int start, int rangeLength, List<num> from, [int startFrom]) {
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
10640 // From Iterable<Node>: 10608 // From Iterable<Node>:
10641 10609
10642 Iterator<Node> get iterator { 10610 Iterator<Node> get iterator {
10643 // Note: NodeLists are not fixed size. And most probably length shouldn't 10611 // Note: NodeLists are not fixed size. And most probably length shouldn't
10644 // be cached in both iterator _and_ forEach method. For now caching it 10612 // be cached in both iterator _and_ forEach method. For now caching it
10645 // for consistency. 10613 // for consistency.
10646 return new FixedSizeListIterator<Node>(this); 10614 return new FixedSizeListIterator<Node>(this);
10647 } 10615 }
10648 10616
10649 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) { 10617 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) {
10650 return Collections.reduce(this, initialValue, combine); 10618 return IterableMixinWorkaround.reduce(this, initialValue, combine);
10651 } 10619 }
10652 10620
10653 bool contains(Node element) => Collections.contains(this, element); 10621 bool contains(Node element) => IterableMixinWorkaround.contains(this, element) ;
10654 10622
10655 void forEach(void f(Node element)) => Collections.forEach(this, f); 10623 void forEach(void f(Node element)) => IterableMixinWorkaround.forEach(this, f) ;
10656 10624
10657 String join([String separator]) => Collections.joinList(this, separator); 10625 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
10658 10626
10659 List mappedBy(f(Node element)) => new MappedList<Node, dynamic>(this, f); 10627 List mappedBy(f(Node element)) => IterableMixinWorkaround.mappedByList(this, f );
10660 10628
10661 Iterable<Node> where(bool f(Node element)) => new WhereIterable<Node>(this, f) ; 10629 Iterable<Node> where(bool f(Node element)) => IterableMixinWorkaround.where(th is, f);
10662 10630
10663 bool every(bool f(Node element)) => Collections.every(this, f); 10631 bool every(bool f(Node element)) => IterableMixinWorkaround.every(this, f);
10664 10632
10665 bool any(bool f(Node element)) => Collections.any(this, f); 10633 bool any(bool f(Node element)) => IterableMixinWorkaround.any(this, f);
10666 10634
10667 List<Node> toList() => new List<Node>.from(this); 10635 List<Node> toList() => new List<Node>.from(this);
10668 Set<Node> toSet() => new Set<Node>.from(this); 10636 Set<Node> toSet() => new Set<Node>.from(this);
10669 10637
10670 bool get isEmpty => this.length == 0; 10638 bool get isEmpty => this.length == 0;
10671 10639
10672 List<Node> take(int n) => new ListView<Node>(this, 0, n); 10640 List<Node> take(int n) => IterableMixinWorkaround.takeList(this, n);
10673 10641
10674 Iterable<Node> takeWhile(bool test(Node value)) { 10642 Iterable<Node> takeWhile(bool test(Node value)) {
10675 return new TakeWhileIterable<Node>(this, test); 10643 return IterableMixinWorkaround.takeWhile(this, test);
10676 } 10644 }
10677 10645
10678 List<Node> skip(int n) => new ListView<Node>(this, n, null); 10646 List<Node> skip(int n) => IterableMixinWorkaround.skipList(this, n);
10679 10647
10680 Iterable<Node> skipWhile(bool test(Node value)) { 10648 Iterable<Node> skipWhile(bool test(Node value)) {
10681 return new SkipWhileIterable<Node>(this, test); 10649 return IterableMixinWorkaround.skipWhile(this, test);
10682 } 10650 }
10683 10651
10684 Node firstMatching(bool test(Node value), { Node orElse() }) { 10652 Node firstMatching(bool test(Node value), { Node orElse() }) {
10685 return Collections.firstMatching(this, test, orElse); 10653 return IterableMixinWorkaround.firstMatching(this, test, orElse);
10686 } 10654 }
10687 10655
10688 Node lastMatching(bool test(Node value), {Node orElse()}) { 10656 Node lastMatching(bool test(Node value), {Node orElse()}) {
10689 return Collections.lastMatchingInList(this, test, orElse); 10657 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
10690 } 10658 }
10691 10659
10692 Node singleMatching(bool test(Node value)) { 10660 Node singleMatching(bool test(Node value)) {
10693 return Collections.singleMatching(this, test); 10661 return IterableMixinWorkaround.singleMatching(this, test);
10694 } 10662 }
10695 10663
10696 Node elementAt(int index) { 10664 Node elementAt(int index) {
10697 return this[index]; 10665 return this[index];
10698 } 10666 }
10699 10667
10700 // From Collection<Node>: 10668 // From Collection<Node>:
10701 10669
10702 void add(Node value) { 10670 void add(Node value) {
10703 throw new UnsupportedError("Cannot add to immutable List."); 10671 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
10741 if (this.length > 0) return this[this.length - 1]; 10709 if (this.length > 0) return this[this.length - 1];
10742 throw new StateError("No elements"); 10710 throw new StateError("No elements");
10743 } 10711 }
10744 10712
10745 Node get single { 10713 Node get single {
10746 if (length == 1) return this[0]; 10714 if (length == 1) return this[0];
10747 if (length == 0) throw new StateError("No elements"); 10715 if (length == 0) throw new StateError("No elements");
10748 throw new StateError("More than one element"); 10716 throw new StateError("More than one element");
10749 } 10717 }
10750 10718
10751 Node min([int compare(Node a, Node b)]) => Collections.min(this, compare); 10719 Node min([int compare(Node a, Node b)]) => IterableMixinWorkaround.min(this, c ompare);
10752 10720
10753 Node max([int compare(Node a, Node b)]) => Collections.max(this, compare); 10721 Node max([int compare(Node a, Node b)]) => IterableMixinWorkaround.max(this, c ompare);
10754 10722
10755 Node removeAt(int pos) { 10723 Node removeAt(int pos) {
10756 throw new UnsupportedError("Cannot removeAt on immutable List."); 10724 throw new UnsupportedError("Cannot removeAt on immutable List.");
10757 } 10725 }
10758 10726
10759 Node removeLast() { 10727 Node removeLast() {
10760 throw new UnsupportedError("Cannot removeLast on immutable List."); 10728 throw new UnsupportedError("Cannot removeLast on immutable List.");
10761 } 10729 }
10762 10730
10763 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) { 10731 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) {
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
10809 // From Iterable<Node>: 10777 // From Iterable<Node>:
10810 10778
10811 Iterator<Node> get iterator { 10779 Iterator<Node> get iterator {
10812 // Note: NodeLists are not fixed size. And most probably length shouldn't 10780 // Note: NodeLists are not fixed size. And most probably length shouldn't
10813 // be cached in both iterator _and_ forEach method. For now caching it 10781 // be cached in both iterator _and_ forEach method. For now caching it
10814 // for consistency. 10782 // for consistency.
10815 return new FixedSizeListIterator<Node>(this); 10783 return new FixedSizeListIterator<Node>(this);
10816 } 10784 }
10817 10785
10818 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) { 10786 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) {
10819 return Collections.reduce(this, initialValue, combine); 10787 return IterableMixinWorkaround.reduce(this, initialValue, combine);
10820 } 10788 }
10821 10789
10822 bool contains(Node element) => Collections.contains(this, element); 10790 bool contains(Node element) => IterableMixinWorkaround.contains(this, element) ;
10823 10791
10824 void forEach(void f(Node element)) => Collections.forEach(this, f); 10792 void forEach(void f(Node element)) => IterableMixinWorkaround.forEach(this, f) ;
10825 10793
10826 String join([String separator]) => Collections.joinList(this, separator); 10794 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
10827 10795
10828 List mappedBy(f(Node element)) => new MappedList<Node, dynamic>(this, f); 10796 List mappedBy(f(Node element)) => IterableMixinWorkaround.mappedByList(this, f );
10829 10797
10830 Iterable<Node> where(bool f(Node element)) => new WhereIterable<Node>(this, f) ; 10798 Iterable<Node> where(bool f(Node element)) => IterableMixinWorkaround.where(th is, f);
10831 10799
10832 bool every(bool f(Node element)) => Collections.every(this, f); 10800 bool every(bool f(Node element)) => IterableMixinWorkaround.every(this, f);
10833 10801
10834 bool any(bool f(Node element)) => Collections.any(this, f); 10802 bool any(bool f(Node element)) => IterableMixinWorkaround.any(this, f);
10835 10803
10836 List<Node> toList() => new List<Node>.from(this); 10804 List<Node> toList() => new List<Node>.from(this);
10837 Set<Node> toSet() => new Set<Node>.from(this); 10805 Set<Node> toSet() => new Set<Node>.from(this);
10838 10806
10839 bool get isEmpty => this.length == 0; 10807 bool get isEmpty => this.length == 0;
10840 10808
10841 List<Node> take(int n) => new ListView<Node>(this, 0, n); 10809 List<Node> take(int n) => IterableMixinWorkaround.takeList(this, n);
10842 10810
10843 Iterable<Node> takeWhile(bool test(Node value)) { 10811 Iterable<Node> takeWhile(bool test(Node value)) {
10844 return new TakeWhileIterable<Node>(this, test); 10812 return IterableMixinWorkaround.takeWhile(this, test);
10845 } 10813 }
10846 10814
10847 List<Node> skip(int n) => new ListView<Node>(this, n, null); 10815 List<Node> skip(int n) => IterableMixinWorkaround.skipList(this, n);
10848 10816
10849 Iterable<Node> skipWhile(bool test(Node value)) { 10817 Iterable<Node> skipWhile(bool test(Node value)) {
10850 return new SkipWhileIterable<Node>(this, test); 10818 return IterableMixinWorkaround.skipWhile(this, test);
10851 } 10819 }
10852 10820
10853 Node firstMatching(bool test(Node value), { Node orElse() }) { 10821 Node firstMatching(bool test(Node value), { Node orElse() }) {
10854 return Collections.firstMatching(this, test, orElse); 10822 return IterableMixinWorkaround.firstMatching(this, test, orElse);
10855 } 10823 }
10856 10824
10857 Node lastMatching(bool test(Node value), {Node orElse()}) { 10825 Node lastMatching(bool test(Node value), {Node orElse()}) {
10858 return Collections.lastMatchingInList(this, test, orElse); 10826 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
10859 } 10827 }
10860 10828
10861 Node singleMatching(bool test(Node value)) { 10829 Node singleMatching(bool test(Node value)) {
10862 return Collections.singleMatching(this, test); 10830 return IterableMixinWorkaround.singleMatching(this, test);
10863 } 10831 }
10864 10832
10865 Node elementAt(int index) { 10833 Node elementAt(int index) {
10866 return this[index]; 10834 return this[index];
10867 } 10835 }
10868 10836
10869 // From Collection<Node>: 10837 // From Collection<Node>:
10870 10838
10871 void add(Node value) { 10839 void add(Node value) {
10872 throw new UnsupportedError("Cannot add to immutable List."); 10840 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
10910 if (this.length > 0) return this[this.length - 1]; 10878 if (this.length > 0) return this[this.length - 1];
10911 throw new StateError("No elements"); 10879 throw new StateError("No elements");
10912 } 10880 }
10913 10881
10914 Node get single { 10882 Node get single {
10915 if (length == 1) return this[0]; 10883 if (length == 1) return this[0];
10916 if (length == 0) throw new StateError("No elements"); 10884 if (length == 0) throw new StateError("No elements");
10917 throw new StateError("More than one element"); 10885 throw new StateError("More than one element");
10918 } 10886 }
10919 10887
10920 Node min([int compare(Node a, Node b)]) => Collections.min(this, compare); 10888 Node min([int compare(Node a, Node b)]) => IterableMixinWorkaround.min(this, c ompare);
10921 10889
10922 Node max([int compare(Node a, Node b)]) => Collections.max(this, compare); 10890 Node max([int compare(Node a, Node b)]) => IterableMixinWorkaround.max(this, c ompare);
10923 10891
10924 Node removeAt(int pos) { 10892 Node removeAt(int pos) {
10925 throw new UnsupportedError("Cannot removeAt on immutable List."); 10893 throw new UnsupportedError("Cannot removeAt on immutable List.");
10926 } 10894 }
10927 10895
10928 Node removeLast() { 10896 Node removeLast() {
10929 throw new UnsupportedError("Cannot removeLast on immutable List."); 10897 throw new UnsupportedError("Cannot removeLast on immutable List.");
10930 } 10898 }
10931 10899
10932 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) { 10900 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) {
(...skipping 1447 matching lines...) Expand 10 before | Expand all | Expand 10 after
12380 // From Iterable<int>: 12348 // From Iterable<int>:
12381 12349
12382 Iterator<int> get iterator { 12350 Iterator<int> get iterator {
12383 // Note: NodeLists are not fixed size. And most probably length shouldn't 12351 // Note: NodeLists are not fixed size. And most probably length shouldn't
12384 // be cached in both iterator _and_ forEach method. For now caching it 12352 // be cached in both iterator _and_ forEach method. For now caching it
12385 // for consistency. 12353 // for consistency.
12386 return new FixedSizeListIterator<int>(this); 12354 return new FixedSizeListIterator<int>(this);
12387 } 12355 }
12388 12356
12389 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 12357 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
12390 return Collections.reduce(this, initialValue, combine); 12358 return IterableMixinWorkaround.reduce(this, initialValue, combine);
12391 } 12359 }
12392 12360
12393 bool contains(int element) => Collections.contains(this, element); 12361 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
12394 12362
12395 void forEach(void f(int element)) => Collections.forEach(this, f); 12363 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
12396 12364
12397 String join([String separator]) => Collections.joinList(this, separator); 12365 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
12398 12366
12399 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 12367 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
12400 12368
12401 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 12369 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
12402 12370
12403 bool every(bool f(int element)) => Collections.every(this, f); 12371 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
12404 12372
12405 bool any(bool f(int element)) => Collections.any(this, f); 12373 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
12406 12374
12407 List<int> toList() => new List<int>.from(this); 12375 List<int> toList() => new List<int>.from(this);
12408 Set<int> toSet() => new Set<int>.from(this); 12376 Set<int> toSet() => new Set<int>.from(this);
12409 12377
12410 bool get isEmpty => this.length == 0; 12378 bool get isEmpty => this.length == 0;
12411 12379
12412 List<int> take(int n) => new ListView<int>(this, 0, n); 12380 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
12413 12381
12414 Iterable<int> takeWhile(bool test(int value)) { 12382 Iterable<int> takeWhile(bool test(int value)) {
12415 return new TakeWhileIterable<int>(this, test); 12383 return IterableMixinWorkaround.takeWhile(this, test);
12416 } 12384 }
12417 12385
12418 List<int> skip(int n) => new ListView<int>(this, n, null); 12386 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
12419 12387
12420 Iterable<int> skipWhile(bool test(int value)) { 12388 Iterable<int> skipWhile(bool test(int value)) {
12421 return new SkipWhileIterable<int>(this, test); 12389 return IterableMixinWorkaround.skipWhile(this, test);
12422 } 12390 }
12423 12391
12424 int firstMatching(bool test(int value), { int orElse() }) { 12392 int firstMatching(bool test(int value), { int orElse() }) {
12425 return Collections.firstMatching(this, test, orElse); 12393 return IterableMixinWorkaround.firstMatching(this, test, orElse);
12426 } 12394 }
12427 12395
12428 int lastMatching(bool test(int value), {int orElse()}) { 12396 int lastMatching(bool test(int value), {int orElse()}) {
12429 return Collections.lastMatchingInList(this, test, orElse); 12397 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
12430 } 12398 }
12431 12399
12432 int singleMatching(bool test(int value)) { 12400 int singleMatching(bool test(int value)) {
12433 return Collections.singleMatching(this, test); 12401 return IterableMixinWorkaround.singleMatching(this, test);
12434 } 12402 }
12435 12403
12436 int elementAt(int index) { 12404 int elementAt(int index) {
12437 return this[index]; 12405 return this[index];
12438 } 12406 }
12439 12407
12440 // From Collection<int>: 12408 // From Collection<int>:
12441 12409
12442 void add(int value) { 12410 void add(int value) {
12443 throw new UnsupportedError("Cannot add to immutable List."); 12411 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
12481 if (this.length > 0) return this[this.length - 1]; 12449 if (this.length > 0) return this[this.length - 1];
12482 throw new StateError("No elements"); 12450 throw new StateError("No elements");
12483 } 12451 }
12484 12452
12485 int get single { 12453 int get single {
12486 if (length == 1) return this[0]; 12454 if (length == 1) return this[0];
12487 if (length == 0) throw new StateError("No elements"); 12455 if (length == 0) throw new StateError("No elements");
12488 throw new StateError("More than one element"); 12456 throw new StateError("More than one element");
12489 } 12457 }
12490 12458
12491 int min([int compare(int a, int b)]) => Collections.min(this, compare); 12459 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
12492 12460
12493 int max([int compare(int a, int b)]) => Collections.max(this, compare); 12461 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
12494 12462
12495 int removeAt(int pos) { 12463 int removeAt(int pos) {
12496 throw new UnsupportedError("Cannot removeAt on immutable List."); 12464 throw new UnsupportedError("Cannot removeAt on immutable List.");
12497 } 12465 }
12498 12466
12499 int removeLast() { 12467 int removeLast() {
12500 throw new UnsupportedError("Cannot removeLast on immutable List."); 12468 throw new UnsupportedError("Cannot removeLast on immutable List.");
12501 } 12469 }
12502 12470
12503 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 12471 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
12554 // From Iterable<int>: 12522 // From Iterable<int>:
12555 12523
12556 Iterator<int> get iterator { 12524 Iterator<int> get iterator {
12557 // Note: NodeLists are not fixed size. And most probably length shouldn't 12525 // Note: NodeLists are not fixed size. And most probably length shouldn't
12558 // be cached in both iterator _and_ forEach method. For now caching it 12526 // be cached in both iterator _and_ forEach method. For now caching it
12559 // for consistency. 12527 // for consistency.
12560 return new FixedSizeListIterator<int>(this); 12528 return new FixedSizeListIterator<int>(this);
12561 } 12529 }
12562 12530
12563 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 12531 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
12564 return Collections.reduce(this, initialValue, combine); 12532 return IterableMixinWorkaround.reduce(this, initialValue, combine);
12565 } 12533 }
12566 12534
12567 bool contains(int element) => Collections.contains(this, element); 12535 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
12568 12536
12569 void forEach(void f(int element)) => Collections.forEach(this, f); 12537 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
12570 12538
12571 String join([String separator]) => Collections.joinList(this, separator); 12539 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
12572 12540
12573 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 12541 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
12574 12542
12575 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 12543 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
12576 12544
12577 bool every(bool f(int element)) => Collections.every(this, f); 12545 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
12578 12546
12579 bool any(bool f(int element)) => Collections.any(this, f); 12547 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
12580 12548
12581 List<int> toList() => new List<int>.from(this); 12549 List<int> toList() => new List<int>.from(this);
12582 Set<int> toSet() => new Set<int>.from(this); 12550 Set<int> toSet() => new Set<int>.from(this);
12583 12551
12584 bool get isEmpty => this.length == 0; 12552 bool get isEmpty => this.length == 0;
12585 12553
12586 List<int> take(int n) => new ListView<int>(this, 0, n); 12554 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
12587 12555
12588 Iterable<int> takeWhile(bool test(int value)) { 12556 Iterable<int> takeWhile(bool test(int value)) {
12589 return new TakeWhileIterable<int>(this, test); 12557 return IterableMixinWorkaround.takeWhile(this, test);
12590 } 12558 }
12591 12559
12592 List<int> skip(int n) => new ListView<int>(this, n, null); 12560 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
12593 12561
12594 Iterable<int> skipWhile(bool test(int value)) { 12562 Iterable<int> skipWhile(bool test(int value)) {
12595 return new SkipWhileIterable<int>(this, test); 12563 return IterableMixinWorkaround.skipWhile(this, test);
12596 } 12564 }
12597 12565
12598 int firstMatching(bool test(int value), { int orElse() }) { 12566 int firstMatching(bool test(int value), { int orElse() }) {
12599 return Collections.firstMatching(this, test, orElse); 12567 return IterableMixinWorkaround.firstMatching(this, test, orElse);
12600 } 12568 }
12601 12569
12602 int lastMatching(bool test(int value), {int orElse()}) { 12570 int lastMatching(bool test(int value), {int orElse()}) {
12603 return Collections.lastMatchingInList(this, test, orElse); 12571 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
12604 } 12572 }
12605 12573
12606 int singleMatching(bool test(int value)) { 12574 int singleMatching(bool test(int value)) {
12607 return Collections.singleMatching(this, test); 12575 return IterableMixinWorkaround.singleMatching(this, test);
12608 } 12576 }
12609 12577
12610 int elementAt(int index) { 12578 int elementAt(int index) {
12611 return this[index]; 12579 return this[index];
12612 } 12580 }
12613 12581
12614 // From Collection<int>: 12582 // From Collection<int>:
12615 12583
12616 void add(int value) { 12584 void add(int value) {
12617 throw new UnsupportedError("Cannot add to immutable List."); 12585 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
12655 if (this.length > 0) return this[this.length - 1]; 12623 if (this.length > 0) return this[this.length - 1];
12656 throw new StateError("No elements"); 12624 throw new StateError("No elements");
12657 } 12625 }
12658 12626
12659 int get single { 12627 int get single {
12660 if (length == 1) return this[0]; 12628 if (length == 1) return this[0];
12661 if (length == 0) throw new StateError("No elements"); 12629 if (length == 0) throw new StateError("No elements");
12662 throw new StateError("More than one element"); 12630 throw new StateError("More than one element");
12663 } 12631 }
12664 12632
12665 int min([int compare(int a, int b)]) => Collections.min(this, compare); 12633 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
12666 12634
12667 int max([int compare(int a, int b)]) => Collections.max(this, compare); 12635 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
12668 12636
12669 int removeAt(int pos) { 12637 int removeAt(int pos) {
12670 throw new UnsupportedError("Cannot removeAt on immutable List."); 12638 throw new UnsupportedError("Cannot removeAt on immutable List.");
12671 } 12639 }
12672 12640
12673 int removeLast() { 12641 int removeLast() {
12674 throw new UnsupportedError("Cannot removeLast on immutable List."); 12642 throw new UnsupportedError("Cannot removeLast on immutable List.");
12675 } 12643 }
12676 12644
12677 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 12645 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
12728 // From Iterable<int>: 12696 // From Iterable<int>:
12729 12697
12730 Iterator<int> get iterator { 12698 Iterator<int> get iterator {
12731 // Note: NodeLists are not fixed size. And most probably length shouldn't 12699 // Note: NodeLists are not fixed size. And most probably length shouldn't
12732 // be cached in both iterator _and_ forEach method. For now caching it 12700 // be cached in both iterator _and_ forEach method. For now caching it
12733 // for consistency. 12701 // for consistency.
12734 return new FixedSizeListIterator<int>(this); 12702 return new FixedSizeListIterator<int>(this);
12735 } 12703 }
12736 12704
12737 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 12705 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
12738 return Collections.reduce(this, initialValue, combine); 12706 return IterableMixinWorkaround.reduce(this, initialValue, combine);
12739 } 12707 }
12740 12708
12741 bool contains(int element) => Collections.contains(this, element); 12709 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
12742 12710
12743 void forEach(void f(int element)) => Collections.forEach(this, f); 12711 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
12744 12712
12745 String join([String separator]) => Collections.joinList(this, separator); 12713 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
12746 12714
12747 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 12715 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
12748 12716
12749 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 12717 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
12750 12718
12751 bool every(bool f(int element)) => Collections.every(this, f); 12719 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
12752 12720
12753 bool any(bool f(int element)) => Collections.any(this, f); 12721 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
12754 12722
12755 List<int> toList() => new List<int>.from(this); 12723 List<int> toList() => new List<int>.from(this);
12756 Set<int> toSet() => new Set<int>.from(this); 12724 Set<int> toSet() => new Set<int>.from(this);
12757 12725
12758 bool get isEmpty => this.length == 0; 12726 bool get isEmpty => this.length == 0;
12759 12727
12760 List<int> take(int n) => new ListView<int>(this, 0, n); 12728 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
12761 12729
12762 Iterable<int> takeWhile(bool test(int value)) { 12730 Iterable<int> takeWhile(bool test(int value)) {
12763 return new TakeWhileIterable<int>(this, test); 12731 return IterableMixinWorkaround.takeWhile(this, test);
12764 } 12732 }
12765 12733
12766 List<int> skip(int n) => new ListView<int>(this, n, null); 12734 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
12767 12735
12768 Iterable<int> skipWhile(bool test(int value)) { 12736 Iterable<int> skipWhile(bool test(int value)) {
12769 return new SkipWhileIterable<int>(this, test); 12737 return IterableMixinWorkaround.skipWhile(this, test);
12770 } 12738 }
12771 12739
12772 int firstMatching(bool test(int value), { int orElse() }) { 12740 int firstMatching(bool test(int value), { int orElse() }) {
12773 return Collections.firstMatching(this, test, orElse); 12741 return IterableMixinWorkaround.firstMatching(this, test, orElse);
12774 } 12742 }
12775 12743
12776 int lastMatching(bool test(int value), {int orElse()}) { 12744 int lastMatching(bool test(int value), {int orElse()}) {
12777 return Collections.lastMatchingInList(this, test, orElse); 12745 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
12778 } 12746 }
12779 12747
12780 int singleMatching(bool test(int value)) { 12748 int singleMatching(bool test(int value)) {
12781 return Collections.singleMatching(this, test); 12749 return IterableMixinWorkaround.singleMatching(this, test);
12782 } 12750 }
12783 12751
12784 int elementAt(int index) { 12752 int elementAt(int index) {
12785 return this[index]; 12753 return this[index];
12786 } 12754 }
12787 12755
12788 // From Collection<int>: 12756 // From Collection<int>:
12789 12757
12790 void add(int value) { 12758 void add(int value) {
12791 throw new UnsupportedError("Cannot add to immutable List."); 12759 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
12829 if (this.length > 0) return this[this.length - 1]; 12797 if (this.length > 0) return this[this.length - 1];
12830 throw new StateError("No elements"); 12798 throw new StateError("No elements");
12831 } 12799 }
12832 12800
12833 int get single { 12801 int get single {
12834 if (length == 1) return this[0]; 12802 if (length == 1) return this[0];
12835 if (length == 0) throw new StateError("No elements"); 12803 if (length == 0) throw new StateError("No elements");
12836 throw new StateError("More than one element"); 12804 throw new StateError("More than one element");
12837 } 12805 }
12838 12806
12839 int min([int compare(int a, int b)]) => Collections.min(this, compare); 12807 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
12840 12808
12841 int max([int compare(int a, int b)]) => Collections.max(this, compare); 12809 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
12842 12810
12843 int removeAt(int pos) { 12811 int removeAt(int pos) {
12844 throw new UnsupportedError("Cannot removeAt on immutable List."); 12812 throw new UnsupportedError("Cannot removeAt on immutable List.");
12845 } 12813 }
12846 12814
12847 int removeLast() { 12815 int removeLast() {
12848 throw new UnsupportedError("Cannot removeLast on immutable List."); 12816 throw new UnsupportedError("Cannot removeLast on immutable List.");
12849 } 12817 }
12850 12818
12851 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 12819 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 1738 matching lines...) Expand 10 before | Expand all | Expand 10 after
14590 // From Iterable<Node>: 14558 // From Iterable<Node>:
14591 14559
14592 Iterator<Node> get iterator { 14560 Iterator<Node> get iterator {
14593 // Note: NodeLists are not fixed size. And most probably length shouldn't 14561 // Note: NodeLists are not fixed size. And most probably length shouldn't
14594 // be cached in both iterator _and_ forEach method. For now caching it 14562 // be cached in both iterator _and_ forEach method. For now caching it
14595 // for consistency. 14563 // for consistency.
14596 return new FixedSizeListIterator<Node>(this); 14564 return new FixedSizeListIterator<Node>(this);
14597 } 14565 }
14598 14566
14599 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) { 14567 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) {
14600 return Collections.reduce(this, initialValue, combine); 14568 return IterableMixinWorkaround.reduce(this, initialValue, combine);
14601 } 14569 }
14602 14570
14603 bool contains(Node element) => Collections.contains(this, element); 14571 bool contains(Node element) => IterableMixinWorkaround.contains(this, element) ;
14604 14572
14605 void forEach(void f(Node element)) => Collections.forEach(this, f); 14573 void forEach(void f(Node element)) => IterableMixinWorkaround.forEach(this, f) ;
14606 14574
14607 String join([String separator]) => Collections.joinList(this, separator); 14575 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
14608 14576
14609 List mappedBy(f(Node element)) => new MappedList<Node, dynamic>(this, f); 14577 List mappedBy(f(Node element)) => IterableMixinWorkaround.mappedByList(this, f );
14610 14578
14611 Iterable<Node> where(bool f(Node element)) => new WhereIterable<Node>(this, f) ; 14579 Iterable<Node> where(bool f(Node element)) => IterableMixinWorkaround.where(th is, f);
14612 14580
14613 bool every(bool f(Node element)) => Collections.every(this, f); 14581 bool every(bool f(Node element)) => IterableMixinWorkaround.every(this, f);
14614 14582
14615 bool any(bool f(Node element)) => Collections.any(this, f); 14583 bool any(bool f(Node element)) => IterableMixinWorkaround.any(this, f);
14616 14584
14617 List<Node> toList() => new List<Node>.from(this); 14585 List<Node> toList() => new List<Node>.from(this);
14618 Set<Node> toSet() => new Set<Node>.from(this); 14586 Set<Node> toSet() => new Set<Node>.from(this);
14619 14587
14620 bool get isEmpty => this.length == 0; 14588 bool get isEmpty => this.length == 0;
14621 14589
14622 List<Node> take(int n) => new ListView<Node>(this, 0, n); 14590 List<Node> take(int n) => IterableMixinWorkaround.takeList(this, n);
14623 14591
14624 Iterable<Node> takeWhile(bool test(Node value)) { 14592 Iterable<Node> takeWhile(bool test(Node value)) {
14625 return new TakeWhileIterable<Node>(this, test); 14593 return IterableMixinWorkaround.takeWhile(this, test);
14626 } 14594 }
14627 14595
14628 List<Node> skip(int n) => new ListView<Node>(this, n, null); 14596 List<Node> skip(int n) => IterableMixinWorkaround.skipList(this, n);
14629 14597
14630 Iterable<Node> skipWhile(bool test(Node value)) { 14598 Iterable<Node> skipWhile(bool test(Node value)) {
14631 return new SkipWhileIterable<Node>(this, test); 14599 return IterableMixinWorkaround.skipWhile(this, test);
14632 } 14600 }
14633 14601
14634 Node firstMatching(bool test(Node value), { Node orElse() }) { 14602 Node firstMatching(bool test(Node value), { Node orElse() }) {
14635 return Collections.firstMatching(this, test, orElse); 14603 return IterableMixinWorkaround.firstMatching(this, test, orElse);
14636 } 14604 }
14637 14605
14638 Node lastMatching(bool test(Node value), {Node orElse()}) { 14606 Node lastMatching(bool test(Node value), {Node orElse()}) {
14639 return Collections.lastMatchingInList(this, test, orElse); 14607 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
14640 } 14608 }
14641 14609
14642 Node singleMatching(bool test(Node value)) { 14610 Node singleMatching(bool test(Node value)) {
14643 return Collections.singleMatching(this, test); 14611 return IterableMixinWorkaround.singleMatching(this, test);
14644 } 14612 }
14645 14613
14646 Node elementAt(int index) { 14614 Node elementAt(int index) {
14647 return this[index]; 14615 return this[index];
14648 } 14616 }
14649 14617
14650 // From Collection<Node>: 14618 // From Collection<Node>:
14651 14619
14652 void add(Node value) { 14620 void add(Node value) {
14653 throw new UnsupportedError("Cannot add to immutable List."); 14621 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
14691 if (this.length > 0) return this[this.length - 1]; 14659 if (this.length > 0) return this[this.length - 1];
14692 throw new StateError("No elements"); 14660 throw new StateError("No elements");
14693 } 14661 }
14694 14662
14695 Node get single { 14663 Node get single {
14696 if (length == 1) return this[0]; 14664 if (length == 1) return this[0];
14697 if (length == 0) throw new StateError("No elements"); 14665 if (length == 0) throw new StateError("No elements");
14698 throw new StateError("More than one element"); 14666 throw new StateError("More than one element");
14699 } 14667 }
14700 14668
14701 Node min([int compare(Node a, Node b)]) => Collections.min(this, compare); 14669 Node min([int compare(Node a, Node b)]) => IterableMixinWorkaround.min(this, c ompare);
14702 14670
14703 Node max([int compare(Node a, Node b)]) => Collections.max(this, compare); 14671 Node max([int compare(Node a, Node b)]) => IterableMixinWorkaround.max(this, c ompare);
14704 14672
14705 Node removeAt(int pos) { 14673 Node removeAt(int pos) {
14706 throw new UnsupportedError("Cannot removeAt on immutable List."); 14674 throw new UnsupportedError("Cannot removeAt on immutable List.");
14707 } 14675 }
14708 14676
14709 Node removeLast() { 14677 Node removeLast() {
14710 throw new UnsupportedError("Cannot removeLast on immutable List."); 14678 throw new UnsupportedError("Cannot removeLast on immutable List.");
14711 } 14679 }
14712 14680
14713 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) { 14681 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) {
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
14888 return result; 14856 return result;
14889 } 14857 }
14890 Node get single { 14858 Node get single {
14891 int l = this.length; 14859 int l = this.length;
14892 if (l == 0) throw new StateError("No elements"); 14860 if (l == 0) throw new StateError("No elements");
14893 if (l > 1) throw new StateError("More than one element"); 14861 if (l > 1) throw new StateError("More than one element");
14894 return JS('Node', '#.firstChild', _this); 14862 return JS('Node', '#.firstChild', _this);
14895 } 14863 }
14896 14864
14897 Node min([int compare(Node a, Node b)]) { 14865 Node min([int compare(Node a, Node b)]) {
14898 return Collections.min(this, compare); 14866 return IterableMixinWorkaround.min(this, compare);
14899 } 14867 }
14900 14868
14901 Node max([int compare(Node a, Node b)]) { 14869 Node max([int compare(Node a, Node b)]) {
14902 return Collections.max(this, compare); 14870 return IterableMixinWorkaround.max(this, compare);
14903 } 14871 }
14904 14872
14905 void add(Node value) { 14873 void add(Node value) {
14906 _this.$dom_appendChild(value); 14874 _this.$dom_appendChild(value);
14907 } 14875 }
14908 14876
14909 void addLast(Node value) { 14877 void addLast(Node value) {
14910 _this.$dom_appendChild(value); 14878 _this.$dom_appendChild(value);
14911 } 14879 }
14912 14880
(...skipping 25 matching lines...) Expand all
14938 } 14906 }
14939 14907
14940 void operator []=(int index, Node value) { 14908 void operator []=(int index, Node value) {
14941 _this.$dom_replaceChild(value, this[index]); 14909 _this.$dom_replaceChild(value, this[index]);
14942 } 14910 }
14943 14911
14944 Iterator<Node> get iterator => _this.$dom_childNodes.iterator; 14912 Iterator<Node> get iterator => _this.$dom_childNodes.iterator;
14945 14913
14946 // TODO(jacobr): We can implement these methods much more efficiently by 14914 // TODO(jacobr): We can implement these methods much more efficiently by
14947 // looking up the nodeList only once instead of once per iteration. 14915 // looking up the nodeList only once instead of once per iteration.
14948 bool contains(Node element) => Collections.contains(this, element); 14916 bool contains(Node element) => IterableMixinWorkaround.contains(this, element) ;
14949 14917
14950 void forEach(void f(Node element)) => Collections.forEach(this, f); 14918 void forEach(void f(Node element)) => IterableMixinWorkaround.forEach(this, f) ;
14951 14919
14952 dynamic reduce(dynamic initialValue, 14920 dynamic reduce(dynamic initialValue,
14953 dynamic combine(dynamic previousValue, Node element)) { 14921 dynamic combine(dynamic previousValue, Node element)) {
14954 return Collections.reduce(this, initialValue, combine); 14922 return IterableMixinWorkaround.reduce(this, initialValue, combine);
14955 } 14923 }
14956 14924
14957 String join([String separator]) { 14925 String join([String separator]) {
14958 return Collections.joinList(this, separator); 14926 return IterableMixinWorkaround.joinList(this, separator);
14959 } 14927 }
14960 14928
14961 List mappedBy(f(Node element)) => 14929 List mappedBy(f(Node element)) {
14962 new MappedList<Node, dynamic>(this, f); 14930 return IterableMixinWorkaround.mappedByList(this, f);
14931 }
14963 14932
14964 Iterable<Node> where(bool f(Node element)) => 14933 Iterable<Node> where(bool f(Node element)) {
14965 new WhereIterable<Node>(this, f); 14934 return IterableMixinWorkaround.where(this, f);
14935 }
14966 14936
14967 bool every(bool f(Node element)) => Collections.every(this, f); 14937 bool every(bool f(Node element)) => IterableMixinWorkaround.every(this, f);
14968 14938
14969 bool any(bool f(Node element)) => Collections.any(this, f); 14939 bool any(bool f(Node element)) => IterableMixinWorkaround.any(this, f);
14970 14940
14971 List<Node> toList() => new List<Node>.from(this); 14941 List<Node> toList() => new List<Node>.from(this);
14972 Set<Node> toSet() => new Set<Node>.from(this); 14942 Set<Node> toSet() => new Set<Node>.from(this);
14973 14943
14974 bool get isEmpty => this.length == 0; 14944 bool get isEmpty => this.length == 0;
14975 14945
14976 // From List<Node>: 14946 // From List<Node>:
14977 14947
14978 List<Node> take(int n) { 14948 List<Node> take(int n) {
14979 return new ListView<Node>(this, 0, n); 14949 return IterableMixinWorkaround.takeList(this, n);
14980 } 14950 }
14981 14951
14982 Iterable<Node> takeWhile(bool test(Node value)) { 14952 Iterable<Node> takeWhile(bool test(Node value)) {
14983 return new TakeWhileIterable<Node>(this, test); 14953 return IterableMixinWorkaround.takeWhile(this, test);
14984 } 14954 }
14985 14955
14986 List<Node> skip(int n) { 14956 List<Node> skip(int n) {
14987 return new ListView<Node>(this, n, null); 14957 return IterableMixinWorkaround.skipList(this, n);
14988 } 14958 }
14989 14959
14990 Iterable<Node> skipWhile(bool test(Node value)) { 14960 Iterable<Node> skipWhile(bool test(Node value)) {
14991 return new SkipWhileIterable<Node>(this, test); 14961 return IterableMixinWorkaround.skipWhile(this, test);
14992 } 14962 }
14993 14963
14994 Node firstMatching(bool test(Node value), {Node orElse()}) { 14964 Node firstMatching(bool test(Node value), {Node orElse()}) {
14995 return Collections.firstMatching(this, test, orElse); 14965 return IterableMixinWorkaround.firstMatching(this, test, orElse);
14996 } 14966 }
14997 14967
14998 Node lastMatching(bool test(Node value), {Node orElse()}) { 14968 Node lastMatching(bool test(Node value), {Node orElse()}) {
14999 return Collections.lastMatchingInList(this, test, orElse); 14969 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
15000 } 14970 }
15001 14971
15002 Node singleMatching(bool test(Node value)) { 14972 Node singleMatching(bool test(Node value)) {
15003 return Collections.singleMatching(this, test); 14973 return IterableMixinWorkaround.singleMatching(this, test);
15004 } 14974 }
15005 14975
15006 Node elementAt(int index) { 14976 Node elementAt(int index) {
15007 return this[index]; 14977 return this[index];
15008 } 14978 }
15009 14979
15010 // TODO(jacobr): this could be implemented for child node lists. 14980 // TODO(jacobr): this could be implemented for child node lists.
15011 // The exception we throw here is misleading. 14981 // The exception we throw here is misleading.
15012 void sort([int compare(Node a, Node b)]) { 14982 void sort([int compare(Node a, Node b)]) {
15013 throw new UnsupportedError("Cannot sort immutable List."); 14983 throw new UnsupportedError("Cannot sort immutable List.");
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
15285 // From Iterable<Node>: 15255 // From Iterable<Node>:
15286 15256
15287 Iterator<Node> get iterator { 15257 Iterator<Node> get iterator {
15288 // Note: NodeLists are not fixed size. And most probably length shouldn't 15258 // Note: NodeLists are not fixed size. And most probably length shouldn't
15289 // be cached in both iterator _and_ forEach method. For now caching it 15259 // be cached in both iterator _and_ forEach method. For now caching it
15290 // for consistency. 15260 // for consistency.
15291 return new FixedSizeListIterator<Node>(this); 15261 return new FixedSizeListIterator<Node>(this);
15292 } 15262 }
15293 15263
15294 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) { 15264 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Node)) {
15295 return Collections.reduce(this, initialValue, combine); 15265 return IterableMixinWorkaround.reduce(this, initialValue, combine);
15296 } 15266 }
15297 15267
15298 bool contains(Node element) => Collections.contains(this, element); 15268 bool contains(Node element) => IterableMixinWorkaround.contains(this, element) ;
15299 15269
15300 void forEach(void f(Node element)) => Collections.forEach(this, f); 15270 void forEach(void f(Node element)) => IterableMixinWorkaround.forEach(this, f) ;
15301 15271
15302 String join([String separator]) => Collections.joinList(this, separator); 15272 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
15303 15273
15304 List mappedBy(f(Node element)) => new MappedList<Node, dynamic>(this, f); 15274 List mappedBy(f(Node element)) => IterableMixinWorkaround.mappedByList(this, f );
15305 15275
15306 Iterable<Node> where(bool f(Node element)) => new WhereIterable<Node>(this, f) ; 15276 Iterable<Node> where(bool f(Node element)) => IterableMixinWorkaround.where(th is, f);
15307 15277
15308 bool every(bool f(Node element)) => Collections.every(this, f); 15278 bool every(bool f(Node element)) => IterableMixinWorkaround.every(this, f);
15309 15279
15310 bool any(bool f(Node element)) => Collections.any(this, f); 15280 bool any(bool f(Node element)) => IterableMixinWorkaround.any(this, f);
15311 15281
15312 List<Node> toList() => new List<Node>.from(this); 15282 List<Node> toList() => new List<Node>.from(this);
15313 Set<Node> toSet() => new Set<Node>.from(this); 15283 Set<Node> toSet() => new Set<Node>.from(this);
15314 15284
15315 bool get isEmpty => this.length == 0; 15285 bool get isEmpty => this.length == 0;
15316 15286
15317 List<Node> take(int n) => new ListView<Node>(this, 0, n); 15287 List<Node> take(int n) => IterableMixinWorkaround.takeList(this, n);
15318 15288
15319 Iterable<Node> takeWhile(bool test(Node value)) { 15289 Iterable<Node> takeWhile(bool test(Node value)) {
15320 return new TakeWhileIterable<Node>(this, test); 15290 return IterableMixinWorkaround.takeWhile(this, test);
15321 } 15291 }
15322 15292
15323 List<Node> skip(int n) => new ListView<Node>(this, n, null); 15293 List<Node> skip(int n) => IterableMixinWorkaround.skipList(this, n);
15324 15294
15325 Iterable<Node> skipWhile(bool test(Node value)) { 15295 Iterable<Node> skipWhile(bool test(Node value)) {
15326 return new SkipWhileIterable<Node>(this, test); 15296 return IterableMixinWorkaround.skipWhile(this, test);
15327 } 15297 }
15328 15298
15329 Node firstMatching(bool test(Node value), { Node orElse() }) { 15299 Node firstMatching(bool test(Node value), { Node orElse() }) {
15330 return Collections.firstMatching(this, test, orElse); 15300 return IterableMixinWorkaround.firstMatching(this, test, orElse);
15331 } 15301 }
15332 15302
15333 Node lastMatching(bool test(Node value), {Node orElse()}) { 15303 Node lastMatching(bool test(Node value), {Node orElse()}) {
15334 return Collections.lastMatchingInList(this, test, orElse); 15304 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
15335 } 15305 }
15336 15306
15337 Node singleMatching(bool test(Node value)) { 15307 Node singleMatching(bool test(Node value)) {
15338 return Collections.singleMatching(this, test); 15308 return IterableMixinWorkaround.singleMatching(this, test);
15339 } 15309 }
15340 15310
15341 Node elementAt(int index) { 15311 Node elementAt(int index) {
15342 return this[index]; 15312 return this[index];
15343 } 15313 }
15344 15314
15345 // From Collection<Node>: 15315 // From Collection<Node>:
15346 15316
15347 void add(Node value) { 15317 void add(Node value) {
15348 throw new UnsupportedError("Cannot add to immutable List."); 15318 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
15386 if (this.length > 0) return this[this.length - 1]; 15356 if (this.length > 0) return this[this.length - 1];
15387 throw new StateError("No elements"); 15357 throw new StateError("No elements");
15388 } 15358 }
15389 15359
15390 Node get single { 15360 Node get single {
15391 if (length == 1) return this[0]; 15361 if (length == 1) return this[0];
15392 if (length == 0) throw new StateError("No elements"); 15362 if (length == 0) throw new StateError("No elements");
15393 throw new StateError("More than one element"); 15363 throw new StateError("More than one element");
15394 } 15364 }
15395 15365
15396 Node min([int compare(Node a, Node b)]) => Collections.min(this, compare); 15366 Node min([int compare(Node a, Node b)]) => IterableMixinWorkaround.min(this, c ompare);
15397 15367
15398 Node max([int compare(Node a, Node b)]) => Collections.max(this, compare); 15368 Node max([int compare(Node a, Node b)]) => IterableMixinWorkaround.max(this, c ompare);
15399 15369
15400 Node removeAt(int pos) { 15370 Node removeAt(int pos) {
15401 throw new UnsupportedError("Cannot removeAt on immutable List."); 15371 throw new UnsupportedError("Cannot removeAt on immutable List.");
15402 } 15372 }
15403 15373
15404 Node removeLast() { 15374 Node removeLast() {
15405 throw new UnsupportedError("Cannot removeLast on immutable List."); 15375 throw new UnsupportedError("Cannot removeLast on immutable List.");
15406 } 15376 }
15407 15377
15408 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) { 15378 void setRange(int start, int rangeLength, List<Node> from, [int startFrom]) {
(...skipping 1826 matching lines...) Expand 10 before | Expand all | Expand 10 after
17235 // From Iterable<SourceBuffer>: 17205 // From Iterable<SourceBuffer>:
17236 17206
17237 Iterator<SourceBuffer> get iterator { 17207 Iterator<SourceBuffer> get iterator {
17238 // Note: NodeLists are not fixed size. And most probably length shouldn't 17208 // Note: NodeLists are not fixed size. And most probably length shouldn't
17239 // be cached in both iterator _and_ forEach method. For now caching it 17209 // be cached in both iterator _and_ forEach method. For now caching it
17240 // for consistency. 17210 // for consistency.
17241 return new FixedSizeListIterator<SourceBuffer>(this); 17211 return new FixedSizeListIterator<SourceBuffer>(this);
17242 } 17212 }
17243 17213
17244 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SourceBuffer)) { 17214 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SourceBuffer)) {
17245 return Collections.reduce(this, initialValue, combine); 17215 return IterableMixinWorkaround.reduce(this, initialValue, combine);
17246 } 17216 }
17247 17217
17248 bool contains(SourceBuffer element) => Collections.contains(this, element); 17218 bool contains(SourceBuffer element) => IterableMixinWorkaround.contains(this, element);
17249 17219
17250 void forEach(void f(SourceBuffer element)) => Collections.forEach(this, f); 17220 void forEach(void f(SourceBuffer element)) => IterableMixinWorkaround.forEach( this, f);
17251 17221
17252 String join([String separator]) => Collections.joinList(this, separator); 17222 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
17253 17223
17254 List mappedBy(f(SourceBuffer element)) => new MappedList<SourceBuffer, dynamic >(this, f); 17224 List mappedBy(f(SourceBuffer element)) => IterableMixinWorkaround.mappedByList (this, f);
17255 17225
17256 Iterable<SourceBuffer> where(bool f(SourceBuffer element)) => new WhereIterabl e<SourceBuffer>(this, f); 17226 Iterable<SourceBuffer> where(bool f(SourceBuffer element)) => IterableMixinWor karound.where(this, f);
17257 17227
17258 bool every(bool f(SourceBuffer element)) => Collections.every(this, f); 17228 bool every(bool f(SourceBuffer element)) => IterableMixinWorkaround.every(this , f);
17259 17229
17260 bool any(bool f(SourceBuffer element)) => Collections.any(this, f); 17230 bool any(bool f(SourceBuffer element)) => IterableMixinWorkaround.any(this, f) ;
17261 17231
17262 List<SourceBuffer> toList() => new List<SourceBuffer>.from(this); 17232 List<SourceBuffer> toList() => new List<SourceBuffer>.from(this);
17263 Set<SourceBuffer> toSet() => new Set<SourceBuffer>.from(this); 17233 Set<SourceBuffer> toSet() => new Set<SourceBuffer>.from(this);
17264 17234
17265 bool get isEmpty => this.length == 0; 17235 bool get isEmpty => this.length == 0;
17266 17236
17267 List<SourceBuffer> take(int n) => new ListView<SourceBuffer>(this, 0, n); 17237 List<SourceBuffer> take(int n) => IterableMixinWorkaround.takeList(this, n);
17268 17238
17269 Iterable<SourceBuffer> takeWhile(bool test(SourceBuffer value)) { 17239 Iterable<SourceBuffer> takeWhile(bool test(SourceBuffer value)) {
17270 return new TakeWhileIterable<SourceBuffer>(this, test); 17240 return IterableMixinWorkaround.takeWhile(this, test);
17271 } 17241 }
17272 17242
17273 List<SourceBuffer> skip(int n) => new ListView<SourceBuffer>(this, n, null); 17243 List<SourceBuffer> skip(int n) => IterableMixinWorkaround.skipList(this, n);
17274 17244
17275 Iterable<SourceBuffer> skipWhile(bool test(SourceBuffer value)) { 17245 Iterable<SourceBuffer> skipWhile(bool test(SourceBuffer value)) {
17276 return new SkipWhileIterable<SourceBuffer>(this, test); 17246 return IterableMixinWorkaround.skipWhile(this, test);
17277 } 17247 }
17278 17248
17279 SourceBuffer firstMatching(bool test(SourceBuffer value), { SourceBuffer orEls e() }) { 17249 SourceBuffer firstMatching(bool test(SourceBuffer value), { SourceBuffer orEls e() }) {
17280 return Collections.firstMatching(this, test, orElse); 17250 return IterableMixinWorkaround.firstMatching(this, test, orElse);
17281 } 17251 }
17282 17252
17283 SourceBuffer lastMatching(bool test(SourceBuffer value), {SourceBuffer orElse( )}) { 17253 SourceBuffer lastMatching(bool test(SourceBuffer value), {SourceBuffer orElse( )}) {
17284 return Collections.lastMatchingInList(this, test, orElse); 17254 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
17285 } 17255 }
17286 17256
17287 SourceBuffer singleMatching(bool test(SourceBuffer value)) { 17257 SourceBuffer singleMatching(bool test(SourceBuffer value)) {
17288 return Collections.singleMatching(this, test); 17258 return IterableMixinWorkaround.singleMatching(this, test);
17289 } 17259 }
17290 17260
17291 SourceBuffer elementAt(int index) { 17261 SourceBuffer elementAt(int index) {
17292 return this[index]; 17262 return this[index];
17293 } 17263 }
17294 17264
17295 // From Collection<SourceBuffer>: 17265 // From Collection<SourceBuffer>:
17296 17266
17297 void add(SourceBuffer value) { 17267 void add(SourceBuffer value) {
17298 throw new UnsupportedError("Cannot add to immutable List."); 17268 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
17336 if (this.length > 0) return this[this.length - 1]; 17306 if (this.length > 0) return this[this.length - 1];
17337 throw new StateError("No elements"); 17307 throw new StateError("No elements");
17338 } 17308 }
17339 17309
17340 SourceBuffer get single { 17310 SourceBuffer get single {
17341 if (length == 1) return this[0]; 17311 if (length == 1) return this[0];
17342 if (length == 0) throw new StateError("No elements"); 17312 if (length == 0) throw new StateError("No elements");
17343 throw new StateError("More than one element"); 17313 throw new StateError("More than one element");
17344 } 17314 }
17345 17315
17346 SourceBuffer min([int compare(SourceBuffer a, SourceBuffer b)]) => Collections .min(this, compare); 17316 SourceBuffer min([int compare(SourceBuffer a, SourceBuffer b)]) => IterableMix inWorkaround.min(this, compare);
17347 17317
17348 SourceBuffer max([int compare(SourceBuffer a, SourceBuffer b)]) => Collections .max(this, compare); 17318 SourceBuffer max([int compare(SourceBuffer a, SourceBuffer b)]) => IterableMix inWorkaround.max(this, compare);
17349 17319
17350 SourceBuffer removeAt(int pos) { 17320 SourceBuffer removeAt(int pos) {
17351 throw new UnsupportedError("Cannot removeAt on immutable List."); 17321 throw new UnsupportedError("Cannot removeAt on immutable List.");
17352 } 17322 }
17353 17323
17354 SourceBuffer removeLast() { 17324 SourceBuffer removeLast() {
17355 throw new UnsupportedError("Cannot removeLast on immutable List."); 17325 throw new UnsupportedError("Cannot removeLast on immutable List.");
17356 } 17326 }
17357 17327
17358 void setRange(int start, int rangeLength, List<SourceBuffer> from, [int startF rom]) { 17328 void setRange(int start, int rangeLength, List<SourceBuffer> from, [int startF rom]) {
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
17462 // From Iterable<SpeechGrammar>: 17432 // From Iterable<SpeechGrammar>:
17463 17433
17464 Iterator<SpeechGrammar> get iterator { 17434 Iterator<SpeechGrammar> get iterator {
17465 // Note: NodeLists are not fixed size. And most probably length shouldn't 17435 // Note: NodeLists are not fixed size. And most probably length shouldn't
17466 // be cached in both iterator _and_ forEach method. For now caching it 17436 // be cached in both iterator _and_ forEach method. For now caching it
17467 // for consistency. 17437 // for consistency.
17468 return new FixedSizeListIterator<SpeechGrammar>(this); 17438 return new FixedSizeListIterator<SpeechGrammar>(this);
17469 } 17439 }
17470 17440
17471 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechGrammar)) { 17441 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechGrammar)) {
17472 return Collections.reduce(this, initialValue, combine); 17442 return IterableMixinWorkaround.reduce(this, initialValue, combine);
17473 } 17443 }
17474 17444
17475 bool contains(SpeechGrammar element) => Collections.contains(this, element); 17445 bool contains(SpeechGrammar element) => IterableMixinWorkaround.contains(this, element);
17476 17446
17477 void forEach(void f(SpeechGrammar element)) => Collections.forEach(this, f); 17447 void forEach(void f(SpeechGrammar element)) => IterableMixinWorkaround.forEach (this, f);
17478 17448
17479 String join([String separator]) => Collections.joinList(this, separator); 17449 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
17480 17450
17481 List mappedBy(f(SpeechGrammar element)) => new MappedList<SpeechGrammar, dynam ic>(this, f); 17451 List mappedBy(f(SpeechGrammar element)) => IterableMixinWorkaround.mappedByLis t(this, f);
17482 17452
17483 Iterable<SpeechGrammar> where(bool f(SpeechGrammar element)) => new WhereItera ble<SpeechGrammar>(this, f); 17453 Iterable<SpeechGrammar> where(bool f(SpeechGrammar element)) => IterableMixinW orkaround.where(this, f);
17484 17454
17485 bool every(bool f(SpeechGrammar element)) => Collections.every(this, f); 17455 bool every(bool f(SpeechGrammar element)) => IterableMixinWorkaround.every(thi s, f);
17486 17456
17487 bool any(bool f(SpeechGrammar element)) => Collections.any(this, f); 17457 bool any(bool f(SpeechGrammar element)) => IterableMixinWorkaround.any(this, f );
17488 17458
17489 List<SpeechGrammar> toList() => new List<SpeechGrammar>.from(this); 17459 List<SpeechGrammar> toList() => new List<SpeechGrammar>.from(this);
17490 Set<SpeechGrammar> toSet() => new Set<SpeechGrammar>.from(this); 17460 Set<SpeechGrammar> toSet() => new Set<SpeechGrammar>.from(this);
17491 17461
17492 bool get isEmpty => this.length == 0; 17462 bool get isEmpty => this.length == 0;
17493 17463
17494 List<SpeechGrammar> take(int n) => new ListView<SpeechGrammar>(this, 0, n); 17464 List<SpeechGrammar> take(int n) => IterableMixinWorkaround.takeList(this, n);
17495 17465
17496 Iterable<SpeechGrammar> takeWhile(bool test(SpeechGrammar value)) { 17466 Iterable<SpeechGrammar> takeWhile(bool test(SpeechGrammar value)) {
17497 return new TakeWhileIterable<SpeechGrammar>(this, test); 17467 return IterableMixinWorkaround.takeWhile(this, test);
17498 } 17468 }
17499 17469
17500 List<SpeechGrammar> skip(int n) => new ListView<SpeechGrammar>(this, n, null); 17470 List<SpeechGrammar> skip(int n) => IterableMixinWorkaround.skipList(this, n);
17501 17471
17502 Iterable<SpeechGrammar> skipWhile(bool test(SpeechGrammar value)) { 17472 Iterable<SpeechGrammar> skipWhile(bool test(SpeechGrammar value)) {
17503 return new SkipWhileIterable<SpeechGrammar>(this, test); 17473 return IterableMixinWorkaround.skipWhile(this, test);
17504 } 17474 }
17505 17475
17506 SpeechGrammar firstMatching(bool test(SpeechGrammar value), { SpeechGrammar or Else() }) { 17476 SpeechGrammar firstMatching(bool test(SpeechGrammar value), { SpeechGrammar or Else() }) {
17507 return Collections.firstMatching(this, test, orElse); 17477 return IterableMixinWorkaround.firstMatching(this, test, orElse);
17508 } 17478 }
17509 17479
17510 SpeechGrammar lastMatching(bool test(SpeechGrammar value), {SpeechGrammar orEl se()}) { 17480 SpeechGrammar lastMatching(bool test(SpeechGrammar value), {SpeechGrammar orEl se()}) {
17511 return Collections.lastMatchingInList(this, test, orElse); 17481 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
17512 } 17482 }
17513 17483
17514 SpeechGrammar singleMatching(bool test(SpeechGrammar value)) { 17484 SpeechGrammar singleMatching(bool test(SpeechGrammar value)) {
17515 return Collections.singleMatching(this, test); 17485 return IterableMixinWorkaround.singleMatching(this, test);
17516 } 17486 }
17517 17487
17518 SpeechGrammar elementAt(int index) { 17488 SpeechGrammar elementAt(int index) {
17519 return this[index]; 17489 return this[index];
17520 } 17490 }
17521 17491
17522 // From Collection<SpeechGrammar>: 17492 // From Collection<SpeechGrammar>:
17523 17493
17524 void add(SpeechGrammar value) { 17494 void add(SpeechGrammar value) {
17525 throw new UnsupportedError("Cannot add to immutable List."); 17495 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
17563 if (this.length > 0) return this[this.length - 1]; 17533 if (this.length > 0) return this[this.length - 1];
17564 throw new StateError("No elements"); 17534 throw new StateError("No elements");
17565 } 17535 }
17566 17536
17567 SpeechGrammar get single { 17537 SpeechGrammar get single {
17568 if (length == 1) return this[0]; 17538 if (length == 1) return this[0];
17569 if (length == 0) throw new StateError("No elements"); 17539 if (length == 0) throw new StateError("No elements");
17570 throw new StateError("More than one element"); 17540 throw new StateError("More than one element");
17571 } 17541 }
17572 17542
17573 SpeechGrammar min([int compare(SpeechGrammar a, SpeechGrammar b)]) => Collecti ons.min(this, compare); 17543 SpeechGrammar min([int compare(SpeechGrammar a, SpeechGrammar b)]) => Iterable MixinWorkaround.min(this, compare);
17574 17544
17575 SpeechGrammar max([int compare(SpeechGrammar a, SpeechGrammar b)]) => Collecti ons.max(this, compare); 17545 SpeechGrammar max([int compare(SpeechGrammar a, SpeechGrammar b)]) => Iterable MixinWorkaround.max(this, compare);
17576 17546
17577 SpeechGrammar removeAt(int pos) { 17547 SpeechGrammar removeAt(int pos) {
17578 throw new UnsupportedError("Cannot removeAt on immutable List."); 17548 throw new UnsupportedError("Cannot removeAt on immutable List.");
17579 } 17549 }
17580 17550
17581 SpeechGrammar removeLast() { 17551 SpeechGrammar removeLast() {
17582 throw new UnsupportedError("Cannot removeLast on immutable List."); 17552 throw new UnsupportedError("Cannot removeLast on immutable List.");
17583 } 17553 }
17584 17554
17585 void setRange(int start, int rangeLength, List<SpeechGrammar> from, [int start From]) { 17555 void setRange(int start, int rangeLength, List<SpeechGrammar> from, [int start From]) {
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
17935 // From Iterable<Map>: 17905 // From Iterable<Map>:
17936 17906
17937 Iterator<Map> get iterator { 17907 Iterator<Map> get iterator {
17938 // Note: NodeLists are not fixed size. And most probably length shouldn't 17908 // Note: NodeLists are not fixed size. And most probably length shouldn't
17939 // be cached in both iterator _and_ forEach method. For now caching it 17909 // be cached in both iterator _and_ forEach method. For now caching it
17940 // for consistency. 17910 // for consistency.
17941 return new FixedSizeListIterator<Map>(this); 17911 return new FixedSizeListIterator<Map>(this);
17942 } 17912 }
17943 17913
17944 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Map)) { 17914 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Map)) {
17945 return Collections.reduce(this, initialValue, combine); 17915 return IterableMixinWorkaround.reduce(this, initialValue, combine);
17946 } 17916 }
17947 17917
17948 bool contains(Map element) => Collections.contains(this, element); 17918 bool contains(Map element) => IterableMixinWorkaround.contains(this, element);
17949 17919
17950 void forEach(void f(Map element)) => Collections.forEach(this, f); 17920 void forEach(void f(Map element)) => IterableMixinWorkaround.forEach(this, f);
17951 17921
17952 String join([String separator]) => Collections.joinList(this, separator); 17922 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
17953 17923
17954 List mappedBy(f(Map element)) => new MappedList<Map, dynamic>(this, f); 17924 List mappedBy(f(Map element)) => IterableMixinWorkaround.mappedByList(this, f) ;
17955 17925
17956 Iterable<Map> where(bool f(Map element)) => new WhereIterable<Map>(this, f); 17926 Iterable<Map> where(bool f(Map element)) => IterableMixinWorkaround.where(this , f);
17957 17927
17958 bool every(bool f(Map element)) => Collections.every(this, f); 17928 bool every(bool f(Map element)) => IterableMixinWorkaround.every(this, f);
17959 17929
17960 bool any(bool f(Map element)) => Collections.any(this, f); 17930 bool any(bool f(Map element)) => IterableMixinWorkaround.any(this, f);
17961 17931
17962 List<Map> toList() => new List<Map>.from(this); 17932 List<Map> toList() => new List<Map>.from(this);
17963 Set<Map> toSet() => new Set<Map>.from(this); 17933 Set<Map> toSet() => new Set<Map>.from(this);
17964 17934
17965 bool get isEmpty => this.length == 0; 17935 bool get isEmpty => this.length == 0;
17966 17936
17967 List<Map> take(int n) => new ListView<Map>(this, 0, n); 17937 List<Map> take(int n) => IterableMixinWorkaround.takeList(this, n);
17968 17938
17969 Iterable<Map> takeWhile(bool test(Map value)) { 17939 Iterable<Map> takeWhile(bool test(Map value)) {
17970 return new TakeWhileIterable<Map>(this, test); 17940 return IterableMixinWorkaround.takeWhile(this, test);
17971 } 17941 }
17972 17942
17973 List<Map> skip(int n) => new ListView<Map>(this, n, null); 17943 List<Map> skip(int n) => IterableMixinWorkaround.skipList(this, n);
17974 17944
17975 Iterable<Map> skipWhile(bool test(Map value)) { 17945 Iterable<Map> skipWhile(bool test(Map value)) {
17976 return new SkipWhileIterable<Map>(this, test); 17946 return IterableMixinWorkaround.skipWhile(this, test);
17977 } 17947 }
17978 17948
17979 Map firstMatching(bool test(Map value), { Map orElse() }) { 17949 Map firstMatching(bool test(Map value), { Map orElse() }) {
17980 return Collections.firstMatching(this, test, orElse); 17950 return IterableMixinWorkaround.firstMatching(this, test, orElse);
17981 } 17951 }
17982 17952
17983 Map lastMatching(bool test(Map value), {Map orElse()}) { 17953 Map lastMatching(bool test(Map value), {Map orElse()}) {
17984 return Collections.lastMatchingInList(this, test, orElse); 17954 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
17985 } 17955 }
17986 17956
17987 Map singleMatching(bool test(Map value)) { 17957 Map singleMatching(bool test(Map value)) {
17988 return Collections.singleMatching(this, test); 17958 return IterableMixinWorkaround.singleMatching(this, test);
17989 } 17959 }
17990 17960
17991 Map elementAt(int index) { 17961 Map elementAt(int index) {
17992 return this[index]; 17962 return this[index];
17993 } 17963 }
17994 17964
17995 // From Collection<Map>: 17965 // From Collection<Map>:
17996 17966
17997 void add(Map value) { 17967 void add(Map value) {
17998 throw new UnsupportedError("Cannot add to immutable List."); 17968 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
18036 if (this.length > 0) return this[this.length - 1]; 18006 if (this.length > 0) return this[this.length - 1];
18037 throw new StateError("No elements"); 18007 throw new StateError("No elements");
18038 } 18008 }
18039 18009
18040 Map get single { 18010 Map get single {
18041 if (length == 1) return this[0]; 18011 if (length == 1) return this[0];
18042 if (length == 0) throw new StateError("No elements"); 18012 if (length == 0) throw new StateError("No elements");
18043 throw new StateError("More than one element"); 18013 throw new StateError("More than one element");
18044 } 18014 }
18045 18015
18046 Map min([int compare(Map a, Map b)]) => Collections.min(this, compare); 18016 Map min([int compare(Map a, Map b)]) => IterableMixinWorkaround.min(this, comp are);
18047 18017
18048 Map max([int compare(Map a, Map b)]) => Collections.max(this, compare); 18018 Map max([int compare(Map a, Map b)]) => IterableMixinWorkaround.max(this, comp are);
18049 18019
18050 Map removeAt(int pos) { 18020 Map removeAt(int pos) {
18051 throw new UnsupportedError("Cannot removeAt on immutable List."); 18021 throw new UnsupportedError("Cannot removeAt on immutable List.");
18052 } 18022 }
18053 18023
18054 Map removeLast() { 18024 Map removeLast() {
18055 throw new UnsupportedError("Cannot removeLast on immutable List."); 18025 throw new UnsupportedError("Cannot removeLast on immutable List.");
18056 } 18026 }
18057 18027
18058 void setRange(int start, int rangeLength, List<Map> from, [int startFrom]) { 18028 void setRange(int start, int rangeLength, List<Map> from, [int startFrom]) {
(...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after
18797 // From Iterable<TextTrackCue>: 18767 // From Iterable<TextTrackCue>:
18798 18768
18799 Iterator<TextTrackCue> get iterator { 18769 Iterator<TextTrackCue> get iterator {
18800 // Note: NodeLists are not fixed size. And most probably length shouldn't 18770 // Note: NodeLists are not fixed size. And most probably length shouldn't
18801 // be cached in both iterator _and_ forEach method. For now caching it 18771 // be cached in both iterator _and_ forEach method. For now caching it
18802 // for consistency. 18772 // for consistency.
18803 return new FixedSizeListIterator<TextTrackCue>(this); 18773 return new FixedSizeListIterator<TextTrackCue>(this);
18804 } 18774 }
18805 18775
18806 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, TextTrackCue)) { 18776 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, TextTrackCue)) {
18807 return Collections.reduce(this, initialValue, combine); 18777 return IterableMixinWorkaround.reduce(this, initialValue, combine);
18808 } 18778 }
18809 18779
18810 bool contains(TextTrackCue element) => Collections.contains(this, element); 18780 bool contains(TextTrackCue element) => IterableMixinWorkaround.contains(this, element);
18811 18781
18812 void forEach(void f(TextTrackCue element)) => Collections.forEach(this, f); 18782 void forEach(void f(TextTrackCue element)) => IterableMixinWorkaround.forEach( this, f);
18813 18783
18814 String join([String separator]) => Collections.joinList(this, separator); 18784 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
18815 18785
18816 List mappedBy(f(TextTrackCue element)) => new MappedList<TextTrackCue, dynamic >(this, f); 18786 List mappedBy(f(TextTrackCue element)) => IterableMixinWorkaround.mappedByList (this, f);
18817 18787
18818 Iterable<TextTrackCue> where(bool f(TextTrackCue element)) => new WhereIterabl e<TextTrackCue>(this, f); 18788 Iterable<TextTrackCue> where(bool f(TextTrackCue element)) => IterableMixinWor karound.where(this, f);
18819 18789
18820 bool every(bool f(TextTrackCue element)) => Collections.every(this, f); 18790 bool every(bool f(TextTrackCue element)) => IterableMixinWorkaround.every(this , f);
18821 18791
18822 bool any(bool f(TextTrackCue element)) => Collections.any(this, f); 18792 bool any(bool f(TextTrackCue element)) => IterableMixinWorkaround.any(this, f) ;
18823 18793
18824 List<TextTrackCue> toList() => new List<TextTrackCue>.from(this); 18794 List<TextTrackCue> toList() => new List<TextTrackCue>.from(this);
18825 Set<TextTrackCue> toSet() => new Set<TextTrackCue>.from(this); 18795 Set<TextTrackCue> toSet() => new Set<TextTrackCue>.from(this);
18826 18796
18827 bool get isEmpty => this.length == 0; 18797 bool get isEmpty => this.length == 0;
18828 18798
18829 List<TextTrackCue> take(int n) => new ListView<TextTrackCue>(this, 0, n); 18799 List<TextTrackCue> take(int n) => IterableMixinWorkaround.takeList(this, n);
18830 18800
18831 Iterable<TextTrackCue> takeWhile(bool test(TextTrackCue value)) { 18801 Iterable<TextTrackCue> takeWhile(bool test(TextTrackCue value)) {
18832 return new TakeWhileIterable<TextTrackCue>(this, test); 18802 return IterableMixinWorkaround.takeWhile(this, test);
18833 } 18803 }
18834 18804
18835 List<TextTrackCue> skip(int n) => new ListView<TextTrackCue>(this, n, null); 18805 List<TextTrackCue> skip(int n) => IterableMixinWorkaround.skipList(this, n);
18836 18806
18837 Iterable<TextTrackCue> skipWhile(bool test(TextTrackCue value)) { 18807 Iterable<TextTrackCue> skipWhile(bool test(TextTrackCue value)) {
18838 return new SkipWhileIterable<TextTrackCue>(this, test); 18808 return IterableMixinWorkaround.skipWhile(this, test);
18839 } 18809 }
18840 18810
18841 TextTrackCue firstMatching(bool test(TextTrackCue value), { TextTrackCue orEls e() }) { 18811 TextTrackCue firstMatching(bool test(TextTrackCue value), { TextTrackCue orEls e() }) {
18842 return Collections.firstMatching(this, test, orElse); 18812 return IterableMixinWorkaround.firstMatching(this, test, orElse);
18843 } 18813 }
18844 18814
18845 TextTrackCue lastMatching(bool test(TextTrackCue value), {TextTrackCue orElse( )}) { 18815 TextTrackCue lastMatching(bool test(TextTrackCue value), {TextTrackCue orElse( )}) {
18846 return Collections.lastMatchingInList(this, test, orElse); 18816 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
18847 } 18817 }
18848 18818
18849 TextTrackCue singleMatching(bool test(TextTrackCue value)) { 18819 TextTrackCue singleMatching(bool test(TextTrackCue value)) {
18850 return Collections.singleMatching(this, test); 18820 return IterableMixinWorkaround.singleMatching(this, test);
18851 } 18821 }
18852 18822
18853 TextTrackCue elementAt(int index) { 18823 TextTrackCue elementAt(int index) {
18854 return this[index]; 18824 return this[index];
18855 } 18825 }
18856 18826
18857 // From Collection<TextTrackCue>: 18827 // From Collection<TextTrackCue>:
18858 18828
18859 void add(TextTrackCue value) { 18829 void add(TextTrackCue value) {
18860 throw new UnsupportedError("Cannot add to immutable List."); 18830 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
18898 if (this.length > 0) return this[this.length - 1]; 18868 if (this.length > 0) return this[this.length - 1];
18899 throw new StateError("No elements"); 18869 throw new StateError("No elements");
18900 } 18870 }
18901 18871
18902 TextTrackCue get single { 18872 TextTrackCue get single {
18903 if (length == 1) return this[0]; 18873 if (length == 1) return this[0];
18904 if (length == 0) throw new StateError("No elements"); 18874 if (length == 0) throw new StateError("No elements");
18905 throw new StateError("More than one element"); 18875 throw new StateError("More than one element");
18906 } 18876 }
18907 18877
18908 TextTrackCue min([int compare(TextTrackCue a, TextTrackCue b)]) => Collections .min(this, compare); 18878 TextTrackCue min([int compare(TextTrackCue a, TextTrackCue b)]) => IterableMix inWorkaround.min(this, compare);
18909 18879
18910 TextTrackCue max([int compare(TextTrackCue a, TextTrackCue b)]) => Collections .max(this, compare); 18880 TextTrackCue max([int compare(TextTrackCue a, TextTrackCue b)]) => IterableMix inWorkaround.max(this, compare);
18911 18881
18912 TextTrackCue removeAt(int pos) { 18882 TextTrackCue removeAt(int pos) {
18913 throw new UnsupportedError("Cannot removeAt on immutable List."); 18883 throw new UnsupportedError("Cannot removeAt on immutable List.");
18914 } 18884 }
18915 18885
18916 TextTrackCue removeLast() { 18886 TextTrackCue removeLast() {
18917 throw new UnsupportedError("Cannot removeLast on immutable List."); 18887 throw new UnsupportedError("Cannot removeLast on immutable List.");
18918 } 18888 }
18919 18889
18920 void setRange(int start, int rangeLength, List<TextTrackCue> from, [int startF rom]) { 18890 void setRange(int start, int rangeLength, List<TextTrackCue> from, [int startF rom]) {
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
18968 // From Iterable<TextTrack>: 18938 // From Iterable<TextTrack>:
18969 18939
18970 Iterator<TextTrack> get iterator { 18940 Iterator<TextTrack> get iterator {
18971 // Note: NodeLists are not fixed size. And most probably length shouldn't 18941 // Note: NodeLists are not fixed size. And most probably length shouldn't
18972 // be cached in both iterator _and_ forEach method. For now caching it 18942 // be cached in both iterator _and_ forEach method. For now caching it
18973 // for consistency. 18943 // for consistency.
18974 return new FixedSizeListIterator<TextTrack>(this); 18944 return new FixedSizeListIterator<TextTrack>(this);
18975 } 18945 }
18976 18946
18977 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, TextTrack)) { 18947 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, TextTrack)) {
18978 return Collections.reduce(this, initialValue, combine); 18948 return IterableMixinWorkaround.reduce(this, initialValue, combine);
18979 } 18949 }
18980 18950
18981 bool contains(TextTrack element) => Collections.contains(this, element); 18951 bool contains(TextTrack element) => IterableMixinWorkaround.contains(this, ele ment);
18982 18952
18983 void forEach(void f(TextTrack element)) => Collections.forEach(this, f); 18953 void forEach(void f(TextTrack element)) => IterableMixinWorkaround.forEach(thi s, f);
18984 18954
18985 String join([String separator]) => Collections.joinList(this, separator); 18955 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
18986 18956
18987 List mappedBy(f(TextTrack element)) => new MappedList<TextTrack, dynamic>(this , f); 18957 List mappedBy(f(TextTrack element)) => IterableMixinWorkaround.mappedByList(th is, f);
18988 18958
18989 Iterable<TextTrack> where(bool f(TextTrack element)) => new WhereIterable<Text Track>(this, f); 18959 Iterable<TextTrack> where(bool f(TextTrack element)) => IterableMixinWorkaroun d.where(this, f);
18990 18960
18991 bool every(bool f(TextTrack element)) => Collections.every(this, f); 18961 bool every(bool f(TextTrack element)) => IterableMixinWorkaround.every(this, f );
18992 18962
18993 bool any(bool f(TextTrack element)) => Collections.any(this, f); 18963 bool any(bool f(TextTrack element)) => IterableMixinWorkaround.any(this, f);
18994 18964
18995 List<TextTrack> toList() => new List<TextTrack>.from(this); 18965 List<TextTrack> toList() => new List<TextTrack>.from(this);
18996 Set<TextTrack> toSet() => new Set<TextTrack>.from(this); 18966 Set<TextTrack> toSet() => new Set<TextTrack>.from(this);
18997 18967
18998 bool get isEmpty => this.length == 0; 18968 bool get isEmpty => this.length == 0;
18999 18969
19000 List<TextTrack> take(int n) => new ListView<TextTrack>(this, 0, n); 18970 List<TextTrack> take(int n) => IterableMixinWorkaround.takeList(this, n);
19001 18971
19002 Iterable<TextTrack> takeWhile(bool test(TextTrack value)) { 18972 Iterable<TextTrack> takeWhile(bool test(TextTrack value)) {
19003 return new TakeWhileIterable<TextTrack>(this, test); 18973 return IterableMixinWorkaround.takeWhile(this, test);
19004 } 18974 }
19005 18975
19006 List<TextTrack> skip(int n) => new ListView<TextTrack>(this, n, null); 18976 List<TextTrack> skip(int n) => IterableMixinWorkaround.skipList(this, n);
19007 18977
19008 Iterable<TextTrack> skipWhile(bool test(TextTrack value)) { 18978 Iterable<TextTrack> skipWhile(bool test(TextTrack value)) {
19009 return new SkipWhileIterable<TextTrack>(this, test); 18979 return IterableMixinWorkaround.skipWhile(this, test);
19010 } 18980 }
19011 18981
19012 TextTrack firstMatching(bool test(TextTrack value), { TextTrack orElse() }) { 18982 TextTrack firstMatching(bool test(TextTrack value), { TextTrack orElse() }) {
19013 return Collections.firstMatching(this, test, orElse); 18983 return IterableMixinWorkaround.firstMatching(this, test, orElse);
19014 } 18984 }
19015 18985
19016 TextTrack lastMatching(bool test(TextTrack value), {TextTrack orElse()}) { 18986 TextTrack lastMatching(bool test(TextTrack value), {TextTrack orElse()}) {
19017 return Collections.lastMatchingInList(this, test, orElse); 18987 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
19018 } 18988 }
19019 18989
19020 TextTrack singleMatching(bool test(TextTrack value)) { 18990 TextTrack singleMatching(bool test(TextTrack value)) {
19021 return Collections.singleMatching(this, test); 18991 return IterableMixinWorkaround.singleMatching(this, test);
19022 } 18992 }
19023 18993
19024 TextTrack elementAt(int index) { 18994 TextTrack elementAt(int index) {
19025 return this[index]; 18995 return this[index];
19026 } 18996 }
19027 18997
19028 // From Collection<TextTrack>: 18998 // From Collection<TextTrack>:
19029 18999
19030 void add(TextTrack value) { 19000 void add(TextTrack value) {
19031 throw new UnsupportedError("Cannot add to immutable List."); 19001 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
19069 if (this.length > 0) return this[this.length - 1]; 19039 if (this.length > 0) return this[this.length - 1];
19070 throw new StateError("No elements"); 19040 throw new StateError("No elements");
19071 } 19041 }
19072 19042
19073 TextTrack get single { 19043 TextTrack get single {
19074 if (length == 1) return this[0]; 19044 if (length == 1) return this[0];
19075 if (length == 0) throw new StateError("No elements"); 19045 if (length == 0) throw new StateError("No elements");
19076 throw new StateError("More than one element"); 19046 throw new StateError("More than one element");
19077 } 19047 }
19078 19048
19079 TextTrack min([int compare(TextTrack a, TextTrack b)]) => Collections.min(this , compare); 19049 TextTrack min([int compare(TextTrack a, TextTrack b)]) => IterableMixinWorkaro und.min(this, compare);
19080 19050
19081 TextTrack max([int compare(TextTrack a, TextTrack b)]) => Collections.max(this , compare); 19051 TextTrack max([int compare(TextTrack a, TextTrack b)]) => IterableMixinWorkaro und.max(this, compare);
19082 19052
19083 TextTrack removeAt(int pos) { 19053 TextTrack removeAt(int pos) {
19084 throw new UnsupportedError("Cannot removeAt on immutable List."); 19054 throw new UnsupportedError("Cannot removeAt on immutable List.");
19085 } 19055 }
19086 19056
19087 TextTrack removeLast() { 19057 TextTrack removeLast() {
19088 throw new UnsupportedError("Cannot removeLast on immutable List."); 19058 throw new UnsupportedError("Cannot removeLast on immutable List.");
19089 } 19059 }
19090 19060
19091 void setRange(int start, int rangeLength, List<TextTrack> from, [int startFrom ]) { 19061 void setRange(int start, int rangeLength, List<TextTrack> from, [int startFrom ]) {
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
19268 // From Iterable<Touch>: 19238 // From Iterable<Touch>:
19269 19239
19270 Iterator<Touch> get iterator { 19240 Iterator<Touch> get iterator {
19271 // Note: NodeLists are not fixed size. And most probably length shouldn't 19241 // Note: NodeLists are not fixed size. And most probably length shouldn't
19272 // be cached in both iterator _and_ forEach method. For now caching it 19242 // be cached in both iterator _and_ forEach method. For now caching it
19273 // for consistency. 19243 // for consistency.
19274 return new FixedSizeListIterator<Touch>(this); 19244 return new FixedSizeListIterator<Touch>(this);
19275 } 19245 }
19276 19246
19277 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Touch)) { 19247 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Touch)) {
19278 return Collections.reduce(this, initialValue, combine); 19248 return IterableMixinWorkaround.reduce(this, initialValue, combine);
19279 } 19249 }
19280 19250
19281 bool contains(Touch element) => Collections.contains(this, element); 19251 bool contains(Touch element) => IterableMixinWorkaround.contains(this, element );
19282 19252
19283 void forEach(void f(Touch element)) => Collections.forEach(this, f); 19253 void forEach(void f(Touch element)) => IterableMixinWorkaround.forEach(this, f );
19284 19254
19285 String join([String separator]) => Collections.joinList(this, separator); 19255 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
19286 19256
19287 List mappedBy(f(Touch element)) => new MappedList<Touch, dynamic>(this, f); 19257 List mappedBy(f(Touch element)) => IterableMixinWorkaround.mappedByList(this, f);
19288 19258
19289 Iterable<Touch> where(bool f(Touch element)) => new WhereIterable<Touch>(this, f); 19259 Iterable<Touch> where(bool f(Touch element)) => IterableMixinWorkaround.where( this, f);
19290 19260
19291 bool every(bool f(Touch element)) => Collections.every(this, f); 19261 bool every(bool f(Touch element)) => IterableMixinWorkaround.every(this, f);
19292 19262
19293 bool any(bool f(Touch element)) => Collections.any(this, f); 19263 bool any(bool f(Touch element)) => IterableMixinWorkaround.any(this, f);
19294 19264
19295 List<Touch> toList() => new List<Touch>.from(this); 19265 List<Touch> toList() => new List<Touch>.from(this);
19296 Set<Touch> toSet() => new Set<Touch>.from(this); 19266 Set<Touch> toSet() => new Set<Touch>.from(this);
19297 19267
19298 bool get isEmpty => this.length == 0; 19268 bool get isEmpty => this.length == 0;
19299 19269
19300 List<Touch> take(int n) => new ListView<Touch>(this, 0, n); 19270 List<Touch> take(int n) => IterableMixinWorkaround.takeList(this, n);
19301 19271
19302 Iterable<Touch> takeWhile(bool test(Touch value)) { 19272 Iterable<Touch> takeWhile(bool test(Touch value)) {
19303 return new TakeWhileIterable<Touch>(this, test); 19273 return IterableMixinWorkaround.takeWhile(this, test);
19304 } 19274 }
19305 19275
19306 List<Touch> skip(int n) => new ListView<Touch>(this, n, null); 19276 List<Touch> skip(int n) => IterableMixinWorkaround.skipList(this, n);
19307 19277
19308 Iterable<Touch> skipWhile(bool test(Touch value)) { 19278 Iterable<Touch> skipWhile(bool test(Touch value)) {
19309 return new SkipWhileIterable<Touch>(this, test); 19279 return IterableMixinWorkaround.skipWhile(this, test);
19310 } 19280 }
19311 19281
19312 Touch firstMatching(bool test(Touch value), { Touch orElse() }) { 19282 Touch firstMatching(bool test(Touch value), { Touch orElse() }) {
19313 return Collections.firstMatching(this, test, orElse); 19283 return IterableMixinWorkaround.firstMatching(this, test, orElse);
19314 } 19284 }
19315 19285
19316 Touch lastMatching(bool test(Touch value), {Touch orElse()}) { 19286 Touch lastMatching(bool test(Touch value), {Touch orElse()}) {
19317 return Collections.lastMatchingInList(this, test, orElse); 19287 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
19318 } 19288 }
19319 19289
19320 Touch singleMatching(bool test(Touch value)) { 19290 Touch singleMatching(bool test(Touch value)) {
19321 return Collections.singleMatching(this, test); 19291 return IterableMixinWorkaround.singleMatching(this, test);
19322 } 19292 }
19323 19293
19324 Touch elementAt(int index) { 19294 Touch elementAt(int index) {
19325 return this[index]; 19295 return this[index];
19326 } 19296 }
19327 19297
19328 // From Collection<Touch>: 19298 // From Collection<Touch>:
19329 19299
19330 void add(Touch value) { 19300 void add(Touch value) {
19331 throw new UnsupportedError("Cannot add to immutable List."); 19301 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
19369 if (this.length > 0) return this[this.length - 1]; 19339 if (this.length > 0) return this[this.length - 1];
19370 throw new StateError("No elements"); 19340 throw new StateError("No elements");
19371 } 19341 }
19372 19342
19373 Touch get single { 19343 Touch get single {
19374 if (length == 1) return this[0]; 19344 if (length == 1) return this[0];
19375 if (length == 0) throw new StateError("No elements"); 19345 if (length == 0) throw new StateError("No elements");
19376 throw new StateError("More than one element"); 19346 throw new StateError("More than one element");
19377 } 19347 }
19378 19348
19379 Touch min([int compare(Touch a, Touch b)]) => Collections.min(this, compare); 19349 Touch min([int compare(Touch a, Touch b)]) => IterableMixinWorkaround.min(this , compare);
19380 19350
19381 Touch max([int compare(Touch a, Touch b)]) => Collections.max(this, compare); 19351 Touch max([int compare(Touch a, Touch b)]) => IterableMixinWorkaround.max(this , compare);
19382 19352
19383 Touch removeAt(int pos) { 19353 Touch removeAt(int pos) {
19384 throw new UnsupportedError("Cannot removeAt on immutable List."); 19354 throw new UnsupportedError("Cannot removeAt on immutable List.");
19385 } 19355 }
19386 19356
19387 Touch removeLast() { 19357 Touch removeLast() {
19388 throw new UnsupportedError("Cannot removeLast on immutable List."); 19358 throw new UnsupportedError("Cannot removeLast on immutable List.");
19389 } 19359 }
19390 19360
19391 void setRange(int start, int rangeLength, List<Touch> from, [int startFrom]) { 19361 void setRange(int start, int rangeLength, List<Touch> from, [int startFrom]) {
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
19624 // From Iterable<int>: 19594 // From Iterable<int>:
19625 19595
19626 Iterator<int> get iterator { 19596 Iterator<int> get iterator {
19627 // Note: NodeLists are not fixed size. And most probably length shouldn't 19597 // Note: NodeLists are not fixed size. And most probably length shouldn't
19628 // be cached in both iterator _and_ forEach method. For now caching it 19598 // be cached in both iterator _and_ forEach method. For now caching it
19629 // for consistency. 19599 // for consistency.
19630 return new FixedSizeListIterator<int>(this); 19600 return new FixedSizeListIterator<int>(this);
19631 } 19601 }
19632 19602
19633 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 19603 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
19634 return Collections.reduce(this, initialValue, combine); 19604 return IterableMixinWorkaround.reduce(this, initialValue, combine);
19635 } 19605 }
19636 19606
19637 bool contains(int element) => Collections.contains(this, element); 19607 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
19638 19608
19639 void forEach(void f(int element)) => Collections.forEach(this, f); 19609 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
19640 19610
19641 String join([String separator]) => Collections.joinList(this, separator); 19611 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
19642 19612
19643 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 19613 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
19644 19614
19645 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 19615 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
19646 19616
19647 bool every(bool f(int element)) => Collections.every(this, f); 19617 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
19648 19618
19649 bool any(bool f(int element)) => Collections.any(this, f); 19619 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
19650 19620
19651 List<int> toList() => new List<int>.from(this); 19621 List<int> toList() => new List<int>.from(this);
19652 Set<int> toSet() => new Set<int>.from(this); 19622 Set<int> toSet() => new Set<int>.from(this);
19653 19623
19654 bool get isEmpty => this.length == 0; 19624 bool get isEmpty => this.length == 0;
19655 19625
19656 List<int> take(int n) => new ListView<int>(this, 0, n); 19626 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
19657 19627
19658 Iterable<int> takeWhile(bool test(int value)) { 19628 Iterable<int> takeWhile(bool test(int value)) {
19659 return new TakeWhileIterable<int>(this, test); 19629 return IterableMixinWorkaround.takeWhile(this, test);
19660 } 19630 }
19661 19631
19662 List<int> skip(int n) => new ListView<int>(this, n, null); 19632 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
19663 19633
19664 Iterable<int> skipWhile(bool test(int value)) { 19634 Iterable<int> skipWhile(bool test(int value)) {
19665 return new SkipWhileIterable<int>(this, test); 19635 return IterableMixinWorkaround.skipWhile(this, test);
19666 } 19636 }
19667 19637
19668 int firstMatching(bool test(int value), { int orElse() }) { 19638 int firstMatching(bool test(int value), { int orElse() }) {
19669 return Collections.firstMatching(this, test, orElse); 19639 return IterableMixinWorkaround.firstMatching(this, test, orElse);
19670 } 19640 }
19671 19641
19672 int lastMatching(bool test(int value), {int orElse()}) { 19642 int lastMatching(bool test(int value), {int orElse()}) {
19673 return Collections.lastMatchingInList(this, test, orElse); 19643 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
19674 } 19644 }
19675 19645
19676 int singleMatching(bool test(int value)) { 19646 int singleMatching(bool test(int value)) {
19677 return Collections.singleMatching(this, test); 19647 return IterableMixinWorkaround.singleMatching(this, test);
19678 } 19648 }
19679 19649
19680 int elementAt(int index) { 19650 int elementAt(int index) {
19681 return this[index]; 19651 return this[index];
19682 } 19652 }
19683 19653
19684 // From Collection<int>: 19654 // From Collection<int>:
19685 19655
19686 void add(int value) { 19656 void add(int value) {
19687 throw new UnsupportedError("Cannot add to immutable List."); 19657 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
19725 if (this.length > 0) return this[this.length - 1]; 19695 if (this.length > 0) return this[this.length - 1];
19726 throw new StateError("No elements"); 19696 throw new StateError("No elements");
19727 } 19697 }
19728 19698
19729 int get single { 19699 int get single {
19730 if (length == 1) return this[0]; 19700 if (length == 1) return this[0];
19731 if (length == 0) throw new StateError("No elements"); 19701 if (length == 0) throw new StateError("No elements");
19732 throw new StateError("More than one element"); 19702 throw new StateError("More than one element");
19733 } 19703 }
19734 19704
19735 int min([int compare(int a, int b)]) => Collections.min(this, compare); 19705 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
19736 19706
19737 int max([int compare(int a, int b)]) => Collections.max(this, compare); 19707 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
19738 19708
19739 int removeAt(int pos) { 19709 int removeAt(int pos) {
19740 throw new UnsupportedError("Cannot removeAt on immutable List."); 19710 throw new UnsupportedError("Cannot removeAt on immutable List.");
19741 } 19711 }
19742 19712
19743 int removeLast() { 19713 int removeLast() {
19744 throw new UnsupportedError("Cannot removeLast on immutable List."); 19714 throw new UnsupportedError("Cannot removeLast on immutable List.");
19745 } 19715 }
19746 19716
19747 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 19717 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
19798 // From Iterable<int>: 19768 // From Iterable<int>:
19799 19769
19800 Iterator<int> get iterator { 19770 Iterator<int> get iterator {
19801 // Note: NodeLists are not fixed size. And most probably length shouldn't 19771 // Note: NodeLists are not fixed size. And most probably length shouldn't
19802 // be cached in both iterator _and_ forEach method. For now caching it 19772 // be cached in both iterator _and_ forEach method. For now caching it
19803 // for consistency. 19773 // for consistency.
19804 return new FixedSizeListIterator<int>(this); 19774 return new FixedSizeListIterator<int>(this);
19805 } 19775 }
19806 19776
19807 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 19777 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
19808 return Collections.reduce(this, initialValue, combine); 19778 return IterableMixinWorkaround.reduce(this, initialValue, combine);
19809 } 19779 }
19810 19780
19811 bool contains(int element) => Collections.contains(this, element); 19781 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
19812 19782
19813 void forEach(void f(int element)) => Collections.forEach(this, f); 19783 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
19814 19784
19815 String join([String separator]) => Collections.joinList(this, separator); 19785 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
19816 19786
19817 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 19787 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
19818 19788
19819 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 19789 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
19820 19790
19821 bool every(bool f(int element)) => Collections.every(this, f); 19791 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
19822 19792
19823 bool any(bool f(int element)) => Collections.any(this, f); 19793 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
19824 19794
19825 List<int> toList() => new List<int>.from(this); 19795 List<int> toList() => new List<int>.from(this);
19826 Set<int> toSet() => new Set<int>.from(this); 19796 Set<int> toSet() => new Set<int>.from(this);
19827 19797
19828 bool get isEmpty => this.length == 0; 19798 bool get isEmpty => this.length == 0;
19829 19799
19830 List<int> take(int n) => new ListView<int>(this, 0, n); 19800 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
19831 19801
19832 Iterable<int> takeWhile(bool test(int value)) { 19802 Iterable<int> takeWhile(bool test(int value)) {
19833 return new TakeWhileIterable<int>(this, test); 19803 return IterableMixinWorkaround.takeWhile(this, test);
19834 } 19804 }
19835 19805
19836 List<int> skip(int n) => new ListView<int>(this, n, null); 19806 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
19837 19807
19838 Iterable<int> skipWhile(bool test(int value)) { 19808 Iterable<int> skipWhile(bool test(int value)) {
19839 return new SkipWhileIterable<int>(this, test); 19809 return IterableMixinWorkaround.skipWhile(this, test);
19840 } 19810 }
19841 19811
19842 int firstMatching(bool test(int value), { int orElse() }) { 19812 int firstMatching(bool test(int value), { int orElse() }) {
19843 return Collections.firstMatching(this, test, orElse); 19813 return IterableMixinWorkaround.firstMatching(this, test, orElse);
19844 } 19814 }
19845 19815
19846 int lastMatching(bool test(int value), {int orElse()}) { 19816 int lastMatching(bool test(int value), {int orElse()}) {
19847 return Collections.lastMatchingInList(this, test, orElse); 19817 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
19848 } 19818 }
19849 19819
19850 int singleMatching(bool test(int value)) { 19820 int singleMatching(bool test(int value)) {
19851 return Collections.singleMatching(this, test); 19821 return IterableMixinWorkaround.singleMatching(this, test);
19852 } 19822 }
19853 19823
19854 int elementAt(int index) { 19824 int elementAt(int index) {
19855 return this[index]; 19825 return this[index];
19856 } 19826 }
19857 19827
19858 // From Collection<int>: 19828 // From Collection<int>:
19859 19829
19860 void add(int value) { 19830 void add(int value) {
19861 throw new UnsupportedError("Cannot add to immutable List."); 19831 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
19899 if (this.length > 0) return this[this.length - 1]; 19869 if (this.length > 0) return this[this.length - 1];
19900 throw new StateError("No elements"); 19870 throw new StateError("No elements");
19901 } 19871 }
19902 19872
19903 int get single { 19873 int get single {
19904 if (length == 1) return this[0]; 19874 if (length == 1) return this[0];
19905 if (length == 0) throw new StateError("No elements"); 19875 if (length == 0) throw new StateError("No elements");
19906 throw new StateError("More than one element"); 19876 throw new StateError("More than one element");
19907 } 19877 }
19908 19878
19909 int min([int compare(int a, int b)]) => Collections.min(this, compare); 19879 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
19910 19880
19911 int max([int compare(int a, int b)]) => Collections.max(this, compare); 19881 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
19912 19882
19913 int removeAt(int pos) { 19883 int removeAt(int pos) {
19914 throw new UnsupportedError("Cannot removeAt on immutable List."); 19884 throw new UnsupportedError("Cannot removeAt on immutable List.");
19915 } 19885 }
19916 19886
19917 int removeLast() { 19887 int removeLast() {
19918 throw new UnsupportedError("Cannot removeLast on immutable List."); 19888 throw new UnsupportedError("Cannot removeLast on immutable List.");
19919 } 19889 }
19920 19890
19921 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 19891 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
19972 // From Iterable<int>: 19942 // From Iterable<int>:
19973 19943
19974 Iterator<int> get iterator { 19944 Iterator<int> get iterator {
19975 // Note: NodeLists are not fixed size. And most probably length shouldn't 19945 // Note: NodeLists are not fixed size. And most probably length shouldn't
19976 // be cached in both iterator _and_ forEach method. For now caching it 19946 // be cached in both iterator _and_ forEach method. For now caching it
19977 // for consistency. 19947 // for consistency.
19978 return new FixedSizeListIterator<int>(this); 19948 return new FixedSizeListIterator<int>(this);
19979 } 19949 }
19980 19950
19981 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) { 19951 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, int)) {
19982 return Collections.reduce(this, initialValue, combine); 19952 return IterableMixinWorkaround.reduce(this, initialValue, combine);
19983 } 19953 }
19984 19954
19985 bool contains(int element) => Collections.contains(this, element); 19955 bool contains(int element) => IterableMixinWorkaround.contains(this, element);
19986 19956
19987 void forEach(void f(int element)) => Collections.forEach(this, f); 19957 void forEach(void f(int element)) => IterableMixinWorkaround.forEach(this, f);
19988 19958
19989 String join([String separator]) => Collections.joinList(this, separator); 19959 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
19990 19960
19991 List mappedBy(f(int element)) => new MappedList<int, dynamic>(this, f); 19961 List mappedBy(f(int element)) => IterableMixinWorkaround.mappedByList(this, f) ;
19992 19962
19993 Iterable<int> where(bool f(int element)) => new WhereIterable<int>(this, f); 19963 Iterable<int> where(bool f(int element)) => IterableMixinWorkaround.where(this , f);
19994 19964
19995 bool every(bool f(int element)) => Collections.every(this, f); 19965 bool every(bool f(int element)) => IterableMixinWorkaround.every(this, f);
19996 19966
19997 bool any(bool f(int element)) => Collections.any(this, f); 19967 bool any(bool f(int element)) => IterableMixinWorkaround.any(this, f);
19998 19968
19999 List<int> toList() => new List<int>.from(this); 19969 List<int> toList() => new List<int>.from(this);
20000 Set<int> toSet() => new Set<int>.from(this); 19970 Set<int> toSet() => new Set<int>.from(this);
20001 19971
20002 bool get isEmpty => this.length == 0; 19972 bool get isEmpty => this.length == 0;
20003 19973
20004 List<int> take(int n) => new ListView<int>(this, 0, n); 19974 List<int> take(int n) => IterableMixinWorkaround.takeList(this, n);
20005 19975
20006 Iterable<int> takeWhile(bool test(int value)) { 19976 Iterable<int> takeWhile(bool test(int value)) {
20007 return new TakeWhileIterable<int>(this, test); 19977 return IterableMixinWorkaround.takeWhile(this, test);
20008 } 19978 }
20009 19979
20010 List<int> skip(int n) => new ListView<int>(this, n, null); 19980 List<int> skip(int n) => IterableMixinWorkaround.skipList(this, n);
20011 19981
20012 Iterable<int> skipWhile(bool test(int value)) { 19982 Iterable<int> skipWhile(bool test(int value)) {
20013 return new SkipWhileIterable<int>(this, test); 19983 return IterableMixinWorkaround.skipWhile(this, test);
20014 } 19984 }
20015 19985
20016 int firstMatching(bool test(int value), { int orElse() }) { 19986 int firstMatching(bool test(int value), { int orElse() }) {
20017 return Collections.firstMatching(this, test, orElse); 19987 return IterableMixinWorkaround.firstMatching(this, test, orElse);
20018 } 19988 }
20019 19989
20020 int lastMatching(bool test(int value), {int orElse()}) { 19990 int lastMatching(bool test(int value), {int orElse()}) {
20021 return Collections.lastMatchingInList(this, test, orElse); 19991 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
20022 } 19992 }
20023 19993
20024 int singleMatching(bool test(int value)) { 19994 int singleMatching(bool test(int value)) {
20025 return Collections.singleMatching(this, test); 19995 return IterableMixinWorkaround.singleMatching(this, test);
20026 } 19996 }
20027 19997
20028 int elementAt(int index) { 19998 int elementAt(int index) {
20029 return this[index]; 19999 return this[index];
20030 } 20000 }
20031 20001
20032 // From Collection<int>: 20002 // From Collection<int>:
20033 20003
20034 void add(int value) { 20004 void add(int value) {
20035 throw new UnsupportedError("Cannot add to immutable List."); 20005 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
20073 if (this.length > 0) return this[this.length - 1]; 20043 if (this.length > 0) return this[this.length - 1];
20074 throw new StateError("No elements"); 20044 throw new StateError("No elements");
20075 } 20045 }
20076 20046
20077 int get single { 20047 int get single {
20078 if (length == 1) return this[0]; 20048 if (length == 1) return this[0];
20079 if (length == 0) throw new StateError("No elements"); 20049 if (length == 0) throw new StateError("No elements");
20080 throw new StateError("More than one element"); 20050 throw new StateError("More than one element");
20081 } 20051 }
20082 20052
20083 int min([int compare(int a, int b)]) => Collections.min(this, compare); 20053 int min([int compare(int a, int b)]) => IterableMixinWorkaround.min(this, comp are);
20084 20054
20085 int max([int compare(int a, int b)]) => Collections.max(this, compare); 20055 int max([int compare(int a, int b)]) => IterableMixinWorkaround.max(this, comp are);
20086 20056
20087 int removeAt(int pos) { 20057 int removeAt(int pos) {
20088 throw new UnsupportedError("Cannot removeAt on immutable List."); 20058 throw new UnsupportedError("Cannot removeAt on immutable List.");
20089 } 20059 }
20090 20060
20091 int removeLast() { 20061 int removeLast() {
20092 throw new UnsupportedError("Cannot removeLast on immutable List."); 20062 throw new UnsupportedError("Cannot removeLast on immutable List.");
20093 } 20063 }
20094 20064
20095 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) { 20065 void setRange(int start, int rangeLength, List<int> from, [int startFrom]) {
(...skipping 3135 matching lines...) Expand 10 before | Expand all | Expand 10 after
23231 // From Iterable<ClientRect>: 23201 // From Iterable<ClientRect>:
23232 23202
23233 Iterator<ClientRect> get iterator { 23203 Iterator<ClientRect> get iterator {
23234 // Note: NodeLists are not fixed size. And most probably length shouldn't 23204 // Note: NodeLists are not fixed size. And most probably length shouldn't
23235 // be cached in both iterator _and_ forEach method. For now caching it 23205 // be cached in both iterator _and_ forEach method. For now caching it
23236 // for consistency. 23206 // for consistency.
23237 return new FixedSizeListIterator<ClientRect>(this); 23207 return new FixedSizeListIterator<ClientRect>(this);
23238 } 23208 }
23239 23209
23240 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, ClientRect)) { 23210 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, ClientRect)) {
23241 return Collections.reduce(this, initialValue, combine); 23211 return IterableMixinWorkaround.reduce(this, initialValue, combine);
23242 } 23212 }
23243 23213
23244 bool contains(ClientRect element) => Collections.contains(this, element); 23214 bool contains(ClientRect element) => IterableMixinWorkaround.contains(this, el ement);
23245 23215
23246 void forEach(void f(ClientRect element)) => Collections.forEach(this, f); 23216 void forEach(void f(ClientRect element)) => IterableMixinWorkaround.forEach(th is, f);
23247 23217
23248 String join([String separator]) => Collections.joinList(this, separator); 23218 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
23249 23219
23250 List mappedBy(f(ClientRect element)) => new MappedList<ClientRect, dynamic>(th is, f); 23220 List mappedBy(f(ClientRect element)) => IterableMixinWorkaround.mappedByList(t his, f);
23251 23221
23252 Iterable<ClientRect> where(bool f(ClientRect element)) => new WhereIterable<Cl ientRect>(this, f); 23222 Iterable<ClientRect> where(bool f(ClientRect element)) => IterableMixinWorkaro und.where(this, f);
23253 23223
23254 bool every(bool f(ClientRect element)) => Collections.every(this, f); 23224 bool every(bool f(ClientRect element)) => IterableMixinWorkaround.every(this, f);
23255 23225
23256 bool any(bool f(ClientRect element)) => Collections.any(this, f); 23226 bool any(bool f(ClientRect element)) => IterableMixinWorkaround.any(this, f);
23257 23227
23258 List<ClientRect> toList() => new List<ClientRect>.from(this); 23228 List<ClientRect> toList() => new List<ClientRect>.from(this);
23259 Set<ClientRect> toSet() => new Set<ClientRect>.from(this); 23229 Set<ClientRect> toSet() => new Set<ClientRect>.from(this);
23260 23230
23261 bool get isEmpty => this.length == 0; 23231 bool get isEmpty => this.length == 0;
23262 23232
23263 List<ClientRect> take(int n) => new ListView<ClientRect>(this, 0, n); 23233 List<ClientRect> take(int n) => IterableMixinWorkaround.takeList(this, n);
23264 23234
23265 Iterable<ClientRect> takeWhile(bool test(ClientRect value)) { 23235 Iterable<ClientRect> takeWhile(bool test(ClientRect value)) {
23266 return new TakeWhileIterable<ClientRect>(this, test); 23236 return IterableMixinWorkaround.takeWhile(this, test);
23267 } 23237 }
23268 23238
23269 List<ClientRect> skip(int n) => new ListView<ClientRect>(this, n, null); 23239 List<ClientRect> skip(int n) => IterableMixinWorkaround.skipList(this, n);
23270 23240
23271 Iterable<ClientRect> skipWhile(bool test(ClientRect value)) { 23241 Iterable<ClientRect> skipWhile(bool test(ClientRect value)) {
23272 return new SkipWhileIterable<ClientRect>(this, test); 23242 return IterableMixinWorkaround.skipWhile(this, test);
23273 } 23243 }
23274 23244
23275 ClientRect firstMatching(bool test(ClientRect value), { ClientRect orElse() }) { 23245 ClientRect firstMatching(bool test(ClientRect value), { ClientRect orElse() }) {
23276 return Collections.firstMatching(this, test, orElse); 23246 return IterableMixinWorkaround.firstMatching(this, test, orElse);
23277 } 23247 }
23278 23248
23279 ClientRect lastMatching(bool test(ClientRect value), {ClientRect orElse()}) { 23249 ClientRect lastMatching(bool test(ClientRect value), {ClientRect orElse()}) {
23280 return Collections.lastMatchingInList(this, test, orElse); 23250 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
23281 } 23251 }
23282 23252
23283 ClientRect singleMatching(bool test(ClientRect value)) { 23253 ClientRect singleMatching(bool test(ClientRect value)) {
23284 return Collections.singleMatching(this, test); 23254 return IterableMixinWorkaround.singleMatching(this, test);
23285 } 23255 }
23286 23256
23287 ClientRect elementAt(int index) { 23257 ClientRect elementAt(int index) {
23288 return this[index]; 23258 return this[index];
23289 } 23259 }
23290 23260
23291 // From Collection<ClientRect>: 23261 // From Collection<ClientRect>:
23292 23262
23293 void add(ClientRect value) { 23263 void add(ClientRect value) {
23294 throw new UnsupportedError("Cannot add to immutable List."); 23264 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
23332 if (this.length > 0) return this[this.length - 1]; 23302 if (this.length > 0) return this[this.length - 1];
23333 throw new StateError("No elements"); 23303 throw new StateError("No elements");
23334 } 23304 }
23335 23305
23336 ClientRect get single { 23306 ClientRect get single {
23337 if (length == 1) return this[0]; 23307 if (length == 1) return this[0];
23338 if (length == 0) throw new StateError("No elements"); 23308 if (length == 0) throw new StateError("No elements");
23339 throw new StateError("More than one element"); 23309 throw new StateError("More than one element");
23340 } 23310 }
23341 23311
23342 ClientRect min([int compare(ClientRect a, ClientRect b)]) => Collections.min(t his, compare); 23312 ClientRect min([int compare(ClientRect a, ClientRect b)]) => IterableMixinWork around.min(this, compare);
23343 23313
23344 ClientRect max([int compare(ClientRect a, ClientRect b)]) => Collections.max(t his, compare); 23314 ClientRect max([int compare(ClientRect a, ClientRect b)]) => IterableMixinWork around.max(this, compare);
23345 23315
23346 ClientRect removeAt(int pos) { 23316 ClientRect removeAt(int pos) {
23347 throw new UnsupportedError("Cannot removeAt on immutable List."); 23317 throw new UnsupportedError("Cannot removeAt on immutable List.");
23348 } 23318 }
23349 23319
23350 ClientRect removeLast() { 23320 ClientRect removeLast() {
23351 throw new UnsupportedError("Cannot removeLast on immutable List."); 23321 throw new UnsupportedError("Cannot removeLast on immutable List.");
23352 } 23322 }
23353 23323
23354 void setRange(int start, int rangeLength, List<ClientRect> from, [int startFro m]) { 23324 void setRange(int start, int rangeLength, List<ClientRect> from, [int startFro m]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
23393 // From Iterable<CssRule>: 23363 // From Iterable<CssRule>:
23394 23364
23395 Iterator<CssRule> get iterator { 23365 Iterator<CssRule> get iterator {
23396 // Note: NodeLists are not fixed size. And most probably length shouldn't 23366 // Note: NodeLists are not fixed size. And most probably length shouldn't
23397 // be cached in both iterator _and_ forEach method. For now caching it 23367 // be cached in both iterator _and_ forEach method. For now caching it
23398 // for consistency. 23368 // for consistency.
23399 return new FixedSizeListIterator<CssRule>(this); 23369 return new FixedSizeListIterator<CssRule>(this);
23400 } 23370 }
23401 23371
23402 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, CssRule)) { 23372 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, CssRule)) {
23403 return Collections.reduce(this, initialValue, combine); 23373 return IterableMixinWorkaround.reduce(this, initialValue, combine);
23404 } 23374 }
23405 23375
23406 bool contains(CssRule element) => Collections.contains(this, element); 23376 bool contains(CssRule element) => IterableMixinWorkaround.contains(this, eleme nt);
23407 23377
23408 void forEach(void f(CssRule element)) => Collections.forEach(this, f); 23378 void forEach(void f(CssRule element)) => IterableMixinWorkaround.forEach(this, f);
23409 23379
23410 String join([String separator]) => Collections.joinList(this, separator); 23380 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
23411 23381
23412 List mappedBy(f(CssRule element)) => new MappedList<CssRule, dynamic>(this, f) ; 23382 List mappedBy(f(CssRule element)) => IterableMixinWorkaround.mappedByList(this , f);
23413 23383
23414 Iterable<CssRule> where(bool f(CssRule element)) => new WhereIterable<CssRule> (this, f); 23384 Iterable<CssRule> where(bool f(CssRule element)) => IterableMixinWorkaround.wh ere(this, f);
23415 23385
23416 bool every(bool f(CssRule element)) => Collections.every(this, f); 23386 bool every(bool f(CssRule element)) => IterableMixinWorkaround.every(this, f);
23417 23387
23418 bool any(bool f(CssRule element)) => Collections.any(this, f); 23388 bool any(bool f(CssRule element)) => IterableMixinWorkaround.any(this, f);
23419 23389
23420 List<CssRule> toList() => new List<CssRule>.from(this); 23390 List<CssRule> toList() => new List<CssRule>.from(this);
23421 Set<CssRule> toSet() => new Set<CssRule>.from(this); 23391 Set<CssRule> toSet() => new Set<CssRule>.from(this);
23422 23392
23423 bool get isEmpty => this.length == 0; 23393 bool get isEmpty => this.length == 0;
23424 23394
23425 List<CssRule> take(int n) => new ListView<CssRule>(this, 0, n); 23395 List<CssRule> take(int n) => IterableMixinWorkaround.takeList(this, n);
23426 23396
23427 Iterable<CssRule> takeWhile(bool test(CssRule value)) { 23397 Iterable<CssRule> takeWhile(bool test(CssRule value)) {
23428 return new TakeWhileIterable<CssRule>(this, test); 23398 return IterableMixinWorkaround.takeWhile(this, test);
23429 } 23399 }
23430 23400
23431 List<CssRule> skip(int n) => new ListView<CssRule>(this, n, null); 23401 List<CssRule> skip(int n) => IterableMixinWorkaround.skipList(this, n);
23432 23402
23433 Iterable<CssRule> skipWhile(bool test(CssRule value)) { 23403 Iterable<CssRule> skipWhile(bool test(CssRule value)) {
23434 return new SkipWhileIterable<CssRule>(this, test); 23404 return IterableMixinWorkaround.skipWhile(this, test);
23435 } 23405 }
23436 23406
23437 CssRule firstMatching(bool test(CssRule value), { CssRule orElse() }) { 23407 CssRule firstMatching(bool test(CssRule value), { CssRule orElse() }) {
23438 return Collections.firstMatching(this, test, orElse); 23408 return IterableMixinWorkaround.firstMatching(this, test, orElse);
23439 } 23409 }
23440 23410
23441 CssRule lastMatching(bool test(CssRule value), {CssRule orElse()}) { 23411 CssRule lastMatching(bool test(CssRule value), {CssRule orElse()}) {
23442 return Collections.lastMatchingInList(this, test, orElse); 23412 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
23443 } 23413 }
23444 23414
23445 CssRule singleMatching(bool test(CssRule value)) { 23415 CssRule singleMatching(bool test(CssRule value)) {
23446 return Collections.singleMatching(this, test); 23416 return IterableMixinWorkaround.singleMatching(this, test);
23447 } 23417 }
23448 23418
23449 CssRule elementAt(int index) { 23419 CssRule elementAt(int index) {
23450 return this[index]; 23420 return this[index];
23451 } 23421 }
23452 23422
23453 // From Collection<CssRule>: 23423 // From Collection<CssRule>:
23454 23424
23455 void add(CssRule value) { 23425 void add(CssRule value) {
23456 throw new UnsupportedError("Cannot add to immutable List."); 23426 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
23494 if (this.length > 0) return this[this.length - 1]; 23464 if (this.length > 0) return this[this.length - 1];
23495 throw new StateError("No elements"); 23465 throw new StateError("No elements");
23496 } 23466 }
23497 23467
23498 CssRule get single { 23468 CssRule get single {
23499 if (length == 1) return this[0]; 23469 if (length == 1) return this[0];
23500 if (length == 0) throw new StateError("No elements"); 23470 if (length == 0) throw new StateError("No elements");
23501 throw new StateError("More than one element"); 23471 throw new StateError("More than one element");
23502 } 23472 }
23503 23473
23504 CssRule min([int compare(CssRule a, CssRule b)]) => Collections.min(this, comp are); 23474 CssRule min([int compare(CssRule a, CssRule b)]) => IterableMixinWorkaround.mi n(this, compare);
23505 23475
23506 CssRule max([int compare(CssRule a, CssRule b)]) => Collections.max(this, comp are); 23476 CssRule max([int compare(CssRule a, CssRule b)]) => IterableMixinWorkaround.ma x(this, compare);
23507 23477
23508 CssRule removeAt(int pos) { 23478 CssRule removeAt(int pos) {
23509 throw new UnsupportedError("Cannot removeAt on immutable List."); 23479 throw new UnsupportedError("Cannot removeAt on immutable List.");
23510 } 23480 }
23511 23481
23512 CssRule removeLast() { 23482 CssRule removeLast() {
23513 throw new UnsupportedError("Cannot removeLast on immutable List."); 23483 throw new UnsupportedError("Cannot removeLast on immutable List.");
23514 } 23484 }
23515 23485
23516 void setRange(int start, int rangeLength, List<CssRule> from, [int startFrom]) { 23486 void setRange(int start, int rangeLength, List<CssRule> from, [int startFrom]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
23555 // From Iterable<CssValue>: 23525 // From Iterable<CssValue>:
23556 23526
23557 Iterator<CssValue> get iterator { 23527 Iterator<CssValue> get iterator {
23558 // Note: NodeLists are not fixed size. And most probably length shouldn't 23528 // Note: NodeLists are not fixed size. And most probably length shouldn't
23559 // be cached in both iterator _and_ forEach method. For now caching it 23529 // be cached in both iterator _and_ forEach method. For now caching it
23560 // for consistency. 23530 // for consistency.
23561 return new FixedSizeListIterator<CssValue>(this); 23531 return new FixedSizeListIterator<CssValue>(this);
23562 } 23532 }
23563 23533
23564 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, CssValue)) { 23534 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, CssValue)) {
23565 return Collections.reduce(this, initialValue, combine); 23535 return IterableMixinWorkaround.reduce(this, initialValue, combine);
23566 } 23536 }
23567 23537
23568 bool contains(CssValue element) => Collections.contains(this, element); 23538 bool contains(CssValue element) => IterableMixinWorkaround.contains(this, elem ent);
23569 23539
23570 void forEach(void f(CssValue element)) => Collections.forEach(this, f); 23540 void forEach(void f(CssValue element)) => IterableMixinWorkaround.forEach(this , f);
23571 23541
23572 String join([String separator]) => Collections.joinList(this, separator); 23542 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
23573 23543
23574 List mappedBy(f(CssValue element)) => new MappedList<CssValue, dynamic>(this, f); 23544 List mappedBy(f(CssValue element)) => IterableMixinWorkaround.mappedByList(thi s, f);
23575 23545
23576 Iterable<CssValue> where(bool f(CssValue element)) => new WhereIterable<CssVal ue>(this, f); 23546 Iterable<CssValue> where(bool f(CssValue element)) => IterableMixinWorkaround. where(this, f);
23577 23547
23578 bool every(bool f(CssValue element)) => Collections.every(this, f); 23548 bool every(bool f(CssValue element)) => IterableMixinWorkaround.every(this, f) ;
23579 23549
23580 bool any(bool f(CssValue element)) => Collections.any(this, f); 23550 bool any(bool f(CssValue element)) => IterableMixinWorkaround.any(this, f);
23581 23551
23582 List<CssValue> toList() => new List<CssValue>.from(this); 23552 List<CssValue> toList() => new List<CssValue>.from(this);
23583 Set<CssValue> toSet() => new Set<CssValue>.from(this); 23553 Set<CssValue> toSet() => new Set<CssValue>.from(this);
23584 23554
23585 bool get isEmpty => this.length == 0; 23555 bool get isEmpty => this.length == 0;
23586 23556
23587 List<CssValue> take(int n) => new ListView<CssValue>(this, 0, n); 23557 List<CssValue> take(int n) => IterableMixinWorkaround.takeList(this, n);
23588 23558
23589 Iterable<CssValue> takeWhile(bool test(CssValue value)) { 23559 Iterable<CssValue> takeWhile(bool test(CssValue value)) {
23590 return new TakeWhileIterable<CssValue>(this, test); 23560 return IterableMixinWorkaround.takeWhile(this, test);
23591 } 23561 }
23592 23562
23593 List<CssValue> skip(int n) => new ListView<CssValue>(this, n, null); 23563 List<CssValue> skip(int n) => IterableMixinWorkaround.skipList(this, n);
23594 23564
23595 Iterable<CssValue> skipWhile(bool test(CssValue value)) { 23565 Iterable<CssValue> skipWhile(bool test(CssValue value)) {
23596 return new SkipWhileIterable<CssValue>(this, test); 23566 return IterableMixinWorkaround.skipWhile(this, test);
23597 } 23567 }
23598 23568
23599 CssValue firstMatching(bool test(CssValue value), { CssValue orElse() }) { 23569 CssValue firstMatching(bool test(CssValue value), { CssValue orElse() }) {
23600 return Collections.firstMatching(this, test, orElse); 23570 return IterableMixinWorkaround.firstMatching(this, test, orElse);
23601 } 23571 }
23602 23572
23603 CssValue lastMatching(bool test(CssValue value), {CssValue orElse()}) { 23573 CssValue lastMatching(bool test(CssValue value), {CssValue orElse()}) {
23604 return Collections.lastMatchingInList(this, test, orElse); 23574 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
23605 } 23575 }
23606 23576
23607 CssValue singleMatching(bool test(CssValue value)) { 23577 CssValue singleMatching(bool test(CssValue value)) {
23608 return Collections.singleMatching(this, test); 23578 return IterableMixinWorkaround.singleMatching(this, test);
23609 } 23579 }
23610 23580
23611 CssValue elementAt(int index) { 23581 CssValue elementAt(int index) {
23612 return this[index]; 23582 return this[index];
23613 } 23583 }
23614 23584
23615 // From Collection<CssValue>: 23585 // From Collection<CssValue>:
23616 23586
23617 void add(CssValue value) { 23587 void add(CssValue value) {
23618 throw new UnsupportedError("Cannot add to immutable List."); 23588 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
23656 if (this.length > 0) return this[this.length - 1]; 23626 if (this.length > 0) return this[this.length - 1];
23657 throw new StateError("No elements"); 23627 throw new StateError("No elements");
23658 } 23628 }
23659 23629
23660 CssValue get single { 23630 CssValue get single {
23661 if (length == 1) return this[0]; 23631 if (length == 1) return this[0];
23662 if (length == 0) throw new StateError("No elements"); 23632 if (length == 0) throw new StateError("No elements");
23663 throw new StateError("More than one element"); 23633 throw new StateError("More than one element");
23664 } 23634 }
23665 23635
23666 CssValue min([int compare(CssValue a, CssValue b)]) => Collections.min(this, c ompare); 23636 CssValue min([int compare(CssValue a, CssValue b)]) => IterableMixinWorkaround .min(this, compare);
23667 23637
23668 CssValue max([int compare(CssValue a, CssValue b)]) => Collections.max(this, c ompare); 23638 CssValue max([int compare(CssValue a, CssValue b)]) => IterableMixinWorkaround .max(this, compare);
23669 23639
23670 CssValue removeAt(int pos) { 23640 CssValue removeAt(int pos) {
23671 throw new UnsupportedError("Cannot removeAt on immutable List."); 23641 throw new UnsupportedError("Cannot removeAt on immutable List.");
23672 } 23642 }
23673 23643
23674 CssValue removeLast() { 23644 CssValue removeLast() {
23675 throw new UnsupportedError("Cannot removeLast on immutable List."); 23645 throw new UnsupportedError("Cannot removeLast on immutable List.");
23676 } 23646 }
23677 23647
23678 void setRange(int start, int rangeLength, List<CssValue> from, [int startFrom] ) { 23648 void setRange(int start, int rangeLength, List<CssValue> from, [int startFrom] ) {
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
23725 // From Iterable<Entry>: 23695 // From Iterable<Entry>:
23726 23696
23727 Iterator<Entry> get iterator { 23697 Iterator<Entry> get iterator {
23728 // Note: NodeLists are not fixed size. And most probably length shouldn't 23698 // Note: NodeLists are not fixed size. And most probably length shouldn't
23729 // be cached in both iterator _and_ forEach method. For now caching it 23699 // be cached in both iterator _and_ forEach method. For now caching it
23730 // for consistency. 23700 // for consistency.
23731 return new FixedSizeListIterator<Entry>(this); 23701 return new FixedSizeListIterator<Entry>(this);
23732 } 23702 }
23733 23703
23734 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Entry)) { 23704 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Entry)) {
23735 return Collections.reduce(this, initialValue, combine); 23705 return IterableMixinWorkaround.reduce(this, initialValue, combine);
23736 } 23706 }
23737 23707
23738 bool contains(Entry element) => Collections.contains(this, element); 23708 bool contains(Entry element) => IterableMixinWorkaround.contains(this, element );
23739 23709
23740 void forEach(void f(Entry element)) => Collections.forEach(this, f); 23710 void forEach(void f(Entry element)) => IterableMixinWorkaround.forEach(this, f );
23741 23711
23742 String join([String separator]) => Collections.joinList(this, separator); 23712 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
23743 23713
23744 List mappedBy(f(Entry element)) => new MappedList<Entry, dynamic>(this, f); 23714 List mappedBy(f(Entry element)) => IterableMixinWorkaround.mappedByList(this, f);
23745 23715
23746 Iterable<Entry> where(bool f(Entry element)) => new WhereIterable<Entry>(this, f); 23716 Iterable<Entry> where(bool f(Entry element)) => IterableMixinWorkaround.where( this, f);
23747 23717
23748 bool every(bool f(Entry element)) => Collections.every(this, f); 23718 bool every(bool f(Entry element)) => IterableMixinWorkaround.every(this, f);
23749 23719
23750 bool any(bool f(Entry element)) => Collections.any(this, f); 23720 bool any(bool f(Entry element)) => IterableMixinWorkaround.any(this, f);
23751 23721
23752 List<Entry> toList() => new List<Entry>.from(this); 23722 List<Entry> toList() => new List<Entry>.from(this);
23753 Set<Entry> toSet() => new Set<Entry>.from(this); 23723 Set<Entry> toSet() => new Set<Entry>.from(this);
23754 23724
23755 bool get isEmpty => this.length == 0; 23725 bool get isEmpty => this.length == 0;
23756 23726
23757 List<Entry> take(int n) => new ListView<Entry>(this, 0, n); 23727 List<Entry> take(int n) => IterableMixinWorkaround.takeList(this, n);
23758 23728
23759 Iterable<Entry> takeWhile(bool test(Entry value)) { 23729 Iterable<Entry> takeWhile(bool test(Entry value)) {
23760 return new TakeWhileIterable<Entry>(this, test); 23730 return IterableMixinWorkaround.takeWhile(this, test);
23761 } 23731 }
23762 23732
23763 List<Entry> skip(int n) => new ListView<Entry>(this, n, null); 23733 List<Entry> skip(int n) => IterableMixinWorkaround.skipList(this, n);
23764 23734
23765 Iterable<Entry> skipWhile(bool test(Entry value)) { 23735 Iterable<Entry> skipWhile(bool test(Entry value)) {
23766 return new SkipWhileIterable<Entry>(this, test); 23736 return IterableMixinWorkaround.skipWhile(this, test);
23767 } 23737 }
23768 23738
23769 Entry firstMatching(bool test(Entry value), { Entry orElse() }) { 23739 Entry firstMatching(bool test(Entry value), { Entry orElse() }) {
23770 return Collections.firstMatching(this, test, orElse); 23740 return IterableMixinWorkaround.firstMatching(this, test, orElse);
23771 } 23741 }
23772 23742
23773 Entry lastMatching(bool test(Entry value), {Entry orElse()}) { 23743 Entry lastMatching(bool test(Entry value), {Entry orElse()}) {
23774 return Collections.lastMatchingInList(this, test, orElse); 23744 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
23775 } 23745 }
23776 23746
23777 Entry singleMatching(bool test(Entry value)) { 23747 Entry singleMatching(bool test(Entry value)) {
23778 return Collections.singleMatching(this, test); 23748 return IterableMixinWorkaround.singleMatching(this, test);
23779 } 23749 }
23780 23750
23781 Entry elementAt(int index) { 23751 Entry elementAt(int index) {
23782 return this[index]; 23752 return this[index];
23783 } 23753 }
23784 23754
23785 // From Collection<Entry>: 23755 // From Collection<Entry>:
23786 23756
23787 void add(Entry value) { 23757 void add(Entry value) {
23788 throw new UnsupportedError("Cannot add to immutable List."); 23758 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
23826 if (this.length > 0) return this[this.length - 1]; 23796 if (this.length > 0) return this[this.length - 1];
23827 throw new StateError("No elements"); 23797 throw new StateError("No elements");
23828 } 23798 }
23829 23799
23830 Entry get single { 23800 Entry get single {
23831 if (length == 1) return this[0]; 23801 if (length == 1) return this[0];
23832 if (length == 0) throw new StateError("No elements"); 23802 if (length == 0) throw new StateError("No elements");
23833 throw new StateError("More than one element"); 23803 throw new StateError("More than one element");
23834 } 23804 }
23835 23805
23836 Entry min([int compare(Entry a, Entry b)]) => Collections.min(this, compare); 23806 Entry min([int compare(Entry a, Entry b)]) => IterableMixinWorkaround.min(this , compare);
23837 23807
23838 Entry max([int compare(Entry a, Entry b)]) => Collections.max(this, compare); 23808 Entry max([int compare(Entry a, Entry b)]) => IterableMixinWorkaround.max(this , compare);
23839 23809
23840 Entry removeAt(int pos) { 23810 Entry removeAt(int pos) {
23841 throw new UnsupportedError("Cannot removeAt on immutable List."); 23811 throw new UnsupportedError("Cannot removeAt on immutable List.");
23842 } 23812 }
23843 23813
23844 Entry removeLast() { 23814 Entry removeLast() {
23845 throw new UnsupportedError("Cannot removeLast on immutable List."); 23815 throw new UnsupportedError("Cannot removeLast on immutable List.");
23846 } 23816 }
23847 23817
23848 void setRange(int start, int rangeLength, List<Entry> from, [int startFrom]) { 23818 void setRange(int start, int rangeLength, List<Entry> from, [int startFrom]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
23887 // From Iterable<EntrySync>: 23857 // From Iterable<EntrySync>:
23888 23858
23889 Iterator<EntrySync> get iterator { 23859 Iterator<EntrySync> get iterator {
23890 // Note: NodeLists are not fixed size. And most probably length shouldn't 23860 // Note: NodeLists are not fixed size. And most probably length shouldn't
23891 // be cached in both iterator _and_ forEach method. For now caching it 23861 // be cached in both iterator _and_ forEach method. For now caching it
23892 // for consistency. 23862 // for consistency.
23893 return new FixedSizeListIterator<EntrySync>(this); 23863 return new FixedSizeListIterator<EntrySync>(this);
23894 } 23864 }
23895 23865
23896 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, EntrySync)) { 23866 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, EntrySync)) {
23897 return Collections.reduce(this, initialValue, combine); 23867 return IterableMixinWorkaround.reduce(this, initialValue, combine);
23898 } 23868 }
23899 23869
23900 bool contains(EntrySync element) => Collections.contains(this, element); 23870 bool contains(EntrySync element) => IterableMixinWorkaround.contains(this, ele ment);
23901 23871
23902 void forEach(void f(EntrySync element)) => Collections.forEach(this, f); 23872 void forEach(void f(EntrySync element)) => IterableMixinWorkaround.forEach(thi s, f);
23903 23873
23904 String join([String separator]) => Collections.joinList(this, separator); 23874 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
23905 23875
23906 List mappedBy(f(EntrySync element)) => new MappedList<EntrySync, dynamic>(this , f); 23876 List mappedBy(f(EntrySync element)) => IterableMixinWorkaround.mappedByList(th is, f);
23907 23877
23908 Iterable<EntrySync> where(bool f(EntrySync element)) => new WhereIterable<Entr ySync>(this, f); 23878 Iterable<EntrySync> where(bool f(EntrySync element)) => IterableMixinWorkaroun d.where(this, f);
23909 23879
23910 bool every(bool f(EntrySync element)) => Collections.every(this, f); 23880 bool every(bool f(EntrySync element)) => IterableMixinWorkaround.every(this, f );
23911 23881
23912 bool any(bool f(EntrySync element)) => Collections.any(this, f); 23882 bool any(bool f(EntrySync element)) => IterableMixinWorkaround.any(this, f);
23913 23883
23914 List<EntrySync> toList() => new List<EntrySync>.from(this); 23884 List<EntrySync> toList() => new List<EntrySync>.from(this);
23915 Set<EntrySync> toSet() => new Set<EntrySync>.from(this); 23885 Set<EntrySync> toSet() => new Set<EntrySync>.from(this);
23916 23886
23917 bool get isEmpty => this.length == 0; 23887 bool get isEmpty => this.length == 0;
23918 23888
23919 List<EntrySync> take(int n) => new ListView<EntrySync>(this, 0, n); 23889 List<EntrySync> take(int n) => IterableMixinWorkaround.takeList(this, n);
23920 23890
23921 Iterable<EntrySync> takeWhile(bool test(EntrySync value)) { 23891 Iterable<EntrySync> takeWhile(bool test(EntrySync value)) {
23922 return new TakeWhileIterable<EntrySync>(this, test); 23892 return IterableMixinWorkaround.takeWhile(this, test);
23923 } 23893 }
23924 23894
23925 List<EntrySync> skip(int n) => new ListView<EntrySync>(this, n, null); 23895 List<EntrySync> skip(int n) => IterableMixinWorkaround.skipList(this, n);
23926 23896
23927 Iterable<EntrySync> skipWhile(bool test(EntrySync value)) { 23897 Iterable<EntrySync> skipWhile(bool test(EntrySync value)) {
23928 return new SkipWhileIterable<EntrySync>(this, test); 23898 return IterableMixinWorkaround.skipWhile(this, test);
23929 } 23899 }
23930 23900
23931 EntrySync firstMatching(bool test(EntrySync value), { EntrySync orElse() }) { 23901 EntrySync firstMatching(bool test(EntrySync value), { EntrySync orElse() }) {
23932 return Collections.firstMatching(this, test, orElse); 23902 return IterableMixinWorkaround.firstMatching(this, test, orElse);
23933 } 23903 }
23934 23904
23935 EntrySync lastMatching(bool test(EntrySync value), {EntrySync orElse()}) { 23905 EntrySync lastMatching(bool test(EntrySync value), {EntrySync orElse()}) {
23936 return Collections.lastMatchingInList(this, test, orElse); 23906 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
23937 } 23907 }
23938 23908
23939 EntrySync singleMatching(bool test(EntrySync value)) { 23909 EntrySync singleMatching(bool test(EntrySync value)) {
23940 return Collections.singleMatching(this, test); 23910 return IterableMixinWorkaround.singleMatching(this, test);
23941 } 23911 }
23942 23912
23943 EntrySync elementAt(int index) { 23913 EntrySync elementAt(int index) {
23944 return this[index]; 23914 return this[index];
23945 } 23915 }
23946 23916
23947 // From Collection<EntrySync>: 23917 // From Collection<EntrySync>:
23948 23918
23949 void add(EntrySync value) { 23919 void add(EntrySync value) {
23950 throw new UnsupportedError("Cannot add to immutable List."); 23920 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
23988 if (this.length > 0) return this[this.length - 1]; 23958 if (this.length > 0) return this[this.length - 1];
23989 throw new StateError("No elements"); 23959 throw new StateError("No elements");
23990 } 23960 }
23991 23961
23992 EntrySync get single { 23962 EntrySync get single {
23993 if (length == 1) return this[0]; 23963 if (length == 1) return this[0];
23994 if (length == 0) throw new StateError("No elements"); 23964 if (length == 0) throw new StateError("No elements");
23995 throw new StateError("More than one element"); 23965 throw new StateError("More than one element");
23996 } 23966 }
23997 23967
23998 EntrySync min([int compare(EntrySync a, EntrySync b)]) => Collections.min(this , compare); 23968 EntrySync min([int compare(EntrySync a, EntrySync b)]) => IterableMixinWorkaro und.min(this, compare);
23999 23969
24000 EntrySync max([int compare(EntrySync a, EntrySync b)]) => Collections.max(this , compare); 23970 EntrySync max([int compare(EntrySync a, EntrySync b)]) => IterableMixinWorkaro und.max(this, compare);
24001 23971
24002 EntrySync removeAt(int pos) { 23972 EntrySync removeAt(int pos) {
24003 throw new UnsupportedError("Cannot removeAt on immutable List."); 23973 throw new UnsupportedError("Cannot removeAt on immutable List.");
24004 } 23974 }
24005 23975
24006 EntrySync removeLast() { 23976 EntrySync removeLast() {
24007 throw new UnsupportedError("Cannot removeLast on immutable List."); 23977 throw new UnsupportedError("Cannot removeLast on immutable List.");
24008 } 23978 }
24009 23979
24010 void setRange(int start, int rangeLength, List<EntrySync> from, [int startFrom ]) { 23980 void setRange(int start, int rangeLength, List<EntrySync> from, [int startFrom ]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
24049 // From Iterable<Gamepad>: 24019 // From Iterable<Gamepad>:
24050 24020
24051 Iterator<Gamepad> get iterator { 24021 Iterator<Gamepad> get iterator {
24052 // Note: NodeLists are not fixed size. And most probably length shouldn't 24022 // Note: NodeLists are not fixed size. And most probably length shouldn't
24053 // be cached in both iterator _and_ forEach method. For now caching it 24023 // be cached in both iterator _and_ forEach method. For now caching it
24054 // for consistency. 24024 // for consistency.
24055 return new FixedSizeListIterator<Gamepad>(this); 24025 return new FixedSizeListIterator<Gamepad>(this);
24056 } 24026 }
24057 24027
24058 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Gamepad)) { 24028 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, Gamepad)) {
24059 return Collections.reduce(this, initialValue, combine); 24029 return IterableMixinWorkaround.reduce(this, initialValue, combine);
24060 } 24030 }
24061 24031
24062 bool contains(Gamepad element) => Collections.contains(this, element); 24032 bool contains(Gamepad element) => IterableMixinWorkaround.contains(this, eleme nt);
24063 24033
24064 void forEach(void f(Gamepad element)) => Collections.forEach(this, f); 24034 void forEach(void f(Gamepad element)) => IterableMixinWorkaround.forEach(this, f);
24065 24035
24066 String join([String separator]) => Collections.joinList(this, separator); 24036 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
24067 24037
24068 List mappedBy(f(Gamepad element)) => new MappedList<Gamepad, dynamic>(this, f) ; 24038 List mappedBy(f(Gamepad element)) => IterableMixinWorkaround.mappedByList(this , f);
24069 24039
24070 Iterable<Gamepad> where(bool f(Gamepad element)) => new WhereIterable<Gamepad> (this, f); 24040 Iterable<Gamepad> where(bool f(Gamepad element)) => IterableMixinWorkaround.wh ere(this, f);
24071 24041
24072 bool every(bool f(Gamepad element)) => Collections.every(this, f); 24042 bool every(bool f(Gamepad element)) => IterableMixinWorkaround.every(this, f);
24073 24043
24074 bool any(bool f(Gamepad element)) => Collections.any(this, f); 24044 bool any(bool f(Gamepad element)) => IterableMixinWorkaround.any(this, f);
24075 24045
24076 List<Gamepad> toList() => new List<Gamepad>.from(this); 24046 List<Gamepad> toList() => new List<Gamepad>.from(this);
24077 Set<Gamepad> toSet() => new Set<Gamepad>.from(this); 24047 Set<Gamepad> toSet() => new Set<Gamepad>.from(this);
24078 24048
24079 bool get isEmpty => this.length == 0; 24049 bool get isEmpty => this.length == 0;
24080 24050
24081 List<Gamepad> take(int n) => new ListView<Gamepad>(this, 0, n); 24051 List<Gamepad> take(int n) => IterableMixinWorkaround.takeList(this, n);
24082 24052
24083 Iterable<Gamepad> takeWhile(bool test(Gamepad value)) { 24053 Iterable<Gamepad> takeWhile(bool test(Gamepad value)) {
24084 return new TakeWhileIterable<Gamepad>(this, test); 24054 return IterableMixinWorkaround.takeWhile(this, test);
24085 } 24055 }
24086 24056
24087 List<Gamepad> skip(int n) => new ListView<Gamepad>(this, n, null); 24057 List<Gamepad> skip(int n) => IterableMixinWorkaround.skipList(this, n);
24088 24058
24089 Iterable<Gamepad> skipWhile(bool test(Gamepad value)) { 24059 Iterable<Gamepad> skipWhile(bool test(Gamepad value)) {
24090 return new SkipWhileIterable<Gamepad>(this, test); 24060 return IterableMixinWorkaround.skipWhile(this, test);
24091 } 24061 }
24092 24062
24093 Gamepad firstMatching(bool test(Gamepad value), { Gamepad orElse() }) { 24063 Gamepad firstMatching(bool test(Gamepad value), { Gamepad orElse() }) {
24094 return Collections.firstMatching(this, test, orElse); 24064 return IterableMixinWorkaround.firstMatching(this, test, orElse);
24095 } 24065 }
24096 24066
24097 Gamepad lastMatching(bool test(Gamepad value), {Gamepad orElse()}) { 24067 Gamepad lastMatching(bool test(Gamepad value), {Gamepad orElse()}) {
24098 return Collections.lastMatchingInList(this, test, orElse); 24068 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
24099 } 24069 }
24100 24070
24101 Gamepad singleMatching(bool test(Gamepad value)) { 24071 Gamepad singleMatching(bool test(Gamepad value)) {
24102 return Collections.singleMatching(this, test); 24072 return IterableMixinWorkaround.singleMatching(this, test);
24103 } 24073 }
24104 24074
24105 Gamepad elementAt(int index) { 24075 Gamepad elementAt(int index) {
24106 return this[index]; 24076 return this[index];
24107 } 24077 }
24108 24078
24109 // From Collection<Gamepad>: 24079 // From Collection<Gamepad>:
24110 24080
24111 void add(Gamepad value) { 24081 void add(Gamepad value) {
24112 throw new UnsupportedError("Cannot add to immutable List."); 24082 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
24150 if (this.length > 0) return this[this.length - 1]; 24120 if (this.length > 0) return this[this.length - 1];
24151 throw new StateError("No elements"); 24121 throw new StateError("No elements");
24152 } 24122 }
24153 24123
24154 Gamepad get single { 24124 Gamepad get single {
24155 if (length == 1) return this[0]; 24125 if (length == 1) return this[0];
24156 if (length == 0) throw new StateError("No elements"); 24126 if (length == 0) throw new StateError("No elements");
24157 throw new StateError("More than one element"); 24127 throw new StateError("More than one element");
24158 } 24128 }
24159 24129
24160 Gamepad min([int compare(Gamepad a, Gamepad b)]) => Collections.min(this, comp are); 24130 Gamepad min([int compare(Gamepad a, Gamepad b)]) => IterableMixinWorkaround.mi n(this, compare);
24161 24131
24162 Gamepad max([int compare(Gamepad a, Gamepad b)]) => Collections.max(this, comp are); 24132 Gamepad max([int compare(Gamepad a, Gamepad b)]) => IterableMixinWorkaround.ma x(this, compare);
24163 24133
24164 Gamepad removeAt(int pos) { 24134 Gamepad removeAt(int pos) {
24165 throw new UnsupportedError("Cannot removeAt on immutable List."); 24135 throw new UnsupportedError("Cannot removeAt on immutable List.");
24166 } 24136 }
24167 24137
24168 Gamepad removeLast() { 24138 Gamepad removeLast() {
24169 throw new UnsupportedError("Cannot removeLast on immutable List."); 24139 throw new UnsupportedError("Cannot removeLast on immutable List.");
24170 } 24140 }
24171 24141
24172 void setRange(int start, int rangeLength, List<Gamepad> from, [int startFrom]) { 24142 void setRange(int start, int rangeLength, List<Gamepad> from, [int startFrom]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
24211 // From Iterable<MediaStream>: 24181 // From Iterable<MediaStream>:
24212 24182
24213 Iterator<MediaStream> get iterator { 24183 Iterator<MediaStream> get iterator {
24214 // Note: NodeLists are not fixed size. And most probably length shouldn't 24184 // Note: NodeLists are not fixed size. And most probably length shouldn't
24215 // be cached in both iterator _and_ forEach method. For now caching it 24185 // be cached in both iterator _and_ forEach method. For now caching it
24216 // for consistency. 24186 // for consistency.
24217 return new FixedSizeListIterator<MediaStream>(this); 24187 return new FixedSizeListIterator<MediaStream>(this);
24218 } 24188 }
24219 24189
24220 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, MediaStream)) { 24190 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, MediaStream)) {
24221 return Collections.reduce(this, initialValue, combine); 24191 return IterableMixinWorkaround.reduce(this, initialValue, combine);
24222 } 24192 }
24223 24193
24224 bool contains(MediaStream element) => Collections.contains(this, element); 24194 bool contains(MediaStream element) => IterableMixinWorkaround.contains(this, e lement);
24225 24195
24226 void forEach(void f(MediaStream element)) => Collections.forEach(this, f); 24196 void forEach(void f(MediaStream element)) => IterableMixinWorkaround.forEach(t his, f);
24227 24197
24228 String join([String separator]) => Collections.joinList(this, separator); 24198 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
24229 24199
24230 List mappedBy(f(MediaStream element)) => new MappedList<MediaStream, dynamic>( this, f); 24200 List mappedBy(f(MediaStream element)) => IterableMixinWorkaround.mappedByList( this, f);
24231 24201
24232 Iterable<MediaStream> where(bool f(MediaStream element)) => new WhereIterable< MediaStream>(this, f); 24202 Iterable<MediaStream> where(bool f(MediaStream element)) => IterableMixinWorka round.where(this, f);
24233 24203
24234 bool every(bool f(MediaStream element)) => Collections.every(this, f); 24204 bool every(bool f(MediaStream element)) => IterableMixinWorkaround.every(this, f);
24235 24205
24236 bool any(bool f(MediaStream element)) => Collections.any(this, f); 24206 bool any(bool f(MediaStream element)) => IterableMixinWorkaround.any(this, f);
24237 24207
24238 List<MediaStream> toList() => new List<MediaStream>.from(this); 24208 List<MediaStream> toList() => new List<MediaStream>.from(this);
24239 Set<MediaStream> toSet() => new Set<MediaStream>.from(this); 24209 Set<MediaStream> toSet() => new Set<MediaStream>.from(this);
24240 24210
24241 bool get isEmpty => this.length == 0; 24211 bool get isEmpty => this.length == 0;
24242 24212
24243 List<MediaStream> take(int n) => new ListView<MediaStream>(this, 0, n); 24213 List<MediaStream> take(int n) => IterableMixinWorkaround.takeList(this, n);
24244 24214
24245 Iterable<MediaStream> takeWhile(bool test(MediaStream value)) { 24215 Iterable<MediaStream> takeWhile(bool test(MediaStream value)) {
24246 return new TakeWhileIterable<MediaStream>(this, test); 24216 return IterableMixinWorkaround.takeWhile(this, test);
24247 } 24217 }
24248 24218
24249 List<MediaStream> skip(int n) => new ListView<MediaStream>(this, n, null); 24219 List<MediaStream> skip(int n) => IterableMixinWorkaround.skipList(this, n);
24250 24220
24251 Iterable<MediaStream> skipWhile(bool test(MediaStream value)) { 24221 Iterable<MediaStream> skipWhile(bool test(MediaStream value)) {
24252 return new SkipWhileIterable<MediaStream>(this, test); 24222 return IterableMixinWorkaround.skipWhile(this, test);
24253 } 24223 }
24254 24224
24255 MediaStream firstMatching(bool test(MediaStream value), { MediaStream orElse() }) { 24225 MediaStream firstMatching(bool test(MediaStream value), { MediaStream orElse() }) {
24256 return Collections.firstMatching(this, test, orElse); 24226 return IterableMixinWorkaround.firstMatching(this, test, orElse);
24257 } 24227 }
24258 24228
24259 MediaStream lastMatching(bool test(MediaStream value), {MediaStream orElse()}) { 24229 MediaStream lastMatching(bool test(MediaStream value), {MediaStream orElse()}) {
24260 return Collections.lastMatchingInList(this, test, orElse); 24230 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
24261 } 24231 }
24262 24232
24263 MediaStream singleMatching(bool test(MediaStream value)) { 24233 MediaStream singleMatching(bool test(MediaStream value)) {
24264 return Collections.singleMatching(this, test); 24234 return IterableMixinWorkaround.singleMatching(this, test);
24265 } 24235 }
24266 24236
24267 MediaStream elementAt(int index) { 24237 MediaStream elementAt(int index) {
24268 return this[index]; 24238 return this[index];
24269 } 24239 }
24270 24240
24271 // From Collection<MediaStream>: 24241 // From Collection<MediaStream>:
24272 24242
24273 void add(MediaStream value) { 24243 void add(MediaStream value) {
24274 throw new UnsupportedError("Cannot add to immutable List."); 24244 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
24312 if (this.length > 0) return this[this.length - 1]; 24282 if (this.length > 0) return this[this.length - 1];
24313 throw new StateError("No elements"); 24283 throw new StateError("No elements");
24314 } 24284 }
24315 24285
24316 MediaStream get single { 24286 MediaStream get single {
24317 if (length == 1) return this[0]; 24287 if (length == 1) return this[0];
24318 if (length == 0) throw new StateError("No elements"); 24288 if (length == 0) throw new StateError("No elements");
24319 throw new StateError("More than one element"); 24289 throw new StateError("More than one element");
24320 } 24290 }
24321 24291
24322 MediaStream min([int compare(MediaStream a, MediaStream b)]) => Collections.mi n(this, compare); 24292 MediaStream min([int compare(MediaStream a, MediaStream b)]) => IterableMixinW orkaround.min(this, compare);
24323 24293
24324 MediaStream max([int compare(MediaStream a, MediaStream b)]) => Collections.ma x(this, compare); 24294 MediaStream max([int compare(MediaStream a, MediaStream b)]) => IterableMixinW orkaround.max(this, compare);
24325 24295
24326 MediaStream removeAt(int pos) { 24296 MediaStream removeAt(int pos) {
24327 throw new UnsupportedError("Cannot removeAt on immutable List."); 24297 throw new UnsupportedError("Cannot removeAt on immutable List.");
24328 } 24298 }
24329 24299
24330 MediaStream removeLast() { 24300 MediaStream removeLast() {
24331 throw new UnsupportedError("Cannot removeLast on immutable List."); 24301 throw new UnsupportedError("Cannot removeLast on immutable List.");
24332 } 24302 }
24333 24303
24334 void setRange(int start, int rangeLength, List<MediaStream> from, [int startFr om]) { 24304 void setRange(int start, int rangeLength, List<MediaStream> from, [int startFr om]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
24373 // From Iterable<SpeechInputResult>: 24343 // From Iterable<SpeechInputResult>:
24374 24344
24375 Iterator<SpeechInputResult> get iterator { 24345 Iterator<SpeechInputResult> get iterator {
24376 // Note: NodeLists are not fixed size. And most probably length shouldn't 24346 // Note: NodeLists are not fixed size. And most probably length shouldn't
24377 // be cached in both iterator _and_ forEach method. For now caching it 24347 // be cached in both iterator _and_ forEach method. For now caching it
24378 // for consistency. 24348 // for consistency.
24379 return new FixedSizeListIterator<SpeechInputResult>(this); 24349 return new FixedSizeListIterator<SpeechInputResult>(this);
24380 } 24350 }
24381 24351
24382 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechInputResul t)) { 24352 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechInputResul t)) {
24383 return Collections.reduce(this, initialValue, combine); 24353 return IterableMixinWorkaround.reduce(this, initialValue, combine);
24384 } 24354 }
24385 24355
24386 bool contains(SpeechInputResult element) => Collections.contains(this, element ); 24356 bool contains(SpeechInputResult element) => IterableMixinWorkaround.contains(t his, element);
24387 24357
24388 void forEach(void f(SpeechInputResult element)) => Collections.forEach(this, f ); 24358 void forEach(void f(SpeechInputResult element)) => IterableMixinWorkaround.for Each(this, f);
24389 24359
24390 String join([String separator]) => Collections.joinList(this, separator); 24360 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
24391 24361
24392 List mappedBy(f(SpeechInputResult element)) => new MappedList<SpeechInputResul t, dynamic>(this, f); 24362 List mappedBy(f(SpeechInputResult element)) => IterableMixinWorkaround.mappedB yList(this, f);
24393 24363
24394 Iterable<SpeechInputResult> where(bool f(SpeechInputResult element)) => new Wh ereIterable<SpeechInputResult>(this, f); 24364 Iterable<SpeechInputResult> where(bool f(SpeechInputResult element)) => Iterab leMixinWorkaround.where(this, f);
24395 24365
24396 bool every(bool f(SpeechInputResult element)) => Collections.every(this, f); 24366 bool every(bool f(SpeechInputResult element)) => IterableMixinWorkaround.every (this, f);
24397 24367
24398 bool any(bool f(SpeechInputResult element)) => Collections.any(this, f); 24368 bool any(bool f(SpeechInputResult element)) => IterableMixinWorkaround.any(thi s, f);
24399 24369
24400 List<SpeechInputResult> toList() => new List<SpeechInputResult>.from(this); 24370 List<SpeechInputResult> toList() => new List<SpeechInputResult>.from(this);
24401 Set<SpeechInputResult> toSet() => new Set<SpeechInputResult>.from(this); 24371 Set<SpeechInputResult> toSet() => new Set<SpeechInputResult>.from(this);
24402 24372
24403 bool get isEmpty => this.length == 0; 24373 bool get isEmpty => this.length == 0;
24404 24374
24405 List<SpeechInputResult> take(int n) => new ListView<SpeechInputResult>(this, 0 , n); 24375 List<SpeechInputResult> take(int n) => IterableMixinWorkaround.takeList(this, n);
24406 24376
24407 Iterable<SpeechInputResult> takeWhile(bool test(SpeechInputResult value)) { 24377 Iterable<SpeechInputResult> takeWhile(bool test(SpeechInputResult value)) {
24408 return new TakeWhileIterable<SpeechInputResult>(this, test); 24378 return IterableMixinWorkaround.takeWhile(this, test);
24409 } 24379 }
24410 24380
24411 List<SpeechInputResult> skip(int n) => new ListView<SpeechInputResult>(this, n , null); 24381 List<SpeechInputResult> skip(int n) => IterableMixinWorkaround.skipList(this, n);
24412 24382
24413 Iterable<SpeechInputResult> skipWhile(bool test(SpeechInputResult value)) { 24383 Iterable<SpeechInputResult> skipWhile(bool test(SpeechInputResult value)) {
24414 return new SkipWhileIterable<SpeechInputResult>(this, test); 24384 return IterableMixinWorkaround.skipWhile(this, test);
24415 } 24385 }
24416 24386
24417 SpeechInputResult firstMatching(bool test(SpeechInputResult value), { SpeechIn putResult orElse() }) { 24387 SpeechInputResult firstMatching(bool test(SpeechInputResult value), { SpeechIn putResult orElse() }) {
24418 return Collections.firstMatching(this, test, orElse); 24388 return IterableMixinWorkaround.firstMatching(this, test, orElse);
24419 } 24389 }
24420 24390
24421 SpeechInputResult lastMatching(bool test(SpeechInputResult value), {SpeechInpu tResult orElse()}) { 24391 SpeechInputResult lastMatching(bool test(SpeechInputResult value), {SpeechInpu tResult orElse()}) {
24422 return Collections.lastMatchingInList(this, test, orElse); 24392 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
24423 } 24393 }
24424 24394
24425 SpeechInputResult singleMatching(bool test(SpeechInputResult value)) { 24395 SpeechInputResult singleMatching(bool test(SpeechInputResult value)) {
24426 return Collections.singleMatching(this, test); 24396 return IterableMixinWorkaround.singleMatching(this, test);
24427 } 24397 }
24428 24398
24429 SpeechInputResult elementAt(int index) { 24399 SpeechInputResult elementAt(int index) {
24430 return this[index]; 24400 return this[index];
24431 } 24401 }
24432 24402
24433 // From Collection<SpeechInputResult>: 24403 // From Collection<SpeechInputResult>:
24434 24404
24435 void add(SpeechInputResult value) { 24405 void add(SpeechInputResult value) {
24436 throw new UnsupportedError("Cannot add to immutable List."); 24406 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
24474 if (this.length > 0) return this[this.length - 1]; 24444 if (this.length > 0) return this[this.length - 1];
24475 throw new StateError("No elements"); 24445 throw new StateError("No elements");
24476 } 24446 }
24477 24447
24478 SpeechInputResult get single { 24448 SpeechInputResult get single {
24479 if (length == 1) return this[0]; 24449 if (length == 1) return this[0];
24480 if (length == 0) throw new StateError("No elements"); 24450 if (length == 0) throw new StateError("No elements");
24481 throw new StateError("More than one element"); 24451 throw new StateError("More than one element");
24482 } 24452 }
24483 24453
24484 SpeechInputResult min([int compare(SpeechInputResult a, SpeechInputResult b)]) => Collections.min(this, compare); 24454 SpeechInputResult min([int compare(SpeechInputResult a, SpeechInputResult b)]) => IterableMixinWorkaround.min(this, compare);
24485 24455
24486 SpeechInputResult max([int compare(SpeechInputResult a, SpeechInputResult b)]) => Collections.max(this, compare); 24456 SpeechInputResult max([int compare(SpeechInputResult a, SpeechInputResult b)]) => IterableMixinWorkaround.max(this, compare);
24487 24457
24488 SpeechInputResult removeAt(int pos) { 24458 SpeechInputResult removeAt(int pos) {
24489 throw new UnsupportedError("Cannot removeAt on immutable List."); 24459 throw new UnsupportedError("Cannot removeAt on immutable List.");
24490 } 24460 }
24491 24461
24492 SpeechInputResult removeLast() { 24462 SpeechInputResult removeLast() {
24493 throw new UnsupportedError("Cannot removeLast on immutable List."); 24463 throw new UnsupportedError("Cannot removeLast on immutable List.");
24494 } 24464 }
24495 24465
24496 void setRange(int start, int rangeLength, List<SpeechInputResult> from, [int s tartFrom]) { 24466 void setRange(int start, int rangeLength, List<SpeechInputResult> from, [int s tartFrom]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
24535 // From Iterable<SpeechRecognitionResult>: 24505 // From Iterable<SpeechRecognitionResult>:
24536 24506
24537 Iterator<SpeechRecognitionResult> get iterator { 24507 Iterator<SpeechRecognitionResult> get iterator {
24538 // Note: NodeLists are not fixed size. And most probably length shouldn't 24508 // Note: NodeLists are not fixed size. And most probably length shouldn't
24539 // be cached in both iterator _and_ forEach method. For now caching it 24509 // be cached in both iterator _and_ forEach method. For now caching it
24540 // for consistency. 24510 // for consistency.
24541 return new FixedSizeListIterator<SpeechRecognitionResult>(this); 24511 return new FixedSizeListIterator<SpeechRecognitionResult>(this);
24542 } 24512 }
24543 24513
24544 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechRecognitio nResult)) { 24514 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, SpeechRecognitio nResult)) {
24545 return Collections.reduce(this, initialValue, combine); 24515 return IterableMixinWorkaround.reduce(this, initialValue, combine);
24546 } 24516 }
24547 24517
24548 bool contains(SpeechRecognitionResult element) => Collections.contains(this, e lement); 24518 bool contains(SpeechRecognitionResult element) => IterableMixinWorkaround.cont ains(this, element);
24549 24519
24550 void forEach(void f(SpeechRecognitionResult element)) => Collections.forEach(t his, f); 24520 void forEach(void f(SpeechRecognitionResult element)) => IterableMixinWorkarou nd.forEach(this, f);
24551 24521
24552 String join([String separator]) => Collections.joinList(this, separator); 24522 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
24553 24523
24554 List mappedBy(f(SpeechRecognitionResult element)) => new MappedList<SpeechReco gnitionResult, dynamic>(this, f); 24524 List mappedBy(f(SpeechRecognitionResult element)) => IterableMixinWorkaround.m appedByList(this, f);
24555 24525
24556 Iterable<SpeechRecognitionResult> where(bool f(SpeechRecognitionResult element )) => new WhereIterable<SpeechRecognitionResult>(this, f); 24526 Iterable<SpeechRecognitionResult> where(bool f(SpeechRecognitionResult element )) => IterableMixinWorkaround.where(this, f);
24557 24527
24558 bool every(bool f(SpeechRecognitionResult element)) => Collections.every(this, f); 24528 bool every(bool f(SpeechRecognitionResult element)) => IterableMixinWorkaround .every(this, f);
24559 24529
24560 bool any(bool f(SpeechRecognitionResult element)) => Collections.any(this, f); 24530 bool any(bool f(SpeechRecognitionResult element)) => IterableMixinWorkaround.a ny(this, f);
24561 24531
24562 List<SpeechRecognitionResult> toList() => new List<SpeechRecognitionResult>.fr om(this); 24532 List<SpeechRecognitionResult> toList() => new List<SpeechRecognitionResult>.fr om(this);
24563 Set<SpeechRecognitionResult> toSet() => new Set<SpeechRecognitionResult>.from( this); 24533 Set<SpeechRecognitionResult> toSet() => new Set<SpeechRecognitionResult>.from( this);
24564 24534
24565 bool get isEmpty => this.length == 0; 24535 bool get isEmpty => this.length == 0;
24566 24536
24567 List<SpeechRecognitionResult> take(int n) => new ListView<SpeechRecognitionRes ult>(this, 0, n); 24537 List<SpeechRecognitionResult> take(int n) => IterableMixinWorkaround.takeList( this, n);
24568 24538
24569 Iterable<SpeechRecognitionResult> takeWhile(bool test(SpeechRecognitionResult value)) { 24539 Iterable<SpeechRecognitionResult> takeWhile(bool test(SpeechRecognitionResult value)) {
24570 return new TakeWhileIterable<SpeechRecognitionResult>(this, test); 24540 return IterableMixinWorkaround.takeWhile(this, test);
24571 } 24541 }
24572 24542
24573 List<SpeechRecognitionResult> skip(int n) => new ListView<SpeechRecognitionRes ult>(this, n, null); 24543 List<SpeechRecognitionResult> skip(int n) => IterableMixinWorkaround.skipList( this, n);
24574 24544
24575 Iterable<SpeechRecognitionResult> skipWhile(bool test(SpeechRecognitionResult value)) { 24545 Iterable<SpeechRecognitionResult> skipWhile(bool test(SpeechRecognitionResult value)) {
24576 return new SkipWhileIterable<SpeechRecognitionResult>(this, test); 24546 return IterableMixinWorkaround.skipWhile(this, test);
24577 } 24547 }
24578 24548
24579 SpeechRecognitionResult firstMatching(bool test(SpeechRecognitionResult value) , { SpeechRecognitionResult orElse() }) { 24549 SpeechRecognitionResult firstMatching(bool test(SpeechRecognitionResult value) , { SpeechRecognitionResult orElse() }) {
24580 return Collections.firstMatching(this, test, orElse); 24550 return IterableMixinWorkaround.firstMatching(this, test, orElse);
24581 } 24551 }
24582 24552
24583 SpeechRecognitionResult lastMatching(bool test(SpeechRecognitionResult value), {SpeechRecognitionResult orElse()}) { 24553 SpeechRecognitionResult lastMatching(bool test(SpeechRecognitionResult value), {SpeechRecognitionResult orElse()}) {
24584 return Collections.lastMatchingInList(this, test, orElse); 24554 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
24585 } 24555 }
24586 24556
24587 SpeechRecognitionResult singleMatching(bool test(SpeechRecognitionResult value )) { 24557 SpeechRecognitionResult singleMatching(bool test(SpeechRecognitionResult value )) {
24588 return Collections.singleMatching(this, test); 24558 return IterableMixinWorkaround.singleMatching(this, test);
24589 } 24559 }
24590 24560
24591 SpeechRecognitionResult elementAt(int index) { 24561 SpeechRecognitionResult elementAt(int index) {
24592 return this[index]; 24562 return this[index];
24593 } 24563 }
24594 24564
24595 // From Collection<SpeechRecognitionResult>: 24565 // From Collection<SpeechRecognitionResult>:
24596 24566
24597 void add(SpeechRecognitionResult value) { 24567 void add(SpeechRecognitionResult value) {
24598 throw new UnsupportedError("Cannot add to immutable List."); 24568 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
24636 if (this.length > 0) return this[this.length - 1]; 24606 if (this.length > 0) return this[this.length - 1];
24637 throw new StateError("No elements"); 24607 throw new StateError("No elements");
24638 } 24608 }
24639 24609
24640 SpeechRecognitionResult get single { 24610 SpeechRecognitionResult get single {
24641 if (length == 1) return this[0]; 24611 if (length == 1) return this[0];
24642 if (length == 0) throw new StateError("No elements"); 24612 if (length == 0) throw new StateError("No elements");
24643 throw new StateError("More than one element"); 24613 throw new StateError("More than one element");
24644 } 24614 }
24645 24615
24646 SpeechRecognitionResult min([int compare(SpeechRecognitionResult a, SpeechReco gnitionResult b)]) => Collections.min(this, compare); 24616 SpeechRecognitionResult min([int compare(SpeechRecognitionResult a, SpeechReco gnitionResult b)]) => IterableMixinWorkaround.min(this, compare);
24647 24617
24648 SpeechRecognitionResult max([int compare(SpeechRecognitionResult a, SpeechReco gnitionResult b)]) => Collections.max(this, compare); 24618 SpeechRecognitionResult max([int compare(SpeechRecognitionResult a, SpeechReco gnitionResult b)]) => IterableMixinWorkaround.max(this, compare);
24649 24619
24650 SpeechRecognitionResult removeAt(int pos) { 24620 SpeechRecognitionResult removeAt(int pos) {
24651 throw new UnsupportedError("Cannot removeAt on immutable List."); 24621 throw new UnsupportedError("Cannot removeAt on immutable List.");
24652 } 24622 }
24653 24623
24654 SpeechRecognitionResult removeLast() { 24624 SpeechRecognitionResult removeLast() {
24655 throw new UnsupportedError("Cannot removeLast on immutable List."); 24625 throw new UnsupportedError("Cannot removeLast on immutable List.");
24656 } 24626 }
24657 24627
24658 void setRange(int start, int rangeLength, List<SpeechRecognitionResult> from, [int startFrom]) { 24628 void setRange(int start, int rangeLength, List<SpeechRecognitionResult> from, [int startFrom]) {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
24697 // From Iterable<StyleSheet>: 24667 // From Iterable<StyleSheet>:
24698 24668
24699 Iterator<StyleSheet> get iterator { 24669 Iterator<StyleSheet> get iterator {
24700 // Note: NodeLists are not fixed size. And most probably length shouldn't 24670 // Note: NodeLists are not fixed size. And most probably length shouldn't
24701 // be cached in both iterator _and_ forEach method. For now caching it 24671 // be cached in both iterator _and_ forEach method. For now caching it
24702 // for consistency. 24672 // for consistency.
24703 return new FixedSizeListIterator<StyleSheet>(this); 24673 return new FixedSizeListIterator<StyleSheet>(this);
24704 } 24674 }
24705 24675
24706 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, StyleSheet)) { 24676 dynamic reduce(dynamic initialValue, dynamic combine(dynamic, StyleSheet)) {
24707 return Collections.reduce(this, initialValue, combine); 24677 return IterableMixinWorkaround.reduce(this, initialValue, combine);
24708 } 24678 }
24709 24679
24710 bool contains(StyleSheet element) => Collections.contains(this, element); 24680 bool contains(StyleSheet element) => IterableMixinWorkaround.contains(this, el ement);
24711 24681
24712 void forEach(void f(StyleSheet element)) => Collections.forEach(this, f); 24682 void forEach(void f(StyleSheet element)) => IterableMixinWorkaround.forEach(th is, f);
24713 24683
24714 String join([String separator]) => Collections.joinList(this, separator); 24684 String join([String separator]) => IterableMixinWorkaround.joinList(this, sepa rator);
24715 24685
24716 List mappedBy(f(StyleSheet element)) => new MappedList<StyleSheet, dynamic>(th is, f); 24686 List mappedBy(f(StyleSheet element)) => IterableMixinWorkaround.mappedByList(t his, f);
24717 24687
24718 Iterable<StyleSheet> where(bool f(StyleSheet element)) => new WhereIterable<St yleSheet>(this, f); 24688 Iterable<StyleSheet> where(bool f(StyleSheet element)) => IterableMixinWorkaro und.where(this, f);
24719 24689
24720 bool every(bool f(StyleSheet element)) => Collections.every(this, f); 24690 bool every(bool f(StyleSheet element)) => IterableMixinWorkaround.every(this, f);
24721 24691
24722 bool any(bool f(StyleSheet element)) => Collections.any(this, f); 24692 bool any(bool f(StyleSheet element)) => IterableMixinWorkaround.any(this, f);
24723 24693
24724 List<StyleSheet> toList() => new List<StyleSheet>.from(this); 24694 List<StyleSheet> toList() => new List<StyleSheet>.from(this);
24725 Set<StyleSheet> toSet() => new Set<StyleSheet>.from(this); 24695 Set<StyleSheet> toSet() => new Set<StyleSheet>.from(this);
24726 24696
24727 bool get isEmpty => this.length == 0; 24697 bool get isEmpty => this.length == 0;
24728 24698
24729 List<StyleSheet> take(int n) => new ListView<StyleSheet>(this, 0, n); 24699 List<StyleSheet> take(int n) => IterableMixinWorkaround.takeList(this, n);
24730 24700
24731 Iterable<StyleSheet> takeWhile(bool test(StyleSheet value)) { 24701 Iterable<StyleSheet> takeWhile(bool test(StyleSheet value)) {
24732 return new TakeWhileIterable<StyleSheet>(this, test); 24702 return IterableMixinWorkaround.takeWhile(this, test);
24733 } 24703 }
24734 24704
24735 List<StyleSheet> skip(int n) => new ListView<StyleSheet>(this, n, null); 24705 List<StyleSheet> skip(int n) => IterableMixinWorkaround.skipList(this, n);
24736 24706
24737 Iterable<StyleSheet> skipWhile(bool test(StyleSheet value)) { 24707 Iterable<StyleSheet> skipWhile(bool test(StyleSheet value)) {
24738 return new SkipWhileIterable<StyleSheet>(this, test); 24708 return IterableMixinWorkaround.skipWhile(this, test);
24739 } 24709 }
24740 24710
24741 StyleSheet firstMatching(bool test(StyleSheet value), { StyleSheet orElse() }) { 24711 StyleSheet firstMatching(bool test(StyleSheet value), { StyleSheet orElse() }) {
24742 return Collections.firstMatching(this, test, orElse); 24712 return IterableMixinWorkaround.firstMatching(this, test, orElse);
24743 } 24713 }
24744 24714
24745 StyleSheet lastMatching(bool test(StyleSheet value), {StyleSheet orElse()}) { 24715 StyleSheet lastMatching(bool test(StyleSheet value), {StyleSheet orElse()}) {
24746 return Collections.lastMatchingInList(this, test, orElse); 24716 return IterableMixinWorkaround.lastMatchingInList(this, test, orElse);
24747 } 24717 }
24748 24718
24749 StyleSheet singleMatching(bool test(StyleSheet value)) { 24719 StyleSheet singleMatching(bool test(StyleSheet value)) {
24750 return Collections.singleMatching(this, test); 24720 return IterableMixinWorkaround.singleMatching(this, test);
24751 } 24721 }
24752 24722
24753 StyleSheet elementAt(int index) { 24723 StyleSheet elementAt(int index) {
24754 return this[index]; 24724 return this[index];
24755 } 24725 }
24756 24726
24757 // From Collection<StyleSheet>: 24727 // From Collection<StyleSheet>:
24758 24728
24759 void add(StyleSheet value) { 24729 void add(StyleSheet value) {
24760 throw new UnsupportedError("Cannot add to immutable List."); 24730 throw new UnsupportedError("Cannot add to immutable List.");
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
24798 if (this.length > 0) return this[this.length - 1]; 24768 if (this.length > 0) return this[this.length - 1];
24799 throw new StateError("No elements"); 24769 throw new StateError("No elements");
24800 } 24770 }
24801 24771
24802 StyleSheet get single { 24772 StyleSheet get single {
24803 if (length == 1) return this[0]; 24773 if (length == 1) return this[0];
24804 if (length == 0) throw new StateError("No elements"); 24774 if (length == 0) throw new StateError("No elements");
24805 throw new StateError("More than one element"); 24775 throw new StateError("More than one element");
24806 } 24776 }
24807 24777
24808 StyleSheet min([int compare(StyleSheet a, StyleSheet b)]) => Collections.min(t his, compare); 24778 StyleSheet min([int compare(StyleSheet a, StyleSheet b)]) => IterableMixinWork around.min(this, compare);
24809 24779
24810 StyleSheet max([int compare(StyleSheet a, StyleSheet b)]) => Collections.max(t his, compare); 24780 StyleSheet max([int compare(StyleSheet a, StyleSheet b)]) => IterableMixinWork around.max(this, compare);
24811 24781
24812 StyleSheet removeAt(int pos) { 24782 StyleSheet removeAt(int pos) {
24813 throw new UnsupportedError("Cannot removeAt on immutable List."); 24783 throw new UnsupportedError("Cannot removeAt on immutable List.");
24814 } 24784 }
24815 24785
24816 StyleSheet removeLast() { 24786 StyleSheet removeLast() {
24817 throw new UnsupportedError("Cannot removeLast on immutable List."); 24787 throw new UnsupportedError("Cannot removeLast on immutable List.");
24818 } 24788 }
24819 24789
24820 void setRange(int start, int rangeLength, List<StyleSheet> from, [int startFro m]) { 24790 void setRange(int start, int rangeLength, List<StyleSheet> from, [int startFro m]) {
(...skipping 3243 matching lines...) Expand 10 before | Expand all | Expand 10 after
28064 _position = nextPosition; 28034 _position = nextPosition;
28065 return true; 28035 return true;
28066 } 28036 }
28067 _current = null; 28037 _current = null;
28068 _position = _array.length; 28038 _position = _array.length;
28069 return false; 28039 return false;
28070 } 28040 }
28071 28041
28072 T get current => _current; 28042 T get current => _current;
28073 } 28043 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698