| 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 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 2206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2217 .then((socket) { | 2217 .then((socket) { |
| 2218 return new _HttpServer._(socket, true); | 2218 return new _HttpServer._(socket, true); |
| 2219 }); | 2219 }); |
| 2220 } | 2220 } |
| 2221 | 2221 |
| 2222 static Future<HttpServer> bindSecure(address, | 2222 static Future<HttpServer> bindSecure(address, |
| 2223 int port, | 2223 int port, |
| 2224 SecurityContext context, | 2224 SecurityContext context, |
| 2225 int backlog, | 2225 int backlog, |
| 2226 bool v6Only, | 2226 bool v6Only, |
| 2227 String certificate_name, | |
| 2228 bool requestClientCertificate, | 2227 bool requestClientCertificate, |
| 2229 bool shared) { | 2228 bool shared) { |
| 2230 return SecureServerSocket.bind( | 2229 return SecureServerSocket.bind( |
| 2231 address, | 2230 address, |
| 2232 port, | 2231 port, |
| 2233 context, | 2232 context, |
| 2234 backlog: backlog, | 2233 backlog: backlog, |
| 2235 v6Only: v6Only, | 2234 v6Only: v6Only, |
| 2236 requestClientCertificate: requestClientCertificate, | 2235 requestClientCertificate: requestClientCertificate, |
| 2237 shared: shared) | 2236 shared: shared) |
| (...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2863 const _RedirectInfo(this.statusCode, this.method, this.location); | 2862 const _RedirectInfo(this.statusCode, this.method, this.location); |
| 2864 } | 2863 } |
| 2865 | 2864 |
| 2866 String _getHttpVersion() { | 2865 String _getHttpVersion() { |
| 2867 var version = Platform.version; | 2866 var version = Platform.version; |
| 2868 // Only include major and minor version numbers. | 2867 // Only include major and minor version numbers. |
| 2869 int index = version.indexOf('.', version.indexOf('.') + 1); | 2868 int index = version.indexOf('.', version.indexOf('.') + 1); |
| 2870 version = version.substring(0, index); | 2869 version = version.substring(0, index); |
| 2871 return 'Dart/$version (dart:io)'; | 2870 return 'Dart/$version (dart:io)'; |
| 2872 } | 2871 } |
| OLD | NEW |