DioRestorableChunkedFileHandler constructor
const
DioRestorableChunkedFileHandler({
- required Dio client,
- required XFile file,
- required String presentPath,
- required ChunkPathCallback chunkPath,
- required StatusPathCallback statusPath,
- required PresentParser<
Response> presentParser, - required StatusParser<
Response> statusParser, - String presentMethod = kPresentMethod,
- String chunkMethod = kChunkMethod,
- String statusMethod = kStatusMethod,
- Map<
String, String> ? presentHeaders, - RestorableChunkHeadersCallback? chunkHeaders,
- StatusHeadersCallback? statusHeaders,
- String? presentBody,
- String? chunkBody,
- String? statusBody,
- int? chunkSize,
- String fileKey = kFileKey,
- ChunkParser<
Response> chunkParser = kChunkParser, - PresentHeadersCallback? presentHeadersCallback,
- CancelToken? cancelToken,
client used to upload the file
set chunkSize to choose the size of the chunks else
defaultChunkSize is used
Implementation
const DioRestorableChunkedFileHandler({
required dio.Dio client,
required super.file,
required super.presentPath,
required super.chunkPath,
required super.statusPath,
required super.presentParser,
required super.statusParser,
super.presentMethod,
super.chunkMethod,
super.statusMethod,
super.presentHeaders,
super.chunkHeaders,
super.statusHeaders,
super.presentBody,
super.chunkBody,
super.statusBody,
super.chunkSize,
super.fileKey,
super.chunkParser,
super.presentHeadersCallback,
this.cancelToken,
}) : _client = client;