| 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.io; | 5 part of dart.io; |
| 6 | 6 |
| 7 const SYSTEM_ENCODING = const SystemEncoding(); | 7 const SystemEncoding SYSTEM_ENCODING = const SystemEncoding(); |
| 8 | 8 |
| 9 /** | 9 /** |
| 10 * The system encoding is the current code page on Windows and UTF-8 on | 10 * The system encoding is the current code page on Windows and UTF-8 on |
| 11 * Linux and Mac. | 11 * Linux and Mac. |
| 12 */ | 12 */ |
| 13 class SystemEncoding extends Encoding { | 13 class SystemEncoding extends Encoding { |
| 14 const SystemEncoding(); | 14 const SystemEncoding(); |
| 15 | 15 |
| 16 String get name => 'system'; | 16 String get name => 'system'; |
| 17 | 17 |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 _WindowsCodePageDecoderSink(this._sink); | 122 _WindowsCodePageDecoderSink(this._sink); |
| 123 | 123 |
| 124 void close() { | 124 void close() { |
| 125 _sink.close(); | 125 _sink.close(); |
| 126 } | 126 } |
| 127 | 127 |
| 128 void add(List<int> bytes) { | 128 void add(List<int> bytes) { |
| 129 _sink.add(_WindowsCodePageDecoder._decodeBytes(bytes)); | 129 _sink.add(_WindowsCodePageDecoder._decodeBytes(bytes)); |
| 130 } | 130 } |
| 131 } | 131 } |
| OLD | NEW |