/**
 * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
 *
 * Do not edit this file as changes may cause incorrect behavior and will be lost
 * once the code is regenerated.
 *
 * @generated by codegen project: GenerateModuleCpp.js
 */

#include "RNZstdSpecJSI.h"

namespace facebook::react {

static jsi::Value __hostFunction_NativeZstdCxxSpecJSI_compress(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
  return static_cast<NativeZstdCxxSpecJSI *>(&turboModule)->compress(
    rt,
    count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
    count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asNumber()
  );
}
static jsi::Value __hostFunction_NativeZstdCxxSpecJSI_decompress(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
  return static_cast<NativeZstdCxxSpecJSI *>(&turboModule)->decompress(
    rt,
    count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt).asArray(rt)
  );
}

NativeZstdCxxSpecJSI::NativeZstdCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
  : TurboModule("Zstd", jsInvoker) {
  methodMap_["compress"] = MethodMetadata {2, __hostFunction_NativeZstdCxxSpecJSI_compress};
  methodMap_["decompress"] = MethodMetadata {1, __hostFunction_NativeZstdCxxSpecJSI_decompress};
}


} // namespace facebook::react
