| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 part of dart.collection; | 5 part of dart.collection; |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * A hash-table based implementation of [Map]. | 8 * A hash-table based implementation of [Map]. |
| 9 * | 9 * |
| 10 * The insertion order of keys is remembered, | 10 * The insertion order of keys is remembered, |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 * If [keys] contains the same object multiple times, the last occurrence | 129 * If [keys] contains the same object multiple times, the last occurrence |
| 130 * overwrites the previous value. | 130 * overwrites the previous value. |
| 131 * | 131 * |
| 132 * It is an error if the two [Iterable]s don't have the same length. | 132 * It is an error if the two [Iterable]s don't have the same length. |
| 133 */ | 133 */ |
| 134 factory LinkedHashMap.fromIterables(Iterable<K> keys, Iterable<V> values) { | 134 factory LinkedHashMap.fromIterables(Iterable<K> keys, Iterable<V> values) { |
| 135 LinkedHashMap<K, V> map = new LinkedHashMap<K, V>(); | 135 LinkedHashMap<K, V> map = new LinkedHashMap<K, V>(); |
| 136 Maps._fillMapWithIterables(map, keys, values); | 136 Maps._fillMapWithIterables(map, keys, values); |
| 137 return map; | 137 return map; |
| 138 } | 138 } |
| 139 |
| 140 @NoInline() |
| 141 factory LinkedHashMap._literal(List keyValuePairs) { |
| 142 return fillLiteralMap(keyValuePairs, new _LinkedHashMap<K, V>()); |
| 143 } |
| 144 |
| 145 @NoThrows() @NoInline() |
| 146 factory LinkedHashMap._empty() { |
| 147 return new _LinkedHashMap<K, V>(); |
| 148 } |
| 139 } | 149 } |
| OLD | NEW |