///
/// HybridViewModelImagePropertySpec.swift
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
/// https://github.com/mrousavy/nitro
/// Copyright © Marc Rousavy @ Margelo
///

import NitroModules

/// See ``HybridViewModelImagePropertySpec``
public protocol HybridViewModelImagePropertySpec_protocol: HybridObject, HybridViewModelPropertySpec_protocol {
  // Properties
  

  // Methods
  func set(image: (any HybridRiveImageSpec)?) throws -> Void
  func addListener(onChanged: @escaping () -> Void) throws -> () -> Void
  func removeListeners() throws -> Void
}

public extension HybridViewModelImagePropertySpec_protocol {
  /// Default implementation of ``HybridObject.toString``
  func toString() -> String {
    return "[HybridObject ViewModelImageProperty]"
  }
}

/// See ``HybridViewModelImagePropertySpec``
open class HybridViewModelImagePropertySpec_base: HybridViewModelPropertySpec_base {
  private weak var cxxWrapper: HybridViewModelImagePropertySpec_cxx? = nil
  public override init() { super.init() }
  public override func getCxxWrapper() -> HybridViewModelImagePropertySpec_cxx {
  #if DEBUG
    guard self is any HybridViewModelImagePropertySpec else {
      fatalError("`self` is not a `HybridViewModelImagePropertySpec`! Did you accidentally inherit from `HybridViewModelImagePropertySpec_base` instead of `HybridViewModelImagePropertySpec`?")
    }
  #endif
    if let cxxWrapper = self.cxxWrapper {
      return cxxWrapper
    } else {
      let cxxWrapper = HybridViewModelImagePropertySpec_cxx(self as! any HybridViewModelImagePropertySpec)
      self.cxxWrapper = cxxWrapper
      return cxxWrapper
    }
  }
}

/**
 * A Swift base-protocol representing the ViewModelImageProperty HybridObject.
 * Implement this protocol to create Swift-based instances of ViewModelImageProperty.
 * ```swift
 * class HybridViewModelImageProperty : HybridViewModelImagePropertySpec {
 *   // ...
 * }
 * ```
 */
public typealias HybridViewModelImagePropertySpec = HybridViewModelImagePropertySpec_protocol & HybridViewModelImagePropertySpec_base
