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

Side by Side Diff: sdk/lib/io/http_impl.dart

Issue 300113005: Untype 'Socket' a few places, where we try to call a hidden function. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | sdk/lib/io/websocket_impl.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) 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 int _OUTGOING_BUFFER_SIZE = 8 * 1024; 7 const int _OUTGOING_BUFFER_SIZE = 8 * 1024;
8 8
9 class _HttpIncoming extends Stream<List<int>> { 9 class _HttpIncoming extends Stream<List<int>> {
10 final int _transferLength; 10 final int _transferLength;
(...skipping 2383 matching lines...) Expand 10 before | Expand all | Expand 10 after
2394 ..remotePort = socket.remotePort 2394 ..remotePort = socket.remotePort
2395 ..localPort = socket.port; 2395 ..localPort = socket.port;
2396 } catch (e) { } 2396 } catch (e) { }
2397 return null; 2397 return null;
2398 } 2398 }
2399 } 2399 }
2400 2400
2401 2401
2402 class _DetachedSocket extends Stream<List<int>> implements Socket { 2402 class _DetachedSocket extends Stream<List<int>> implements Socket {
2403 final Stream<List<int>> _incoming; 2403 final Stream<List<int>> _incoming;
2404 final Socket _socket; 2404 final _socket;
2405 2405
2406 _DetachedSocket(this._socket, this._incoming); 2406 _DetachedSocket(this._socket, this._incoming);
2407 2407
2408 StreamSubscription<List<int>> listen(void onData(List<int> event), 2408 StreamSubscription<List<int>> listen(void onData(List<int> event),
2409 {Function onError, 2409 {Function onError,
2410 void onDone(), 2410 void onDone(),
2411 bool cancelOnError}) { 2411 bool cancelOnError}) {
2412 return _incoming.listen(onData, 2412 return _incoming.listen(onData,
2413 onError: onError, 2413 onError: onError,
2414 onDone: onDone, 2414 onDone: onDone,
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
2702 const _RedirectInfo(this.statusCode, this.method, this.location); 2702 const _RedirectInfo(this.statusCode, this.method, this.location);
2703 } 2703 }
2704 2704
2705 String _getHttpVersion() { 2705 String _getHttpVersion() {
2706 var version = Platform.version; 2706 var version = Platform.version;
2707 // Only include major and minor version numbers. 2707 // Only include major and minor version numbers.
2708 int index = version.indexOf('.', version.indexOf('.') + 1); 2708 int index = version.indexOf('.', version.indexOf('.') + 1);
2709 version = version.substring(0, index); 2709 version = version.substring(0, index);
2710 return 'Dart/$version (dart:io)'; 2710 return 'Dart/$version (dart:io)';
2711 } 2711 }
OLDNEW
« no previous file with comments | « no previous file | sdk/lib/io/websocket_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698