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

import NitroModules

/// See ``HybridBarcodeSpec``
public protocol HybridBarcodeSpec_protocol: HybridObject {
  // Properties
  var format: BarcodeFormat { get }
  var boundingBox: Rect { get }
  var cornerPoints: [Point] { get }
  var displayValue: String? { get }
  var rawBytes: ArrayBuffer? { get }
  var rawValue: String? { get }
  var valueType: BarcodeValueType { get }

  // Methods
  
}

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

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

/**
 * A Swift base-protocol representing the Barcode HybridObject.
 * Implement this protocol to create Swift-based instances of Barcode.
 * ```swift
 * class HybridBarcode : HybridBarcodeSpec {
 *   // ...
 * }
 * ```
 */
public typealias HybridBarcodeSpec = HybridBarcodeSpec_protocol & HybridBarcodeSpec_base
