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 library dart.uri; | 5 #library('dart:uri'); |
6 | 6 |
7 import 'dart:math'; | 7 #import('dart:math'); |
8 import 'dart:utf'; | 8 #import('dart:utf'); |
9 | 9 |
10 part 'encode_decode.dart'; | 10 #source('encode_decode.dart'); |
11 part 'helpers.dart'; | 11 #source('helpers.dart'); |
12 | 12 |
13 /** | 13 /** |
14 * A parsed URI, inspired by Closure's [URI][] class. Implements [RFC-3986][]. | 14 * A parsed URI, inspired by Closure's [URI][] class. Implements [RFC-3986][]. |
15 * [uri]: http://closure-library.googlecode.com/svn/docs/class_goog_Uri.html | 15 * [uri]: http://closure-library.googlecode.com/svn/docs/class_goog_Uri.html |
16 * [RFC-3986]: http://tools.ietf.org/html/rfc3986#section-4.3) | 16 * [RFC-3986]: http://tools.ietf.org/html/rfc3986#section-4.3) |
17 */ | 17 */ |
18 class Uri { | 18 class Uri { |
19 final String scheme; | 19 final String scheme; |
20 final String userInfo; | 20 final String userInfo; |
21 final String domain; | 21 final String domain; |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
230 } | 230 } |
231 | 231 |
232 static void _addIfNonEmpty(StringBuffer sb, String test, | 232 static void _addIfNonEmpty(StringBuffer sb, String test, |
233 String first, String second) { | 233 String first, String second) { |
234 if ("" != test) { | 234 if ("" != test) { |
235 sb.add(first == null ? "null" : first); | 235 sb.add(first == null ? "null" : first); |
236 sb.add(second == null ? "null" : second); | 236 sb.add(second == null ? "null" : second); |
237 } | 237 } |
238 } | 238 } |
239 } | 239 } |
OLD | NEW |