@onekeyfe/react-native-range-downloader 3.0.86 → 3.0.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/nitrogen/generated/android/c++/JDownloadChannel.hpp +1 -1
  2. package/nitrogen/generated/android/c++/JFirmwareArchiveExpectedEntry.hpp +1 -1
  3. package/nitrogen/generated/android/c++/JFirmwareArchiveMaterializeParams.hpp +9 -9
  4. package/nitrogen/generated/android/c++/JFirmwareArchiveMaterializeResult.hpp +9 -9
  5. package/nitrogen/generated/android/c++/JFirmwareArchiveMaterializedArtifact.hpp +1 -1
  6. package/nitrogen/generated/android/c++/JFirmwareArtifactCancelParams.hpp +1 -1
  7. package/nitrogen/generated/android/c++/JFirmwareArtifactCapabilities.hpp +9 -9
  8. package/nitrogen/generated/android/c++/JFirmwareArtifactDownloadParams.hpp +1 -1
  9. package/nitrogen/generated/android/c++/JFirmwareArtifactLease.hpp +1 -1
  10. package/nitrogen/generated/android/c++/JFirmwareArtifactLeaseCreateParams.hpp +1 -1
  11. package/nitrogen/generated/android/c++/JFirmwareArtifactLeaseReleaseParams.hpp +1 -1
  12. package/nitrogen/generated/android/c++/JFirmwareArtifactLeaseRetainParams.hpp +1 -1
  13. package/nitrogen/generated/android/c++/JFirmwareArtifactReaderCloseParams.hpp +1 -1
  14. package/nitrogen/generated/android/c++/JFirmwareArtifactReaderInfo.hpp +1 -1
  15. package/nitrogen/generated/android/c++/JFirmwareArtifactReaderReadParams.hpp +1 -1
  16. package/nitrogen/generated/android/c++/JFirmwareArtifactReceipt.hpp +1 -1
  17. package/nitrogen/generated/android/c++/JFirmwareArtifactRefParams.hpp +1 -1
  18. package/nitrogen/generated/android/c++/JFirmwareArtifactSweepResult.hpp +1 -1
  19. package/nitrogen/generated/android/c++/JRangeDownloadEvent.hpp +1 -1
  20. package/nitrogen/generated/android/c++/JRangeDownloadOutcome.hpp +1 -1
  21. package/nitrogen/generated/android/c++/JRangeDownloadParams.hpp +1 -1
  22. package/nitrogen/generated/android/c++/JRangeDownloadResult.hpp +1 -1
  23. package/nitrogen/generated/android/c++/JRangeFallbackKind.hpp +1 -1
  24. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArchiveExpectedEntry.kt +19 -0
  25. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArchiveMaterializeParams.kt +17 -0
  26. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArchiveMaterializeResult.kt +13 -0
  27. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArchiveMaterializedArtifact.kt +15 -0
  28. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactCancelParams.kt +13 -0
  29. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactCapabilities.kt +19 -0
  30. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactDownloadParams.kt +33 -0
  31. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactLease.kt +13 -0
  32. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactLeaseCreateParams.kt +13 -0
  33. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactLeaseReleaseParams.kt +15 -0
  34. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactLeaseRetainParams.kt +15 -0
  35. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactReaderCloseParams.kt +13 -0
  36. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactReaderInfo.kt +15 -0
  37. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactReaderReadParams.kt +17 -0
  38. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactReceipt.kt +19 -0
  39. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactRefParams.kt +13 -0
  40. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/FirmwareArtifactSweepResult.kt +15 -0
  41. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/Func_void_RangeDownloadEvent.kt +0 -2
  42. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/HybridReactNativeRangeDownloaderSpec.kt +2 -0
  43. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/RangeDownloadEvent.kt +21 -0
  44. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/RangeDownloadParams.kt +33 -0
  45. package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativerangedownloader/RangeDownloadResult.kt +19 -0
  46. package/nitrogen/generated/ios/ReactNativeRangeDownloader+autolinking.rb +2 -0
  47. package/package.json +4 -4
@@ -15,7 +15,7 @@ namespace margelo::nitro::reactnativerangedownloader {
15
15
  using namespace facebook;
16
16
 
17
17
  /**
18
- * The C++ JNI bridge between the C++ enum "DownloadChannel" and the the Kotlin enum "DownloadChannel".
18
+ * The C++ JNI bridge between the C++ enum "DownloadChannel" and the Kotlin enum "DownloadChannel".
19
19
  */
20
20
  struct JDownloadChannel final: public jni::JavaClass<JDownloadChannel> {
21
21
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArchiveExpectedEntry" and the the Kotlin data class "FirmwareArchiveExpectedEntry".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArchiveExpectedEntry" and the Kotlin data class "FirmwareArchiveExpectedEntry".
21
21
  */
22
22
  struct JFirmwareArchiveExpectedEntry final: public jni::JavaClass<JFirmwareArchiveExpectedEntry> {
23
23
  public:
@@ -21,7 +21,7 @@ namespace margelo::nitro::reactnativerangedownloader {
21
21
  using namespace facebook;
22
22
 
23
23
  /**
24
- * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializeParams" and the the Kotlin data class "FirmwareArchiveMaterializeParams".
24
+ * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializeParams" and the Kotlin data class "FirmwareArchiveMaterializeParams".
25
25
  */
26
26
  struct JFirmwareArchiveMaterializeParams final: public jni::JavaClass<JFirmwareArchiveMaterializeParams> {
27
27
  public:
@@ -44,16 +44,16 @@ namespace margelo::nitro::reactnativerangedownloader {
44
44
  return FirmwareArchiveMaterializeParams(
45
45
  leaseRef->toStdString(),
46
46
  archiveArtifactRef->toStdString(),
47
- expectedEntries != nullptr ? std::make_optional([&]() {
48
- size_t __size = expectedEntries->size();
47
+ expectedEntries != nullptr ? std::make_optional([&](auto&& __input) {
48
+ size_t __size = __input->size();
49
49
  std::vector<FirmwareArchiveExpectedEntry> __vector;
50
50
  __vector.reserve(__size);
51
51
  for (size_t __i = 0; __i < __size; __i++) {
52
- auto __element = expectedEntries->getElement(__i);
52
+ auto __element = __input->getElement(__i);
53
53
  __vector.push_back(__element->toCpp());
54
54
  }
55
55
  return __vector;
56
- }()) : std::nullopt
56
+ }(expectedEntries)) : std::nullopt
57
57
  );
58
58
  }
59
59
 
@@ -70,16 +70,16 @@ namespace margelo::nitro::reactnativerangedownloader {
70
70
  clazz,
71
71
  jni::make_jstring(value.leaseRef),
72
72
  jni::make_jstring(value.archiveArtifactRef),
73
- value.expectedEntries.has_value() ? [&]() {
74
- size_t __size = value.expectedEntries.value().size();
73
+ value.expectedEntries.has_value() ? [&](auto&& __input) {
74
+ size_t __size = __input.size();
75
75
  jni::local_ref<jni::JArrayClass<JFirmwareArchiveExpectedEntry>> __array = jni::JArrayClass<JFirmwareArchiveExpectedEntry>::newArray(__size);
76
76
  for (size_t __i = 0; __i < __size; __i++) {
77
- const auto& __element = value.expectedEntries.value()[__i];
77
+ const auto& __element = __input[__i];
78
78
  auto __elementJni = JFirmwareArchiveExpectedEntry::fromCpp(__element);
79
79
  __array->setElement(__i, *__elementJni);
80
80
  }
81
81
  return __array;
82
- }() : nullptr
82
+ }(value.expectedEntries.value()) : nullptr
83
83
  );
84
84
  }
85
85
  };
@@ -22,7 +22,7 @@ namespace margelo::nitro::reactnativerangedownloader {
22
22
  using namespace facebook;
23
23
 
24
24
  /**
25
- * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializeResult" and the the Kotlin data class "FirmwareArchiveMaterializeResult".
25
+ * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializeResult" and the Kotlin data class "FirmwareArchiveMaterializeResult".
26
26
  */
27
27
  struct JFirmwareArchiveMaterializeResult final: public jni::JavaClass<JFirmwareArchiveMaterializeResult> {
28
28
  public:
@@ -39,16 +39,16 @@ namespace margelo::nitro::reactnativerangedownloader {
39
39
  static const auto fieldArtifacts = clazz->getField<jni::JArrayClass<JFirmwareArchiveMaterializedArtifact>>("artifacts");
40
40
  jni::local_ref<jni::JArrayClass<JFirmwareArchiveMaterializedArtifact>> artifacts = this->getFieldValue(fieldArtifacts);
41
41
  return FirmwareArchiveMaterializeResult(
42
- [&]() {
43
- size_t __size = artifacts->size();
42
+ [&](auto&& __input) {
43
+ size_t __size = __input->size();
44
44
  std::vector<FirmwareArchiveMaterializedArtifact> __vector;
45
45
  __vector.reserve(__size);
46
46
  for (size_t __i = 0; __i < __size; __i++) {
47
- auto __element = artifacts->getElement(__i);
47
+ auto __element = __input->getElement(__i);
48
48
  __vector.push_back(__element->toCpp());
49
49
  }
50
50
  return __vector;
51
- }()
51
+ }(artifacts)
52
52
  );
53
53
  }
54
54
 
@@ -63,16 +63,16 @@ namespace margelo::nitro::reactnativerangedownloader {
63
63
  static const auto create = clazz->getStaticMethod<JSignature>("fromCpp");
64
64
  return create(
65
65
  clazz,
66
- [&]() {
67
- size_t __size = value.artifacts.size();
66
+ [&](auto&& __input) {
67
+ size_t __size = __input.size();
68
68
  jni::local_ref<jni::JArrayClass<JFirmwareArchiveMaterializedArtifact>> __array = jni::JArrayClass<JFirmwareArchiveMaterializedArtifact>::newArray(__size);
69
69
  for (size_t __i = 0; __i < __size; __i++) {
70
- const auto& __element = value.artifacts[__i];
70
+ const auto& __element = __input[__i];
71
71
  auto __elementJni = JFirmwareArchiveMaterializedArtifact::fromCpp(__element);
72
72
  __array->setElement(__i, *__elementJni);
73
73
  }
74
74
  return __array;
75
- }()
75
+ }(value.artifacts)
76
76
  );
77
77
  }
78
78
  };
@@ -19,7 +19,7 @@ namespace margelo::nitro::reactnativerangedownloader {
19
19
  using namespace facebook;
20
20
 
21
21
  /**
22
- * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializedArtifact" and the the Kotlin data class "FirmwareArchiveMaterializedArtifact".
22
+ * The C++ JNI bridge between the C++ struct "FirmwareArchiveMaterializedArtifact" and the Kotlin data class "FirmwareArchiveMaterializedArtifact".
23
23
  */
24
24
  struct JFirmwareArchiveMaterializedArtifact final: public jni::JavaClass<JFirmwareArchiveMaterializedArtifact> {
25
25
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactCancelParams" and the the Kotlin data class "FirmwareArtifactCancelParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactCancelParams" and the Kotlin data class "FirmwareArtifactCancelParams".
21
21
  */
22
22
  struct JFirmwareArtifactCancelParams final: public jni::JavaClass<JFirmwareArtifactCancelParams> {
23
23
  public:
@@ -18,7 +18,7 @@ namespace margelo::nitro::reactnativerangedownloader {
18
18
  using namespace facebook;
19
19
 
20
20
  /**
21
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactCapabilities" and the the Kotlin data class "FirmwareArtifactCapabilities".
21
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactCapabilities" and the Kotlin data class "FirmwareArtifactCapabilities".
22
22
  */
23
23
  struct JFirmwareArtifactCapabilities final: public jni::JavaClass<JFirmwareArtifactCapabilities> {
24
24
  public:
@@ -42,16 +42,16 @@ namespace margelo::nitro::reactnativerangedownloader {
42
42
  double maxReadBytes = this->getFieldValue(fieldMaxReadBytes);
43
43
  return FirmwareArtifactCapabilities(
44
44
  firmwareArtifactProtocolVersion,
45
- [&]() {
46
- size_t __size = supportedRouteTypes->size();
45
+ [&](auto&& __input) {
46
+ size_t __size = __input->size();
47
47
  std::vector<std::string> __vector;
48
48
  __vector.reserve(__size);
49
49
  for (size_t __i = 0; __i < __size; __i++) {
50
- auto __element = supportedRouteTypes->getElement(__i);
50
+ auto __element = __input->getElement(__i);
51
51
  __vector.push_back(__element->toStdString());
52
52
  }
53
53
  return __vector;
54
- }(),
54
+ }(supportedRouteTypes),
55
55
  static_cast<bool>(supportsArchiveMaterialization),
56
56
  maxReadBytes
57
57
  );
@@ -69,16 +69,16 @@ namespace margelo::nitro::reactnativerangedownloader {
69
69
  return create(
70
70
  clazz,
71
71
  value.firmwareArtifactProtocolVersion,
72
- [&]() {
73
- size_t __size = value.supportedRouteTypes.size();
72
+ [&](auto&& __input) {
73
+ size_t __size = __input.size();
74
74
  jni::local_ref<jni::JArrayClass<jni::JString>> __array = jni::JArrayClass<jni::JString>::newArray(__size);
75
75
  for (size_t __i = 0; __i < __size; __i++) {
76
- const auto& __element = value.supportedRouteTypes[__i];
76
+ const auto& __element = __input[__i];
77
77
  auto __elementJni = jni::make_jstring(__element);
78
78
  __array->setElement(__i, *__elementJni);
79
79
  }
80
80
  return __array;
81
- }(),
81
+ }(value.supportedRouteTypes),
82
82
  value.supportsArchiveMaterialization,
83
83
  value.maxReadBytes
84
84
  );
@@ -18,7 +18,7 @@ namespace margelo::nitro::reactnativerangedownloader {
18
18
  using namespace facebook;
19
19
 
20
20
  /**
21
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactDownloadParams" and the the Kotlin data class "FirmwareArtifactDownloadParams".
21
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactDownloadParams" and the Kotlin data class "FirmwareArtifactDownloadParams".
22
22
  */
23
23
  struct JFirmwareArtifactDownloadParams final: public jni::JavaClass<JFirmwareArtifactDownloadParams> {
24
24
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactLease" and the the Kotlin data class "FirmwareArtifactLease".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactLease" and the Kotlin data class "FirmwareArtifactLease".
21
21
  */
22
22
  struct JFirmwareArtifactLease final: public jni::JavaClass<JFirmwareArtifactLease> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseCreateParams" and the the Kotlin data class "FirmwareArtifactLeaseCreateParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseCreateParams" and the Kotlin data class "FirmwareArtifactLeaseCreateParams".
21
21
  */
22
22
  struct JFirmwareArtifactLeaseCreateParams final: public jni::JavaClass<JFirmwareArtifactLeaseCreateParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseReleaseParams" and the the Kotlin data class "FirmwareArtifactLeaseReleaseParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseReleaseParams" and the Kotlin data class "FirmwareArtifactLeaseReleaseParams".
21
21
  */
22
22
  struct JFirmwareArtifactLeaseReleaseParams final: public jni::JavaClass<JFirmwareArtifactLeaseReleaseParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseRetainParams" and the the Kotlin data class "FirmwareArtifactLeaseRetainParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactLeaseRetainParams" and the Kotlin data class "FirmwareArtifactLeaseRetainParams".
21
21
  */
22
22
  struct JFirmwareArtifactLeaseRetainParams final: public jni::JavaClass<JFirmwareArtifactLeaseRetainParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderCloseParams" and the the Kotlin data class "FirmwareArtifactReaderCloseParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderCloseParams" and the Kotlin data class "FirmwareArtifactReaderCloseParams".
21
21
  */
22
22
  struct JFirmwareArtifactReaderCloseParams final: public jni::JavaClass<JFirmwareArtifactReaderCloseParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderInfo" and the the Kotlin data class "FirmwareArtifactReaderInfo".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderInfo" and the Kotlin data class "FirmwareArtifactReaderInfo".
21
21
  */
22
22
  struct JFirmwareArtifactReaderInfo final: public jni::JavaClass<JFirmwareArtifactReaderInfo> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderReadParams" and the the Kotlin data class "FirmwareArtifactReaderReadParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactReaderReadParams" and the Kotlin data class "FirmwareArtifactReaderReadParams".
21
21
  */
22
22
  struct JFirmwareArtifactReaderReadParams final: public jni::JavaClass<JFirmwareArtifactReaderReadParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactReceipt" and the the Kotlin data class "FirmwareArtifactReceipt".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactReceipt" and the Kotlin data class "FirmwareArtifactReceipt".
21
21
  */
22
22
  struct JFirmwareArtifactReceipt final: public jni::JavaClass<JFirmwareArtifactReceipt> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactRefParams" and the the Kotlin data class "FirmwareArtifactRefParams".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactRefParams" and the Kotlin data class "FirmwareArtifactRefParams".
21
21
  */
22
22
  struct JFirmwareArtifactRefParams final: public jni::JavaClass<JFirmwareArtifactRefParams> {
23
23
  public:
@@ -17,7 +17,7 @@ namespace margelo::nitro::reactnativerangedownloader {
17
17
  using namespace facebook;
18
18
 
19
19
  /**
20
- * The C++ JNI bridge between the C++ struct "FirmwareArtifactSweepResult" and the the Kotlin data class "FirmwareArtifactSweepResult".
20
+ * The C++ JNI bridge between the C++ struct "FirmwareArtifactSweepResult" and the Kotlin data class "FirmwareArtifactSweepResult".
21
21
  */
22
22
  struct JFirmwareArtifactSweepResult final: public jni::JavaClass<JFirmwareArtifactSweepResult> {
23
23
  public:
@@ -19,7 +19,7 @@ namespace margelo::nitro::reactnativerangedownloader {
19
19
  using namespace facebook;
20
20
 
21
21
  /**
22
- * The C++ JNI bridge between the C++ struct "RangeDownloadEvent" and the the Kotlin data class "RangeDownloadEvent".
22
+ * The C++ JNI bridge between the C++ struct "RangeDownloadEvent" and the Kotlin data class "RangeDownloadEvent".
23
23
  */
24
24
  struct JRangeDownloadEvent final: public jni::JavaClass<JRangeDownloadEvent> {
25
25
  public:
@@ -15,7 +15,7 @@ namespace margelo::nitro::reactnativerangedownloader {
15
15
  using namespace facebook;
16
16
 
17
17
  /**
18
- * The C++ JNI bridge between the C++ enum "RangeDownloadOutcome" and the the Kotlin enum "RangeDownloadOutcome".
18
+ * The C++ JNI bridge between the C++ enum "RangeDownloadOutcome" and the Kotlin enum "RangeDownloadOutcome".
19
19
  */
20
20
  struct JRangeDownloadOutcome final: public jni::JavaClass<JRangeDownloadOutcome> {
21
21
  public:
@@ -20,7 +20,7 @@ namespace margelo::nitro::reactnativerangedownloader {
20
20
  using namespace facebook;
21
21
 
22
22
  /**
23
- * The C++ JNI bridge between the C++ struct "RangeDownloadParams" and the the Kotlin data class "RangeDownloadParams".
23
+ * The C++ JNI bridge between the C++ struct "RangeDownloadParams" and the Kotlin data class "RangeDownloadParams".
24
24
  */
25
25
  struct JRangeDownloadParams final: public jni::JavaClass<JRangeDownloadParams> {
26
26
  public:
@@ -22,7 +22,7 @@ namespace margelo::nitro::reactnativerangedownloader {
22
22
  using namespace facebook;
23
23
 
24
24
  /**
25
- * The C++ JNI bridge between the C++ struct "RangeDownloadResult" and the the Kotlin data class "RangeDownloadResult".
25
+ * The C++ JNI bridge between the C++ struct "RangeDownloadResult" and the Kotlin data class "RangeDownloadResult".
26
26
  */
27
27
  struct JRangeDownloadResult final: public jni::JavaClass<JRangeDownloadResult> {
28
28
  public:
@@ -15,7 +15,7 @@ namespace margelo::nitro::reactnativerangedownloader {
15
15
  using namespace facebook;
16
16
 
17
17
  /**
18
- * The C++ JNI bridge between the C++ enum "RangeFallbackKind" and the the Kotlin enum "RangeFallbackKind".
18
+ * The C++ JNI bridge between the C++ enum "RangeFallbackKind" and the Kotlin enum "RangeFallbackKind".
19
19
  */
20
20
  struct JRangeFallbackKind final: public jni::JavaClass<JRangeFallbackKind> {
21
21
  public:
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -32,6 +33,24 @@ data class FirmwareArchiveExpectedEntry(
32
33
  ) {
33
34
  /* primary constructor */
34
35
 
36
+ override fun equals(other: Any?): Boolean {
37
+ if (this === other) return true
38
+ if (other !is FirmwareArchiveExpectedEntry) return false
39
+ return Objects.deepEquals(this.artifactId, other.artifactId)
40
+ && Objects.deepEquals(this.entryName, other.entryName)
41
+ && Objects.deepEquals(this.expectedSize, other.expectedSize)
42
+ && Objects.deepEquals(this.expectedSha256, other.expectedSha256)
43
+ }
44
+
45
+ override fun hashCode(): Int {
46
+ return arrayOf<Any?>(
47
+ artifactId,
48
+ entryName,
49
+ expectedSize,
50
+ expectedSha256
51
+ ).contentDeepHashCode()
52
+ }
53
+
35
54
  companion object {
36
55
  /**
37
56
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -29,6 +30,22 @@ data class FirmwareArchiveMaterializeParams(
29
30
  ) {
30
31
  /* primary constructor */
31
32
 
33
+ override fun equals(other: Any?): Boolean {
34
+ if (this === other) return true
35
+ if (other !is FirmwareArchiveMaterializeParams) return false
36
+ return Objects.deepEquals(this.leaseRef, other.leaseRef)
37
+ && Objects.deepEquals(this.archiveArtifactRef, other.archiveArtifactRef)
38
+ && Objects.deepEquals(this.expectedEntries, other.expectedEntries)
39
+ }
40
+
41
+ override fun hashCode(): Int {
42
+ return arrayOf<Any?>(
43
+ leaseRef,
44
+ archiveArtifactRef,
45
+ expectedEntries
46
+ ).contentDeepHashCode()
47
+ }
48
+
32
49
  companion object {
33
50
  /**
34
51
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArchiveMaterializeResult(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArchiveMaterializeResult) return false
30
+ return Objects.deepEquals(this.artifacts, other.artifacts)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ artifacts
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -26,6 +27,20 @@ data class FirmwareArchiveMaterializedArtifact(
26
27
  ) {
27
28
  /* primary constructor */
28
29
 
30
+ override fun equals(other: Any?): Boolean {
31
+ if (this === other) return true
32
+ if (other !is FirmwareArchiveMaterializedArtifact) return false
33
+ return Objects.deepEquals(this.entryName, other.entryName)
34
+ && Objects.deepEquals(this.receipt, other.receipt)
35
+ }
36
+
37
+ override fun hashCode(): Int {
38
+ return arrayOf<Any?>(
39
+ entryName,
40
+ receipt
41
+ ).contentDeepHashCode()
42
+ }
43
+
29
44
  companion object {
30
45
  /**
31
46
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArtifactCancelParams(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArtifactCancelParams) return false
30
+ return Objects.deepEquals(this.transactionId, other.transactionId)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ transactionId
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -32,6 +33,24 @@ data class FirmwareArtifactCapabilities(
32
33
  ) {
33
34
  /* primary constructor */
34
35
 
36
+ override fun equals(other: Any?): Boolean {
37
+ if (this === other) return true
38
+ if (other !is FirmwareArtifactCapabilities) return false
39
+ return Objects.deepEquals(this.firmwareArtifactProtocolVersion, other.firmwareArtifactProtocolVersion)
40
+ && Objects.deepEquals(this.supportedRouteTypes, other.supportedRouteTypes)
41
+ && Objects.deepEquals(this.supportsArchiveMaterialization, other.supportsArchiveMaterialization)
42
+ && Objects.deepEquals(this.maxReadBytes, other.maxReadBytes)
43
+ }
44
+
45
+ override fun hashCode(): Int {
46
+ return arrayOf<Any?>(
47
+ firmwareArtifactProtocolVersion,
48
+ supportedRouteTypes,
49
+ supportsArchiveMaterialization,
50
+ maxReadBytes
51
+ ).contentDeepHashCode()
52
+ }
53
+
35
54
  companion object {
36
55
  /**
37
56
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -53,6 +54,38 @@ data class FirmwareArtifactDownloadParams(
53
54
  ) {
54
55
  /* primary constructor */
55
56
 
57
+ override fun equals(other: Any?): Boolean {
58
+ if (this === other) return true
59
+ if (other !is FirmwareArtifactDownloadParams) return false
60
+ return Objects.deepEquals(this.taskId, other.taskId)
61
+ && Objects.deepEquals(this.transactionId, other.transactionId)
62
+ && Objects.deepEquals(this.leaseRef, other.leaseRef)
63
+ && Objects.deepEquals(this.artifactId, other.artifactId)
64
+ && Objects.deepEquals(this.url, other.url)
65
+ && Objects.deepEquals(this.routeType, other.routeType)
66
+ && Objects.deepEquals(this.resolvedIp, other.resolvedIp)
67
+ && Objects.deepEquals(this.expectedSize, other.expectedSize)
68
+ && Objects.deepEquals(this.expectedSha256, other.expectedSha256)
69
+ && Objects.deepEquals(this.maxBytes, other.maxBytes)
70
+ && Objects.deepEquals(this.overallDeadlineSeconds, other.overallDeadlineSeconds)
71
+ }
72
+
73
+ override fun hashCode(): Int {
74
+ return arrayOf<Any?>(
75
+ taskId,
76
+ transactionId,
77
+ leaseRef,
78
+ artifactId,
79
+ url,
80
+ routeType,
81
+ resolvedIp,
82
+ expectedSize,
83
+ expectedSha256,
84
+ maxBytes,
85
+ overallDeadlineSeconds
86
+ ).contentDeepHashCode()
87
+ }
88
+
56
89
  companion object {
57
90
  /**
58
91
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArtifactLease(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArtifactLease) return false
30
+ return Objects.deepEquals(this.leaseRef, other.leaseRef)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ leaseRef
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArtifactLeaseCreateParams(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArtifactLeaseCreateParams) return false
30
+ return Objects.deepEquals(this.transactionId, other.transactionId)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ transactionId
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -26,6 +27,20 @@ data class FirmwareArtifactLeaseReleaseParams(
26
27
  ) {
27
28
  /* primary constructor */
28
29
 
30
+ override fun equals(other: Any?): Boolean {
31
+ if (this === other) return true
32
+ if (other !is FirmwareArtifactLeaseReleaseParams) return false
33
+ return Objects.deepEquals(this.leaseRef, other.leaseRef)
34
+ && Objects.deepEquals(this.disposition, other.disposition)
35
+ }
36
+
37
+ override fun hashCode(): Int {
38
+ return arrayOf<Any?>(
39
+ leaseRef,
40
+ disposition
41
+ ).contentDeepHashCode()
42
+ }
43
+
29
44
  companion object {
30
45
  /**
31
46
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -26,6 +27,20 @@ data class FirmwareArtifactLeaseRetainParams(
26
27
  ) {
27
28
  /* primary constructor */
28
29
 
30
+ override fun equals(other: Any?): Boolean {
31
+ if (this === other) return true
32
+ if (other !is FirmwareArtifactLeaseRetainParams) return false
33
+ return Objects.deepEquals(this.leaseRef, other.leaseRef)
34
+ && Objects.deepEquals(this.artifactRef, other.artifactRef)
35
+ }
36
+
37
+ override fun hashCode(): Int {
38
+ return arrayOf<Any?>(
39
+ leaseRef,
40
+ artifactRef
41
+ ).contentDeepHashCode()
42
+ }
43
+
29
44
  companion object {
30
45
  /**
31
46
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArtifactReaderCloseParams(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArtifactReaderCloseParams) return false
30
+ return Objects.deepEquals(this.readerId, other.readerId)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ readerId
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -26,6 +27,20 @@ data class FirmwareArtifactReaderInfo(
26
27
  ) {
27
28
  /* primary constructor */
28
29
 
30
+ override fun equals(other: Any?): Boolean {
31
+ if (this === other) return true
32
+ if (other !is FirmwareArtifactReaderInfo) return false
33
+ return Objects.deepEquals(this.readerId, other.readerId)
34
+ && Objects.deepEquals(this.size, other.size)
35
+ }
36
+
37
+ override fun hashCode(): Int {
38
+ return arrayOf<Any?>(
39
+ readerId,
40
+ size
41
+ ).contentDeepHashCode()
42
+ }
43
+
29
44
  companion object {
30
45
  /**
31
46
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -29,6 +30,22 @@ data class FirmwareArtifactReaderReadParams(
29
30
  ) {
30
31
  /* primary constructor */
31
32
 
33
+ override fun equals(other: Any?): Boolean {
34
+ if (this === other) return true
35
+ if (other !is FirmwareArtifactReaderReadParams) return false
36
+ return Objects.deepEquals(this.readerId, other.readerId)
37
+ && Objects.deepEquals(this.offset, other.offset)
38
+ && Objects.deepEquals(this.length, other.length)
39
+ }
40
+
41
+ override fun hashCode(): Int {
42
+ return arrayOf<Any?>(
43
+ readerId,
44
+ offset,
45
+ length
46
+ ).contentDeepHashCode()
47
+ }
48
+
32
49
  companion object {
33
50
  /**
34
51
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -32,6 +33,24 @@ data class FirmwareArtifactReceipt(
32
33
  ) {
33
34
  /* primary constructor */
34
35
 
36
+ override fun equals(other: Any?): Boolean {
37
+ if (this === other) return true
38
+ if (other !is FirmwareArtifactReceipt) return false
39
+ return Objects.deepEquals(this.artifactRef, other.artifactRef)
40
+ && Objects.deepEquals(this.size, other.size)
41
+ && Objects.deepEquals(this.sha256, other.sha256)
42
+ && Objects.deepEquals(this.expectedSha256Verified, other.expectedSha256Verified)
43
+ }
44
+
45
+ override fun hashCode(): Int {
46
+ return arrayOf<Any?>(
47
+ artifactRef,
48
+ size,
49
+ sha256,
50
+ expectedSha256Verified
51
+ ).contentDeepHashCode()
52
+ }
53
+
35
54
  companion object {
36
55
  /**
37
56
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -23,6 +24,18 @@ data class FirmwareArtifactRefParams(
23
24
  ) {
24
25
  /* primary constructor */
25
26
 
27
+ override fun equals(other: Any?): Boolean {
28
+ if (this === other) return true
29
+ if (other !is FirmwareArtifactRefParams) return false
30
+ return Objects.deepEquals(this.artifactRef, other.artifactRef)
31
+ }
32
+
33
+ override fun hashCode(): Int {
34
+ return arrayOf<Any?>(
35
+ artifactRef
36
+ ).contentDeepHashCode()
37
+ }
38
+
26
39
  companion object {
27
40
  /**
28
41
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -26,6 +27,20 @@ data class FirmwareArtifactSweepResult(
26
27
  ) {
27
28
  /* primary constructor */
28
29
 
30
+ override fun equals(other: Any?): Boolean {
31
+ if (this === other) return true
32
+ if (other !is FirmwareArtifactSweepResult) return false
33
+ return Objects.deepEquals(this.deletedFiles, other.deletedFiles)
34
+ && Objects.deepEquals(this.deletedBytes, other.deletedBytes)
35
+ }
36
+
37
+ override fun hashCode(): Int {
38
+ return arrayOf<Any?>(
39
+ deletedFiles,
40
+ deletedBytes
41
+ ).contentDeepHashCode()
42
+ }
43
+
29
44
  companion object {
30
45
  /**
31
46
  * Constructor called from C++
@@ -10,7 +10,6 @@ package com.margelo.nitro.reactnativerangedownloader
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.jni.HybridData
12
12
  import com.facebook.proguard.annotations.DoNotStrip
13
- import dalvik.annotation.optimization.FastNative
14
13
 
15
14
 
16
15
  /**
@@ -59,7 +58,6 @@ class Func_void_RangeDownloadEvent_cxx: Func_void_RangeDownloadEvent {
59
58
  override fun invoke(event: RangeDownloadEvent): Unit
60
59
  = invoke_cxx(event)
61
60
 
62
- @FastNative
63
61
  private external fun invoke_cxx(event: RangeDownloadEvent): Unit
64
62
  }
65
63
 
@@ -10,6 +10,7 @@ package com.margelo.nitro.reactnativerangedownloader
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.jni.HybridData
12
12
  import com.facebook.proguard.annotations.DoNotStrip
13
+ import dalvik.annotation.optimization.FastNative
13
14
  import com.margelo.nitro.core.Promise
14
15
  import com.margelo.nitro.core.ArrayBuffer
15
16
  import com.margelo.nitro.core.HybridObject
@@ -117,6 +118,7 @@ abstract class HybridReactNativeRangeDownloaderSpec: HybridObject() {
117
118
  @Keep
118
119
  protected open class CxxPart(javaPart: HybridReactNativeRangeDownloaderSpec): HybridObject.CxxPart(javaPart) {
119
120
  // C++ JHybridReactNativeRangeDownloaderSpec::CxxPart::initHybrid(...)
121
+ @FastNative
120
122
  external override fun initHybrid(): HybridData
121
123
  }
122
124
  override fun createCxxPart(): CxxPart {
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -35,6 +36,26 @@ data class RangeDownloadEvent(
35
36
  ) {
36
37
  /* primary constructor */
37
38
 
39
+ override fun equals(other: Any?): Boolean {
40
+ if (this === other) return true
41
+ if (other !is RangeDownloadEvent) return false
42
+ return Objects.deepEquals(this.channel, other.channel)
43
+ && Objects.deepEquals(this.taskId, other.taskId)
44
+ && Objects.deepEquals(this.type, other.type)
45
+ && Objects.deepEquals(this.progress, other.progress)
46
+ && Objects.deepEquals(this.message, other.message)
47
+ }
48
+
49
+ override fun hashCode(): Int {
50
+ return arrayOf<Any?>(
51
+ channel,
52
+ taskId,
53
+ type,
54
+ progress,
55
+ message
56
+ ).contentDeepHashCode()
57
+ }
58
+
38
59
  companion object {
39
60
  /**
40
61
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -53,6 +54,38 @@ data class RangeDownloadParams(
53
54
  ) {
54
55
  /* primary constructor */
55
56
 
57
+ override fun equals(other: Any?): Boolean {
58
+ if (this === other) return true
59
+ if (other !is RangeDownloadParams) return false
60
+ return Objects.deepEquals(this.channel, other.channel)
61
+ && Objects.deepEquals(this.taskId, other.taskId)
62
+ && Objects.deepEquals(this.url, other.url)
63
+ && Objects.deepEquals(this.destFilePath, other.destFilePath)
64
+ && Objects.deepEquals(this.expectedSha256, other.expectedSha256)
65
+ && Objects.deepEquals(this.segmentCount, other.segmentCount)
66
+ && Objects.deepEquals(this.minConcurrentBytes, other.minConcurrentBytes)
67
+ && Objects.deepEquals(this.maxSegmentAttempts, other.maxSegmentAttempts)
68
+ && Objects.deepEquals(this.requestTimeoutSeconds, other.requestTimeoutSeconds)
69
+ && Objects.deepEquals(this.stallTimeoutSeconds, other.stallTimeoutSeconds)
70
+ && Objects.deepEquals(this.overallDeadlineSeconds, other.overallDeadlineSeconds)
71
+ }
72
+
73
+ override fun hashCode(): Int {
74
+ return arrayOf<Any?>(
75
+ channel,
76
+ taskId,
77
+ url,
78
+ destFilePath,
79
+ expectedSha256,
80
+ segmentCount,
81
+ minConcurrentBytes,
82
+ maxSegmentAttempts,
83
+ requestTimeoutSeconds,
84
+ stallTimeoutSeconds,
85
+ overallDeadlineSeconds
86
+ ).contentDeepHashCode()
87
+ }
88
+
56
89
  companion object {
57
90
  /**
58
91
  * Constructor called from C++
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativerangedownloader
9
9
 
10
10
  import androidx.annotation.Keep
11
11
  import com.facebook.proguard.annotations.DoNotStrip
12
+ import java.util.Objects
12
13
 
13
14
 
14
15
  /**
@@ -32,6 +33,24 @@ data class RangeDownloadResult(
32
33
  ) {
33
34
  /* primary constructor */
34
35
 
36
+ override fun equals(other: Any?): Boolean {
37
+ if (this === other) return true
38
+ if (other !is RangeDownloadResult) return false
39
+ return Objects.deepEquals(this.outcome, other.outcome)
40
+ && Objects.deepEquals(this.filePath, other.filePath)
41
+ && Objects.deepEquals(this.fallbackReason, other.fallbackReason)
42
+ && Objects.deepEquals(this.fallbackKind, other.fallbackKind)
43
+ }
44
+
45
+ override fun hashCode(): Int {
46
+ return arrayOf<Any?>(
47
+ outcome,
48
+ filePath,
49
+ fallbackReason,
50
+ fallbackKind
51
+ ).contentDeepHashCode()
52
+ }
53
+
35
54
  companion object {
36
55
  /**
37
56
  * Constructor called from C++
@@ -56,5 +56,7 @@ def add_nitrogen_files(spec)
56
56
  "SWIFT_OBJC_INTEROP_MODE" => "objcxx",
57
57
  # Enables stricter modular headers
58
58
  "DEFINES_MODULE" => "YES",
59
+ # Disable auto-generated ObjC header for Swift (Static linkage on Xcode 26.4 breaks here)
60
+ "SWIFT_INSTALL_OBJC_HEADER" => "NO",
59
61
  })
60
62
  end
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onekeyfe/react-native-range-downloader",
3
- "version": "3.0.86",
3
+ "version": "3.0.88",
4
4
  "description": "react-native-range-downloader",
5
5
  "main": "./lib/module/index.js",
6
6
  "types": "./lib/typescript/src/index.d.ts",
@@ -77,12 +77,12 @@
77
77
  "eslint-plugin-prettier": "^5.5.4",
78
78
  "jest": "^29.7.0",
79
79
  "lefthook": "^2.0.3",
80
- "nitrogen": "0.35.2",
80
+ "nitrogen": "0.36.5",
81
81
  "prettier": "^2.8.8",
82
82
  "react": "19.2.0",
83
83
  "react-native": "patch:react-native@npm%3A0.83.0#~/.yarn/patches/react-native-npm-0.83.0-577d0f2d83.patch",
84
84
  "react-native-builder-bob": "^0.40.13",
85
- "react-native-nitro-modules": "0.35.2",
85
+ "react-native-nitro-modules": "0.36.5",
86
86
  "release-it": "^19.0.4",
87
87
  "turbo": "^2.5.6",
88
88
  "typescript": "^5.9.2"
@@ -90,7 +90,7 @@
90
90
  "peerDependencies": {
91
91
  "react": "*",
92
92
  "react-native": "*",
93
- "react-native-nitro-modules": "0.35.2"
93
+ "react-native-nitro-modules": "0.36.5"
94
94
  },
95
95
  "react-native-builder-bob": {
96
96
  "source": "src",