createAriaTaskOption method

  1. @override
Future<TaskOptions> createAriaTaskOption({
  1. List<String>? header,
  2. String? allProxy,
  3. int? split,
  4. String? dir,
  5. String? out,
  6. String? gid,
  7. bool? rContinue,
  8. bool? autoFileRenaming,
  9. bool? checkIntegrity,
  10. String? lowestSpeedLimit,
  11. String? maxDownloadLimit,
  12. int? maxTries,
  13. int? maxConnectionPerServer,
  14. int? timeout,
  15. required Map<String, String> extraOptions,
  16. dynamic hint,
})
override

Implementation

@override
Future<TaskOptions> createAriaTaskOption(
    {List<String>? header,
    String? allProxy,
    int? split,
    String? dir,
    String? out,
    String? gid,
    bool? rContinue,
    bool? autoFileRenaming,
    bool? checkIntegrity,
    String? lowestSpeedLimit,
    String? maxDownloadLimit,
    int? maxTries,
    int? maxConnectionPerServer,
    int? timeout,
    required Map<String, String> extraOptions,
    dynamic hint}) {
  return handler.executeNormal(NormalTask(
    callFfi: (port_) {
      final serializer = SseSerializer(generalizedFrbRustBinding);
      sse_encode_opt_list_String(header, serializer);
      sse_encode_opt_String(allProxy, serializer);
      sse_encode_opt_box_autoadd_i_32(split, serializer);
      sse_encode_opt_String(dir, serializer);
      sse_encode_opt_String(out, serializer);
      sse_encode_opt_String(gid, serializer);
      sse_encode_opt_box_autoadd_bool(rContinue, serializer);
      sse_encode_opt_box_autoadd_bool(autoFileRenaming, serializer);
      sse_encode_opt_box_autoadd_bool(checkIntegrity, serializer);
      sse_encode_opt_String(lowestSpeedLimit, serializer);
      sse_encode_opt_String(maxDownloadLimit, serializer);
      sse_encode_opt_box_autoadd_i_32(maxTries, serializer);
      sse_encode_opt_box_autoadd_i_32(maxConnectionPerServer, serializer);
      sse_encode_opt_box_autoadd_i_32(timeout, serializer);
      sse_encode_Map_String_String(extraOptions, serializer);
      pdeCallFfi(generalizedFrbRustBinding, serializer,
          funcId: 2, port: port_);
    },
    codec: SseCodec(
      decodeSuccessData:
          sse_decode_Auto_Owned_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockTaskOptions,
      decodeErrorData: null,
    ),
    constMeta: kCreateAriaTaskOptionConstMeta,
    argValues: [
      header,
      allProxy,
      split,
      dir,
      out,
      gid,
      rContinue,
      autoFileRenaming,
      checkIntegrity,
      lowestSpeedLimit,
      maxDownloadLimit,
      maxTries,
      maxConnectionPerServer,
      timeout,
      extraOptions
    ],
    apiImpl: this,
    hint: hint,
  ));
}