CameraView
struct CameraView : UIViewControllerRepresentable
CameraView
- Description: This class is a wrapper for CameraViewController
-
The Controoler to be wrapped.
Declaration
Swift
var controller: QRScannerController
-
The closure to be called when a QR code is detected.
Declaration
Swift
var handleDetectedQR: () -> Void
-
Creates the CameraViewController and sets the handleDetectedQR closure.
Declaration
Swift
func makeUIViewController(context: Context) -> QRScannerController
Parameters
context
The context of the view.
Return Value
The created CameraViewController.
-
Updates the CameraViewController.
Declaration
Swift
func updateUIViewController(_ uiViewController: QRScannerController, context: Context)
Parameters
uiViewController
The CameraViewController to update.
context
The context of the view.