OLD | NEW |
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 library crypto.base64.deecoder; | |
6 | |
7 import 'dart:convert'; | 5 import 'dart:convert'; |
8 import 'dart:typed_data'; | 6 import 'dart:typed_data'; |
9 | 7 |
10 import 'package:charcode/ascii.dart'; | 8 import 'package:charcode/ascii.dart'; |
11 | 9 |
12 import 'decoder_sink.dart'; | 10 import 'decoder_sink.dart'; |
13 | 11 |
14 /// A mapping from ASCII character codes to their corresponding Base64 values. | 12 /// A mapping from ASCII character codes to their corresponding Base64 values. |
15 /// | 13 /// |
16 /// Characters with a value of `null` can't be decoded directly. This includes | 14 /// Characters with a value of `null` can't be decoded directly. This includes |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 } | 118 } |
121 | 119 |
122 return out; | 120 return out; |
123 } | 121 } |
124 | 122 |
125 Base64DecoderSink startChunkedConversion(Sink<List<int>> sink) { | 123 Base64DecoderSink startChunkedConversion(Sink<List<int>> sink) { |
126 if (sink is! ByteConversionSink) sink = new ByteConversionSink.from(sink); | 124 if (sink is! ByteConversionSink) sink = new ByteConversionSink.from(sink); |
127 return new Base64DecoderSink(sink); | 125 return new Base64DecoderSink(sink); |
128 } | 126 } |
129 } | 127 } |
OLD | NEW |