2016-09-24 18:30:01 +00:00
|
|
|
import 'file_upload_info.dart';
|
|
|
|
|
|
|
|
/// A representation of data from an incoming request.
|
2017-01-14 13:50:02 +00:00
|
|
|
abstract class BodyParseResult {
|
2016-09-24 18:30:01 +00:00
|
|
|
/// The parsed body.
|
2017-01-14 13:50:02 +00:00
|
|
|
Map<String, dynamic> get body;
|
2016-09-24 18:30:01 +00:00
|
|
|
|
|
|
|
/// The parsed query string.
|
2017-01-14 13:50:02 +00:00
|
|
|
Map<String, dynamic> get query;
|
2016-09-24 18:30:01 +00:00
|
|
|
|
|
|
|
/// All files uploaded within this request.
|
2017-01-14 13:50:02 +00:00
|
|
|
List<FileUploadInfo> get files;
|
|
|
|
|
|
|
|
/// The original body bytes sent with this request.
|
2018-08-11 02:08:44 +00:00
|
|
|
///
|
2017-01-14 13:50:02 +00:00
|
|
|
/// You must set [storeOriginalBuffer] to `true` to see this.
|
|
|
|
List<int> get originalBuffer;
|
2017-07-19 21:20:57 +00:00
|
|
|
|
|
|
|
/// If an error was encountered while parsing the body, it will appear here.
|
|
|
|
///
|
|
|
|
/// Otherwise, this is `null`.
|
|
|
|
dynamic get error;
|
|
|
|
|
|
|
|
/// If an error was encountered while parsing the body, the call stack will appear here.
|
|
|
|
///
|
|
|
|
/// Otherwise, this is `null`.
|
|
|
|
StackTrace get stack;
|
2016-09-24 18:30:01 +00:00
|
|
|
}
|