| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 | 5 |
| 6 // TODO(srdjan): Use shared array implementation. | 6 // TODO(srdjan): Use shared array implementation. |
| 7 class _ObjectArray<E> implements List<E> { | 7 class _ObjectArray<E> implements List<E> { |
| 8 | 8 |
| 9 factory _ObjectArray(int length) native "ObjectArray_allocate"; | 9 factory _ObjectArray(length) native "ObjectArray_allocate"; |
| 10 | 10 |
| 11 E operator [](int index) native "ObjectArray_getIndexed"; | 11 E operator [](int index) native "ObjectArray_getIndexed"; |
| 12 | 12 |
| 13 void operator []=(int index, E value) native "ObjectArray_setIndexed"; | 13 void operator []=(int index, E value) native "ObjectArray_setIndexed"; |
| 14 | 14 |
| 15 String toString() { | 15 String toString() { |
| 16 return Collections.collectionToString(this); | 16 return Collections.collectionToString(this); |
| 17 } | 17 } |
| 18 | 18 |
| 19 int get length native "ObjectArray_getLength"; | 19 int get length native "ObjectArray_getLength"; |
| (...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 498 } | 498 } |
| 499 _position = _length; | 499 _position = _length; |
| 500 _current = null; | 500 _current = null; |
| 501 return false; | 501 return false; |
| 502 } | 502 } |
| 503 | 503 |
| 504 E get current { | 504 E get current { |
| 505 return _current; | 505 return _current; |
| 506 } | 506 } |
| 507 } | 507 } |
| OLD | NEW |