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

Unified Diff: pkg/http_server/lib/src/http_body_impl.dart

Issue 756493002: pkg/http_server: move to multi-lib layout (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: readme fixup Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/http_server/lib/src/http_body.dart ('k') | pkg/http_server/lib/src/http_multi_server.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/http_server/lib/src/http_body_impl.dart
diff --git a/pkg/http_server/lib/src/http_body_impl.dart b/pkg/http_server/lib/src/http_body_impl.dart
index 7682902985018ee15e4f26a76eed74123ab0a5f7..b6c43c9727a9b20850ba90507787e797721aae80 100644
--- a/pkg/http_server/lib/src/http_body_impl.dart
+++ b/pkg/http_server/lib/src/http_body_impl.dart
@@ -2,13 +2,22 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-part of http_server;
+library http_server.http_body_impl;
-class _HttpBodyHandlerTransformer
+import 'dart:async';
+import 'dart:convert';
+import 'dart:io';
+
+import 'package:mime/mime.dart';
+
+import 'http_body.dart';
+import 'http_multipart_form_data.dart';
+
+class HttpBodyHandlerTransformer
implements StreamTransformer<HttpRequest, HttpRequestBody> {
final Encoding _defaultEncoding;
- const _HttpBodyHandlerTransformer(this._defaultEncoding);
+ const HttpBodyHandlerTransformer(this._defaultEncoding);
Stream<HttpRequestBody> bind(Stream<HttpRequest> stream) {
return new Stream<HttpRequestBody>.eventTransformed(
@@ -28,7 +37,7 @@ class _HttpBodyHandlerTransformerSink implements EventSink<HttpRequest> {
void add(HttpRequest request) {
_pending++;
- _HttpBodyHandler.processRequest(request, _defaultEncoding)
+ HttpBodyHandlerImpl.processRequest(request, _defaultEncoding)
.then(_outSink.add, onError: _outSink.addError)
.whenComplete(() {
_pending--;
@@ -44,7 +53,7 @@ class _HttpBodyHandlerTransformerSink implements EventSink<HttpRequest> {
}
}
-class _HttpBodyHandler {
+class HttpBodyHandlerImpl {
static Future<HttpRequestBody> processRequest(
HttpRequest request,
Encoding defaultEncoding) {
« no previous file with comments | « pkg/http_server/lib/src/http_body.dart ('k') | pkg/http_server/lib/src/http_multi_server.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698