Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(772)

Side by Side Diff: lib/src/io.dart

Issue 1580273002: Get rid of all the library tags. (Closed) Base URL: git@github.com:dart-lang/http@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « lib/src/exception.dart ('k') | lib/src/io_client.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 http.io;
6
7 @MirrorsUsed(targets: const ['dart.io.HttpClient', 'dart.io.HttpException', 5 @MirrorsUsed(targets: const ['dart.io.HttpClient', 'dart.io.HttpException',
8 'dart.io.File']) 6 'dart.io.File'])
9 import 'dart:mirrors'; 7 import 'dart:mirrors';
10 8
11 /// Whether `dart:io` is supported on this platform. 9 /// Whether `dart:io` is supported on this platform.
12 bool get supported => _library != null; 10 bool get supported => _library != null;
13 11
14 /// The `dart:io` library mirror, or `null` if it couldn't be loaded. 12 /// The `dart:io` library mirror, or `null` if it couldn't be loaded.
15 final _library = _getLibrary(); 13 final _library = _getLibrary();
16 14
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 46
49 /// Tries to load `dart:io` and returns `null` if it fails. 47 /// Tries to load `dart:io` and returns `null` if it fails.
50 LibraryMirror _getLibrary() { 48 LibraryMirror _getLibrary() {
51 try { 49 try {
52 return currentMirrorSystem().findLibrary(const Symbol('dart.io')); 50 return currentMirrorSystem().findLibrary(const Symbol('dart.io'));
53 } catch (_) { 51 } catch (_) {
54 // TODO(nweiz): narrow the catch clause when issue 18532 is fixed. 52 // TODO(nweiz): narrow the catch clause when issue 18532 is fixed.
55 return null; 53 return null;
56 } 54 }
57 } 55 }
OLDNEW
« no previous file with comments | « lib/src/exception.dart ('k') | lib/src/io_client.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698