platform/packages/body_parser/lib/src/body_parse_result.dart
Tobe O a13d02069e Add 'packages/body_parser/' from commit 'b4cc359637f6bc510097e97c92f17db072e6e09b'
git-subtree-dir: packages/body_parser
git-subtree-mainline: 9c36a7e981
git-subtree-split: b4cc359637
2020-02-15 18:22:28 -05:00

28 lines
778 B
Dart

import 'file_upload_info.dart';
/// A representation of data from an incoming request.
abstract class BodyParseResult {
/// The parsed body.
Map<String, dynamic> get body;
/// The parsed query string.
Map<String, dynamic> get query;
/// All files uploaded within this request.
List<FileUploadInfo> get files;
/// The original body bytes sent with this request.
///
/// You must set [storeOriginalBuffer] to `true` to see this.
List<int> get originalBuffer;
/// 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;
}