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 mock_client; | |
6 | |
7 import 'dart:async'; | 5 import 'dart:async'; |
8 | 6 |
9 import 'base_client.dart'; | 7 import 'base_client.dart'; |
10 import 'base_request.dart'; | 8 import 'base_request.dart'; |
11 import 'byte_stream.dart'; | 9 import 'byte_stream.dart'; |
12 import 'request.dart'; | 10 import 'request.dart'; |
13 import 'response.dart'; | 11 import 'response.dart'; |
14 import 'streamed_response.dart'; | 12 import 'streamed_response.dart'; |
15 import 'utils.dart'; | 13 import 'utils.dart'; |
16 | 14 |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 } | 78 } |
81 | 79 |
82 /// A handler function that receives [StreamedRequest]s and sends | 80 /// A handler function that receives [StreamedRequest]s and sends |
83 /// [StreamedResponse]s. Note that [request] will be finalized. | 81 /// [StreamedResponse]s. Note that [request] will be finalized. |
84 typedef Future<StreamedResponse> MockClientStreamHandler( | 82 typedef Future<StreamedResponse> MockClientStreamHandler( |
85 BaseRequest request, ByteStream bodyStream); | 83 BaseRequest request, ByteStream bodyStream); |
86 | 84 |
87 /// A handler function that receives [Request]s and sends [Response]s. Note that | 85 /// A handler function that receives [Request]s and sends [Response]s. Note that |
88 /// [request] will be finalized. | 86 /// [request] will be finalized. |
89 typedef Future<Response> MockClientHandler(Request request); | 87 typedef Future<Response> MockClientHandler(Request request); |
OLD | NEW |