///
/// ReactNativeVideoDrm-Swift-Cxx-Bridge.cpp
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
/// https://github.com/mrousavy/nitro
/// Copyright © 2025 Marc Rousavy @ Margelo
///

#include "ReactNativeVideoDrm-Swift-Cxx-Bridge.hpp"

// Include C++ implementation defined types
#include "HybridPluginManagerSpecSwift.hpp"
#include "ReactNativeVideoDrm-Swift-Cxx-Umbrella.hpp"

namespace margelo::nitro::videodrm::bridge::swift {

  // pragma MARK: std::shared_ptr<HybridPluginManagerSpec>
  std::shared_ptr<HybridPluginManagerSpec> create_std__shared_ptr_HybridPluginManagerSpec_(void* _Nonnull swiftUnsafePointer) {
    ReactNativeVideoDrm::HybridPluginManagerSpec_cxx swiftPart = ReactNativeVideoDrm::HybridPluginManagerSpec_cxx::fromUnsafe(swiftUnsafePointer);
    return std::make_shared<margelo::nitro::videodrm::HybridPluginManagerSpecSwift>(swiftPart);
  }
  void* _Nonnull get_std__shared_ptr_HybridPluginManagerSpec_(std__shared_ptr_HybridPluginManagerSpec_ cppType) {
    std::shared_ptr<margelo::nitro::videodrm::HybridPluginManagerSpecSwift> swiftWrapper = std::dynamic_pointer_cast<margelo::nitro::videodrm::HybridPluginManagerSpecSwift>(cppType);
    #ifdef NITRO_DEBUG
    if (swiftWrapper == nullptr) [[unlikely]] {
      throw std::runtime_error("Class \"HybridPluginManagerSpec\" is not implemented in Swift!");
    }
    #endif
    ReactNativeVideoDrm::HybridPluginManagerSpec_cxx& swiftPart = swiftWrapper->getSwiftPart();
    return swiftPart.toUnsafe();
  }

} // namespace margelo::nitro::videodrm::bridge::swift
