#if 0
#elif defined(__arm64__) && __arm64__
// Generated by Apple Swift version 6.0.3 effective-5.10 (swiftlang-6.0.3.1.10 clang-1600.0.30.1)
#ifndef GSSDK_SWIFT_H
#define GSSDK_SWIFT_H
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wgcc-compat"

#if !defined(__has_include)
# define __has_include(x) 0
#endif
#if !defined(__has_attribute)
# define __has_attribute(x) 0
#endif
#if !defined(__has_feature)
# define __has_feature(x) 0
#endif
#if !defined(__has_warning)
# define __has_warning(x) 0
#endif

#if __has_include(<swift/objc-prologue.h>)
# include <swift/objc-prologue.h>
#endif

#pragma clang diagnostic ignored "-Wauto-import"
#if defined(__OBJC__)
#include <Foundation/Foundation.h>
#endif
#if defined(__cplusplus)
#include <cstdint>
#include <cstddef>
#include <cstdbool>
#include <cstring>
#include <stdlib.h>
#include <new>
#include <type_traits>
#else
#include <stdint.h>
#include <stddef.h>
#include <stdbool.h>
#include <string.h>
#endif
#if defined(__cplusplus)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wnon-modular-include-in-framework-module"
#if defined(__arm64e__) && __has_include(<ptrauth.h>)
# include <ptrauth.h>
#else
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wreserved-macro-identifier"
# ifndef __ptrauth_swift_value_witness_function_pointer
#  define __ptrauth_swift_value_witness_function_pointer(x)
# endif
# ifndef __ptrauth_swift_class_method_pointer
#  define __ptrauth_swift_class_method_pointer(x)
# endif
#pragma clang diagnostic pop
#endif
#pragma clang diagnostic pop
#endif

#if !defined(SWIFT_TYPEDEFS)
# define SWIFT_TYPEDEFS 1
# if __has_include(<uchar.h>)
#  include <uchar.h>
# elif !defined(__cplusplus)
typedef uint_least16_t char16_t;
typedef uint_least32_t char32_t;
# endif
typedef float swift_float2  __attribute__((__ext_vector_type__(2)));
typedef float swift_float3  __attribute__((__ext_vector_type__(3)));
typedef float swift_float4  __attribute__((__ext_vector_type__(4)));
typedef double swift_double2  __attribute__((__ext_vector_type__(2)));
typedef double swift_double3  __attribute__((__ext_vector_type__(3)));
typedef double swift_double4  __attribute__((__ext_vector_type__(4)));
typedef int swift_int2  __attribute__((__ext_vector_type__(2)));
typedef int swift_int3  __attribute__((__ext_vector_type__(3)));
typedef int swift_int4  __attribute__((__ext_vector_type__(4)));
typedef unsigned int swift_uint2  __attribute__((__ext_vector_type__(2)));
typedef unsigned int swift_uint3  __attribute__((__ext_vector_type__(3)));
typedef unsigned int swift_uint4  __attribute__((__ext_vector_type__(4)));
#endif

#if !defined(SWIFT_PASTE)
# define SWIFT_PASTE_HELPER(x, y) x##y
# define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y)
#endif
#if !defined(SWIFT_METATYPE)
# define SWIFT_METATYPE(X) Class
#endif
#if !defined(SWIFT_CLASS_PROPERTY)
# if __has_feature(objc_class_property)
#  define SWIFT_CLASS_PROPERTY(...) __VA_ARGS__
# else
#  define SWIFT_CLASS_PROPERTY(...) 
# endif
#endif
#if !defined(SWIFT_RUNTIME_NAME)
# if __has_attribute(objc_runtime_name)
#  define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X)))
# else
#  define SWIFT_RUNTIME_NAME(X) 
# endif
#endif
#if !defined(SWIFT_COMPILE_NAME)
# if __has_attribute(swift_name)
#  define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X)))
# else
#  define SWIFT_COMPILE_NAME(X) 
# endif
#endif
#if !defined(SWIFT_METHOD_FAMILY)
# if __has_attribute(objc_method_family)
#  define SWIFT_METHOD_FAMILY(X) __attribute__((objc_method_family(X)))
# else
#  define SWIFT_METHOD_FAMILY(X) 
# endif
#endif
#if !defined(SWIFT_NOESCAPE)
# if __has_attribute(noescape)
#  define SWIFT_NOESCAPE __attribute__((noescape))
# else
#  define SWIFT_NOESCAPE 
# endif
#endif
#if !defined(SWIFT_RELEASES_ARGUMENT)
# if __has_attribute(ns_consumed)
#  define SWIFT_RELEASES_ARGUMENT __attribute__((ns_consumed))
# else
#  define SWIFT_RELEASES_ARGUMENT 
# endif
#endif
#if !defined(SWIFT_WARN_UNUSED_RESULT)
# if __has_attribute(warn_unused_result)
#  define SWIFT_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
# else
#  define SWIFT_WARN_UNUSED_RESULT 
# endif
#endif
#if !defined(SWIFT_NORETURN)
# if __has_attribute(noreturn)
#  define SWIFT_NORETURN __attribute__((noreturn))
# else
#  define SWIFT_NORETURN 
# endif
#endif
#if !defined(SWIFT_CLASS_EXTRA)
# define SWIFT_CLASS_EXTRA 
#endif
#if !defined(SWIFT_PROTOCOL_EXTRA)
# define SWIFT_PROTOCOL_EXTRA 
#endif
#if !defined(SWIFT_ENUM_EXTRA)
# define SWIFT_ENUM_EXTRA 
#endif
#if !defined(SWIFT_CLASS)
# if __has_attribute(objc_subclassing_restricted)
#  define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA
#  define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
# else
#  define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
#  define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
# endif
#endif
#if !defined(SWIFT_RESILIENT_CLASS)
# if __has_attribute(objc_class_stub)
#  define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME) __attribute__((objc_class_stub))
#  define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_class_stub)) SWIFT_CLASS_NAMED(SWIFT_NAME)
# else
#  define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME)
#  define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) SWIFT_CLASS_NAMED(SWIFT_NAME)
# endif
#endif
#if !defined(SWIFT_PROTOCOL)
# define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
# define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
#endif
#if !defined(SWIFT_EXTENSION)
# define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__)
#endif
#if !defined(OBJC_DESIGNATED_INITIALIZER)
# if __has_attribute(objc_designated_initializer)
#  define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer))
# else
#  define OBJC_DESIGNATED_INITIALIZER 
# endif
#endif
#if !defined(SWIFT_ENUM_ATTR)
# if __has_attribute(enum_extensibility)
#  define SWIFT_ENUM_ATTR(_extensibility) __attribute__((enum_extensibility(_extensibility)))
# else
#  define SWIFT_ENUM_ATTR(_extensibility) 
# endif
#endif
#if !defined(SWIFT_ENUM)
# define SWIFT_ENUM(_type, _name, _extensibility) enum _name : _type _name; enum SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
# if __has_feature(generalized_swift_name)
#  define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) enum _name : _type _name SWIFT_COMPILE_NAME(SWIFT_NAME); enum SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
# else
#  define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) SWIFT_ENUM(_type, _name, _extensibility)
# endif
#endif
#if !defined(SWIFT_UNAVAILABLE)
# define SWIFT_UNAVAILABLE __attribute__((unavailable))
#endif
#if !defined(SWIFT_UNAVAILABLE_MSG)
# define SWIFT_UNAVAILABLE_MSG(msg) __attribute__((unavailable(msg)))
#endif
#if !defined(SWIFT_AVAILABILITY)
# define SWIFT_AVAILABILITY(plat, ...) __attribute__((availability(plat, __VA_ARGS__)))
#endif
#if !defined(SWIFT_WEAK_IMPORT)
# define SWIFT_WEAK_IMPORT __attribute__((weak_import))
#endif
#if !defined(SWIFT_DEPRECATED)
# define SWIFT_DEPRECATED __attribute__((deprecated))
#endif
#if !defined(SWIFT_DEPRECATED_MSG)
# define SWIFT_DEPRECATED_MSG(...) __attribute__((deprecated(__VA_ARGS__)))
#endif
#if !defined(SWIFT_DEPRECATED_OBJC)
# if __has_feature(attribute_diagnose_if_objc)
#  define SWIFT_DEPRECATED_OBJC(Msg) __attribute__((diagnose_if(1, Msg, "warning")))
# else
#  define SWIFT_DEPRECATED_OBJC(Msg) SWIFT_DEPRECATED_MSG(Msg)
# endif
#endif
#if defined(__OBJC__)
#if !defined(IBSegueAction)
# define IBSegueAction 
#endif
#endif
#if !defined(SWIFT_EXTERN)
# if defined(__cplusplus)
#  define SWIFT_EXTERN extern "C"
# else
#  define SWIFT_EXTERN extern
# endif
#endif
#if !defined(SWIFT_CALL)
# define SWIFT_CALL __attribute__((swiftcall))
#endif
#if !defined(SWIFT_INDIRECT_RESULT)
# define SWIFT_INDIRECT_RESULT __attribute__((swift_indirect_result))
#endif
#if !defined(SWIFT_CONTEXT)
# define SWIFT_CONTEXT __attribute__((swift_context))
#endif
#if !defined(SWIFT_ERROR_RESULT)
# define SWIFT_ERROR_RESULT __attribute__((swift_error_result))
#endif
#if defined(__cplusplus)
# define SWIFT_NOEXCEPT noexcept
#else
# define SWIFT_NOEXCEPT 
#endif
#if !defined(SWIFT_C_INLINE_THUNK)
# if __has_attribute(always_inline)
# if __has_attribute(nodebug)
#  define SWIFT_C_INLINE_THUNK inline __attribute__((always_inline)) __attribute__((nodebug))
# else
#  define SWIFT_C_INLINE_THUNK inline __attribute__((always_inline))
# endif
# else
#  define SWIFT_C_INLINE_THUNK inline
# endif
#endif
#if defined(_WIN32)
#if !defined(SWIFT_IMPORT_STDLIB_SYMBOL)
# define SWIFT_IMPORT_STDLIB_SYMBOL __declspec(dllimport)
#endif
#else
#if !defined(SWIFT_IMPORT_STDLIB_SYMBOL)
# define SWIFT_IMPORT_STDLIB_SYMBOL 
#endif
#endif
#if defined(__OBJC__)
#if __has_feature(objc_modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import AVFoundation;
@import CoreFoundation;
@import CoreGraphics;
@import Dispatch;
@import Foundation;
@import ObjectiveC;
@import UIKit;
#endif

#import <GSSDK/GSSDK.h>

#endif
#pragma clang diagnostic ignored "-Wproperty-attribute-mismatch"
#pragma clang diagnostic ignored "-Wduplicate-method-arg"
#if __has_warning("-Wpragma-clang-attribute")
# pragma clang diagnostic ignored "-Wpragma-clang-attribute"
#endif
#pragma clang diagnostic ignored "-Wunknown-pragmas"
#pragma clang diagnostic ignored "-Wnullability"
#pragma clang diagnostic ignored "-Wdollar-in-identifier-extension"
#pragma clang diagnostic ignored "-Wunsafe-buffer-usage"

#if __has_attribute(external_source_symbol)
# pragma push_macro("any")
# undef any
# pragma clang attribute push(__attribute__((external_source_symbol(language="Swift", defined_in="GSSDK",generated_declaration))), apply_to=any(function,enum,objc_interface,objc_category,objc_protocol))
# pragma pop_macro("any")
#endif

#if defined(__OBJC__)

SWIFT_PROTOCOL("_TtP5GSSDK20CGImageRepresentable_")
@protocol CGImageRepresentable
- (CGImageRef _Nullable)CGImageRepresentation SWIFT_WARN_UNUSED_RESULT;
@end


@interface AVCapturePhoto (SWIFT_EXTENSION(GSSDK)) <CGImageRepresentable>
@end







@class NSString;

/// Entry point of the SDK. Use this to initialize the SDK with your license key.
SWIFT_CLASS("_TtC5GSSDK3GSK")
@interface GSK : NSObject
/// Returns the Genius Scan SDK version
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _Nonnull sdkVersion;)
+ (NSString * _Nonnull)sdkVersion SWIFT_WARN_UNUSED_RESULT;
/// Sets the Genius Scan SDK license key with auto-refresh enabled.
/// See <code>setLicenseKey:autoRefresh:</code>
+ (void)setLicenseKey:(NSString * _Nonnull)licenseKey;
/// Sets the Genius Scan SDK license key, while optionally enabling auto-refresh.
/// This method doesn’t return an error but will log warnings should the key be invalid or expired. All other SDK methods that return errors will report
/// an error if there is a problem with the license key, and you must handle them to ensure you provide a good “degraded” experience.
/// For instance, you can prompt the user to update the application to use the scanning feature in case they use a version of the application with an expired license key.
/// important:
/// This method must be called with a valid license key before any use of the SDK methods.
/// \param licenseKey A valid license key. You must publish a new version of the app with an updated license key before the key expires.
///
/// \param autoRefresh If true, the SDK will attempt to automatically refresh the license key to prevent any diruption of service on devices that wouldn’t have
/// updated to the latest version of your app containing the new keys. If <code>autoRefresh</code> is enabled, the following information is sent to the Genius Scan
/// SDK servers: the current license key, a device-unique UUID, and the current version of the app.
///
+ (void)setLicenseKey:(NSString * _Nonnull)licenseKey autoRefresh:(BOOL)autoRefresh;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end

@class AVCaptureDevice;
@class AVCaptureSession;
enum GSKCameraSessionFlashStatus : NSInteger;
enum GSKCameraSessionDocumentDetection : NSInteger;
@class GSKCameraSessionConfiguration;

SWIFT_CLASS("_TtC5GSSDK16GSKCameraSession")
@interface GSKCameraSession : NSObject
/// Minimum duration in <code>.aboutToTrigger</code> state before triggering the photo.
/// This can be used to coordinate animations.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly) NSTimeInterval minDurationInAboutToTriggerForTrigger;)
+ (NSTimeInterval)minDurationInAboutToTriggerForTrigger SWIFT_WARN_UNUSED_RESULT;
/// Public for legacy reasons, not to be used directly.
@property (nonatomic, strong) AVCaptureDevice * _Nullable captureDevice;
/// Public for legacy reasons, not to be used directly.
@property (nonatomic, strong) AVCaptureSession * _Nullable captureSession;
/// The flash mode. Default is .auto.
@property (nonatomic) enum GSKCameraSessionFlashStatus flashStatus;
/// Returns the current status of the document detection.
/// While you can configure the desired mode when setting up the session, the current value can change: for instance, the
/// active document detection is <code>.none</code> while taking the photo, or when the session is paused, even if the requested
/// detection is <code>.highlightAndTrigger</code>.
/// Observable.
@property (nonatomic) enum GSKCameraSessionDocumentDetection activeDocumentDetection;
/// True for the duration of taking the photo and processing it. Observable.
@property (nonatomic, readonly) BOOL isTakingPhoto;
/// Returns false if flash isn’t supported on this device configuration.
@property (nonatomic, readonly) BOOL supportsFlash;
/// Public to be accessible from Objective-C, but should be private otherwise.
@property (nonatomic, readonly, strong) dispatch_queue_t _Nullable captureSessionQueue;
@property (nonatomic, readonly, strong) dispatch_queue_t _Nonnull takePhotoQueue;
- (nonnull instancetype)initWithConfiguration:(GSKCameraSessionConfiguration * _Nonnull)configuration;
- (void)pauseSession;
- (void)resumeSession;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end




@interface GSKCameraSession (SWIFT_EXTENSION(GSSDK))
/// Manually take a photo
/// If autoTriggerEnabled is true, the photo is taken automatically when the frame is detected.
/// Otherwise, if you want to let the user manually trigger the photo, you can use this method.
/// This method can be called even when activeDetectionMode is higlightAndTrigger and will force taking the
/// photo.
/// This method is thread-safe.
/// IMPORTANT: Taking the photo will pause the session. You have to resume the session will <code>resumeSession</code> once
/// you are done processing the result.
- (void)takePhoto;
@end



@class AVCapturePhotoOutput;
@class AVCaptureResolvedPhotoSettings;

@interface GSKCameraSession (SWIFT_EXTENSION(GSSDK)) <AVCapturePhotoCaptureDelegate>
- (void)captureOutput:(AVCapturePhotoOutput * _Nonnull)output willBeginCaptureForResolvedSettings:(AVCaptureResolvedPhotoSettings * _Nonnull)resolvedSettings;
- (void)captureOutput:(AVCapturePhotoOutput * _Nonnull)output willCapturePhotoForResolvedSettings:(AVCaptureResolvedPhotoSettings * _Nonnull)resolvedSettings;
- (void)captureOutput:(AVCapturePhotoOutput * _Nonnull)output didCapturePhotoForResolvedSettings:(AVCaptureResolvedPhotoSettings * _Nonnull)resolvedSettings;
- (void)captureOutput:(AVCapturePhotoOutput * _Nonnull)output didFinishProcessingPhoto:(AVCapturePhoto * _Nonnull)photo error:(NSError * _Nullable)error;
- (void)captureOutput:(AVCapturePhotoOutput * _Nonnull)output didFinishCaptureForResolvedSettings:(AVCaptureResolvedPhotoSettings * _Nonnull)resolvedSettings error:(NSError * _Nullable)error;
@end




/// The configuration for a camera session.
SWIFT_CLASS("_TtC5GSSDK29GSKCameraSessionConfiguration")
@interface GSKCameraSessionConfiguration : NSObject
/// \param documentDetection The type of real-time document detection to apply.
///
- (nonnull instancetype)initWithDocumentDetection:(enum GSKCameraSessionDocumentDetection)documentDetection OBJC_DESIGNATED_INITIALIZER;
/// A session configuration where the document detection is <code>.highlightAndTrigger</code>
- (nonnull instancetype)init;
@end

/// The style of document detection to be used during a camera session.
typedef SWIFT_ENUM(NSInteger, GSKCameraSessionDocumentDetection, open) {
/// The session doesn’t attempt to detect documents.
  GSKCameraSessionDocumentDetectionNone = 0,
/// The session detects documents and produces quadrangles
/// to be used for highlighting the document in the video frames.
  GSKCameraSessionDocumentDetectionHighlight = 1,
/// The session detects documents and snaps the photo when
/// the detection is stable.
  GSKCameraSessionDocumentDetectionHighlightAndTrigger = 2,
};

/// Represents an error raised by the camera session
typedef SWIFT_ENUM(NSInteger, GSKCameraSessionError, open) {
  GSKCameraSessionErrorOther = -1,
  GSKCameraSessionErrorNotAuthorized = -2,
  GSKCameraSessionErrorLockDevice = -3,
  GSKCameraSessionErrorNoDevice = -4,
  GSKCameraSessionErrorInvalidSetupDependency = -5,
  GSKCameraSessionErrorNoVideoCaptureConnection = -6,
  GSKCameraSessionErrorInvalidData = -7,
  GSKCameraSessionErrorBadInput = -8,
  GSKCameraSessionErrorWarnLockDevice = -1003,
};

typedef SWIFT_ENUM(NSInteger, GSKCameraSessionFlashStatus, open) {
  GSKCameraSessionFlashStatusAuto = 0,
  GSKCameraSessionFlashStatusOn = 1,
  GSKCameraSessionFlashStatusOff = 2,
};

@class NSCoder;
@protocol UIViewControllerTransitionCoordinator;
@class NSBundle;

/// A ready-to-use camera interface for scanning documents.
SWIFT_CLASS("_TtC5GSSDK23GSKCameraViewController")
@interface GSKCameraViewController : UIViewController
- (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER SWIFT_UNAVAILABLE;
- (nonnull instancetype)initWithCameraSession:(GSKCameraSession * _Nonnull)cameraSession OBJC_DESIGNATED_INITIALIZER;
@property (nonatomic, readonly) BOOL prefersStatusBarHidden;
- (void)loadView;
- (void)viewDidLoad;
- (void)viewWillAppear:(BOOL)animated;
- (void)viewWillDisappear:(BOOL)animated;
- (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id <UIViewControllerTransitionCoordinator> _Nonnull)coordinator;
- (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
@end

@class GSKView;

@interface GSKCameraViewController (SWIFT_EXTENSION(GSSDK)) <GSKViewDelegate>
- (void)cameraView:(GSKView * _Nonnull)cameraView requestedFocusAtPoint:(CGPoint)focusPoint;
@end



@interface GSKCameraViewController (SWIFT_EXTENSION(GSSDK))
/// Snap the photo
- (void)takePhoto;
@end

@class GSKScan;
@class GSKQuadrangle;

@interface GSKCameraViewController (SWIFT_EXTENSION(GSSDK))
- (void)cameraSessionDidSetup:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession setupFailedWithError:(NSError * _Nonnull)error;
- (void)cameraSessionWillSnapPhoto:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSessionDidSnapPhoto:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession didFailToSnapPhotoWithError:(NSError * _Nonnull)error;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession didGenerateScan:(GSKScan * _Nonnull)scan;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession didEncounterFailureWithError:(NSError * _Nonnull)error;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession didFailWithError:(NSError * _Nonnull)error;
- (void)cameraSessionIsSearchingQuadrangle:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSessionIsAboutToChooseQuadrangle:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession willAutoTriggerWithQuadrangle:(GSKQuadrangle * _Nonnull)quadrangle;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession didFindQuadrangle:(GSKQuadrangle * _Nonnull)quadrangle;
- (void)cameraSessionFailedToFindQuadrangle:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSessionDidStart:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSessionDidStop:(GSKCameraSession * _Nonnull)cameraSession;
- (void)cameraSession:(GSKCameraSession * _Nonnull)cameraSession wasInterruptedWithReason:(enum AVCaptureSessionInterruptionReason)reason;
- (void)cameraSessionInterruptionEnded:(GSKCameraSession * _Nonnull)cameraSession;
@end

/// The type of document detected by the document finder.
typedef SWIFT_ENUM(NSInteger, GSKDocumentFinderImageType, closed) {
/// No document present in the image
  GSKDocumentFinderImageTypeNoDocument = 0,
/// A document present in the image, but no crop, perspective correction have been applied
  GSKDocumentFinderImageTypeUnwarped = 1,
/// A document present in the image, and crop, perspective correction have been applied
  GSKDocumentFinderImageTypeWarped = 2,
/// A document present in the image, crop/perspective correction and
/// enhanced have been applied.
  GSKDocumentFinderImageTypeEnhanced = 3,
};

@class GSKPDFDocument;
@protocol GSKDocumentImageProcessor;
@class GSKDocumentGeneratorConfiguration;

/// This class exposes the capacility to generate a PDF document file.
SWIFT_CLASS("_TtC5GSSDK20GSKDocumentGenerator")
@interface GSKDocumentGenerator : NSObject
/// Generates a document file based on a document model and a generator configuration.
/// \param document The source document to generate as PDF.
///
/// \param imageProcessor An object used to process each source document’s image before inserting it in the resulting document.
/// Only used when generating a PDF document
///
/// \param configuration The configuration for the document generation.
///
- (BOOL)generate:(GSKPDFDocument * _Nonnull)document imageProcessor:(id <GSKDocumentImageProcessor> _Nonnull)imageProcessor configuration:(GSKDocumentGeneratorConfiguration * _Nonnull)configuration error:(NSError * _Nullable * _Nullable)error;
/// Generates a document file based on a document model and a generator configuration.
/// \param document The source document to generate as PDF.
///
/// \param configuration The configuration for the document generation.
///
- (BOOL)generate:(GSKPDFDocument * _Nonnull)document configuration:(GSKDocumentGeneratorConfiguration * _Nonnull)configuration error:(NSError * _Nullable * _Nullable)error;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end

enum GSKDocumentGeneratorFileFormat : NSInteger;
@class GSKDocumentGeneratorDebugConfiguration;

/// A configuration for the document generator.
SWIFT_CLASS("_TtC5GSSDK33GSKDocumentGeneratorConfiguration")
@interface GSKDocumentGeneratorConfiguration : NSObject
/// The output file format of the document generator. Must be .pdf or .tif.
@property (nonatomic, readonly) enum GSKDocumentGeneratorFileFormat outputFileFormat;
/// The path where the generated document will be written. The extension will not be validated.
@property (nonatomic, readonly, copy) NSString * _Nonnull outputFilePath;
/// Custom font file used during the PDF generation to embed an invisible text layer.
/// If nil, a default font is used, which only supports Latin languages.
/// Only used when <code>outputFileFormat</code> is <code>.pdf</code>.
@property (nonatomic, readonly, copy) NSString * _Nullable pdfFontFilePath;
/// Generate a PDF/A document
@property (nonatomic, readonly) BOOL shouldGeneratePDFA;
/// An optional debug configuration to help debug PDF generation problems.
/// Don’t use this in production. Default is nil.
@property (nonatomic, readonly, strong) GSKDocumentGeneratorDebugConfiguration * _Nullable debugConfiguration;
- (nonnull instancetype)initWithOutputFileFormat:(enum GSKDocumentGeneratorFileFormat)outputFileFormat outputFilePath:(NSString * _Nonnull)outputFilePath pdfFontFilePath:(NSString * _Nullable)pdfFontFilePath shouldGeneratePDFA:(BOOL)shouldGeneratePDFA debugConfiguration:(GSKDocumentGeneratorDebugConfiguration * _Nullable)debugConfiguration OBJC_DESIGNATED_INITIALIZER;
+ (GSKDocumentGeneratorConfiguration * _Nonnull)pdfConfigurationWithOutputFilePath:(NSString * _Nonnull)outputFilePath SWIFT_WARN_UNUSED_RESULT;
+ (GSKDocumentGeneratorConfiguration * _Nonnull)tiffConfigurationWithOutputFilePath:(NSString * _Nonnull)outputFilePath SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKDocumentGeneratorConfiguration (SWIFT_EXTENSION(GSSDK))
- (nullable instancetype)initWithDictionary:(NSDictionary<NSString *, id> * _Nonnull)dictionary error:(NSError * _Nullable * _Nullable)error;
@end


SWIFT_CLASS("_TtC5GSSDK38GSKDocumentGeneratorDebugConfiguration")
@interface GSKDocumentGeneratorDebugConfiguration : NSObject
/// If true, OCR’ed text will visible on the PDF.
/// Defaults to false. Use this for debug only
@property (nonatomic, readonly) BOOL isOCRTextShownOnPDF;
- (nonnull instancetype)initWithIsOCRTextShownOnPDF:(BOOL)isOCRTextShownOnPDF OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

/// Error raised while generating a multi-page document
typedef SWIFT_ENUM(NSInteger, GSKDocumentGeneratorError, open) {
/// An internal error. Look at logs or contact us for more details.
  GSKDocumentGeneratorErrorInternal SWIFT_COMPILE_NAME("internal") = 0,
/// A provided file wasn’t found.
  GSKDocumentGeneratorErrorFileNotFound SWIFT_COMPILE_NAME("fileNotFound") = 1,
/// The provided password is invalid for use in a PDF file.
  GSKDocumentGeneratorErrorInvalidPassword SWIFT_COMPILE_NAME("invalidPassword") = 2,
/// The provided page size is unsupported for a PDF file.
  GSKDocumentGeneratorErrorInvalidPageSize SWIFT_COMPILE_NAME("invalidPageSize") = 3,
/// There was an error processing the image associated to a document page.
  GSKDocumentGeneratorErrorProcessorError SWIFT_COMPILE_NAME("processorError") = 4,
/// An input to the document generator is invalid.
  GSKDocumentGeneratorErrorInvalidInput SWIFT_COMPILE_NAME("invalidInput") = 5,
};
static NSString * _Nonnull const GSKDocumentGeneratorErrorDomain = @"GSSDK.GSKDocumentGeneratorError";

typedef SWIFT_ENUM(NSInteger, GSKDocumentGeneratorFileFormat, open) {
  GSKDocumentGeneratorFileFormatPDF SWIFT_COMPILE_NAME("pdf") = 0,
  GSKDocumentGeneratorFileFormatTIFF SWIFT_COMPILE_NAME("tiff") = 1,
};


/// Used to preprocess pages of the PDF generation.
/// When you generate a PDF document from images, you may want to apply some preprocessing to each image
/// before inserting them in the document (for instance resizing them, including a watermark, etc.) You can
/// implement your own PDF_image_processor and pass it when generating a PDF document.
/// to achieve this.
SWIFT_PROTOCOL("_TtP5GSSDK25GSKDocumentImageProcessor_")
@protocol GSKDocumentImageProcessor
/// Process the image and return a file path to the
/// updated image. The PDF processor will delete this temporary
/// image afterwards (only if it’s different from inputFilePath)
/// @return nil if there is an error
- (NSString * _Nullable)process:(NSString * _Nonnull)inputFilePath SWIFT_WARN_UNUSED_RESULT;
@end


/// A configuration to specify the background cleaning to apply with GSKScanProcessor.
SWIFT_CLASS("_TtC5GSSDK40GSKFilterBackgroundCleaningConfiguration")
@interface GSKFilterBackgroundCleaningConfiguration : NSObject
/// Determines if the edges of the document must be cleaned or not. Cleaning the edges might result in erasing
/// some information that’s close the edges but yields a much cleaner document.
@property (nonatomic, readonly) GSKEdgeCleaning edgeCleaning;
/// Determines if the document’s background is rather light (white) or dark (black).
@property (nonatomic, readonly) GSKBackgroundKind backgroundKind;
/// Determines if the document is composed mainly of text, or contains a mix of text and photos.
@property (nonatomic, readonly) GSKDocumentComposition documentComposition;
/// Determines the strength of the background cleaning. Value between 0 and 1.
@property (nonatomic, readonly) CGFloat strength;
/// \param edgeCleaning If enabled, the document edges will be cleaned up. This helps if the document is torn or folded in
/// the corners, of if the cropping wasn’t perfectly accurate.
///
/// \param backgroundKind If set to dark, the document is considered as having a dark background, and will be processed
/// consequently.
///
/// \param documentComposition If set to “Text and photo”, indicates that document is a composite of text and photos (such
/// as a magazine page). The filter will be less aggressive to preserve the photos.
///
/// \param strength The strength of the filter, between 0 and 1.
///
- (nonnull instancetype)initWithEdgeCleaning:(GSKEdgeCleaning)edgeCleaning backgroundKind:(GSKBackgroundKind)backgroundKind documentComposition:(GSKDocumentComposition)documentComposition strength:(CGFloat)strength OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKFilterBackgroundCleaningConfiguration (SWIFT_EXTENSION(GSSDK))
@property (nonatomic, readonly, copy) NSString * _Nonnull description;
@end


@interface GSKFilterBackgroundCleaningConfiguration (SWIFT_EXTENSION(GSSDK))
- (BOOL)isEqual:(id _Nullable)object SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly) NSUInteger hash;
@end


/// A configuration to determine the colors of the output of the GSKScanProcessor.
SWIFT_CLASS("_TtC5GSSDK27GSKFilterColorConfiguration")
@interface GSKFilterColorConfiguration : NSObject
/// A configuration that results in a monochrome document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterColorConfiguration * _Nonnull monochrome;)
+ (GSKFilterColorConfiguration * _Nonnull)monochrome SWIFT_WARN_UNUSED_RESULT;
/// A configuration that results in a grayscale document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterColorConfiguration * _Nonnull grayscale;)
+ (GSKFilterColorConfiguration * _Nonnull)grayscale SWIFT_WARN_UNUSED_RESULT;
/// A configuration that results in a color document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterColorConfiguration * _Nonnull color;)
+ (GSKFilterColorConfiguration * _Nonnull)color SWIFT_WARN_UNUSED_RESULT;
/// The palette of colors
@property (nonatomic, readonly) GSKFilterColorPalette palette;
- (nonnull instancetype)initWithPalette:(GSKFilterColorPalette)palette OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKFilterColorConfiguration (SWIFT_EXTENSION(GSSDK))
@property (nonatomic, readonly, copy) NSString * _Nonnull description;
@end


@interface GSKFilterColorConfiguration (SWIFT_EXTENSION(GSSDK))
- (BOOL)isEqual:(id _Nullable)object SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly) NSUInteger hash;
@end

@class GSKFilterLightingCorrectionConfiguration;

/// The configuration to use when applying a document enhancement filter.
SWIFT_CLASS("_TtC5GSSDK22GSKFilterConfiguration")
@interface GSKFilterConfiguration : NSObject
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull noOp;)
+ (GSKFilterConfiguration * _Nonnull)noOp SWIFT_WARN_UNUSED_RESULT;
/// A photo filter configuration (no background cleaning)
/// \param lightingCorrectionConfiguration an optional lighting correction configuration. If nil, no correction is applied.
///
/// \param colorConfiguration an optional color configuration. If nil, the color configuration is used.
///
+ (GSKFilterConfiguration * _Nonnull)photoWithLightingCorrectionConfiguration:(GSKFilterLightingCorrectionConfiguration * _Nullable)lightingCorrectionConfiguration colorConfiguration:(GSKFilterColorConfiguration * _Nullable)colorConfiguration SWIFT_WARN_UNUSED_RESULT;
/// The lighting configuration
/// Determines the parameters to tune the image levels, contrast.
@property (nonatomic, readonly, strong) GSKFilterLightingCorrectionConfiguration * _Nullable lightingCorrectionConfiguration;
/// The background cleaning configuration
/// Determines the cleaning up of the document’s background.
@property (nonatomic, readonly, strong) GSKFilterBackgroundCleaningConfiguration * _Nullable backgroundCleaningConfiguration;
/// The color configuration
/// Determines the filter’s output colors.
@property (nonatomic, readonly, strong) GSKFilterColorConfiguration * _Nullable colorConfiguration;
+ (GSKFilterConfiguration * _Nonnull)configurationWithLightingCorrectionConfiguration:(GSKFilterLightingCorrectionConfiguration * _Nullable)lightingCorrectionConfiguration backgroundCleaningConfiguration:(GSKFilterBackgroundCleaningConfiguration * _Nullable)backgroundCleaningConfiguration colorConfiguration:(GSKFilterColorConfiguration * _Nullable)colorConfiguration SWIFT_WARN_UNUSED_RESULT;
/// A filter configuration.
/// \param lightingCorrectionConfiguration an optional lighting correction configuration. If nil, no correction is applied.
///
/// \param backgroundCleaningConfiguration an optional background cleaning configuration. If nil, no background
/// cleaning is applied.
///
/// \param colorConfiguration an optional color configuration. If nil, the color configuration is used.
///
- (nonnull instancetype)initWithLightingCorrectionConfiguration:(GSKFilterLightingCorrectionConfiguration * _Nullable)lightingCorrectionConfiguration backgroundCleaningConfiguration:(GSKFilterBackgroundCleaningConfiguration * _Nullable)backgroundCleaningConfiguration colorConfiguration:(GSKFilterColorConfiguration * _Nullable)colorConfiguration OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKFilterConfiguration (SWIFT_EXTENSION(GSSDK))
- (BOOL)isEqual:(id _Nullable)object SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly) NSUInteger hash;
@end


@interface GSKFilterConfiguration (SWIFT_EXTENSION(GSSDK))
/// A soft document filter resulting in a grayscale document.
/// This filter is ideal for documents with light print such as carbon copy,
/// documents with pale text that you need to preserve, or documents where the
/// text has little contrast with the background.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull softGrayscale;)
+ (GSKFilterConfiguration * _Nonnull)softGrayscale SWIFT_WARN_UNUSED_RESULT;
/// A soft document filter resulting in a color document.
/// This filter is ideal for documents that mix text and images and it also preserves
/// text with low contrast.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull softColor;)
+ (GSKFilterConfiguration * _Nonnull)softColor SWIFT_WARN_UNUSED_RESULT;
/// A strong document filter resulting in a monochrome document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull strongMonochrome;)
+ (GSKFilterConfiguration * _Nonnull)strongMonochrome SWIFT_WARN_UNUSED_RESULT;
/// A strong document filter resulting in a grayscale document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull strongGrayscale;)
+ (GSKFilterConfiguration * _Nonnull)strongGrayscale SWIFT_WARN_UNUSED_RESULT;
/// A strong document filter resulting in a color document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull strongColor;)
+ (GSKFilterConfiguration * _Nonnull)strongColor SWIFT_WARN_UNUSED_RESULT;
/// A filter specially designed for photos.
/// Unlike document filters, this filter will not attempt any background cleaning but will
/// slightly improve the lighting of the image.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull photo;)
+ (GSKFilterConfiguration * _Nonnull)photo SWIFT_WARN_UNUSED_RESULT;
/// A filter specially designed to treat documents with a dark background, in particular white text
/// over a black background.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterConfiguration * _Nonnull darkBackground;)
+ (GSKFilterConfiguration * _Nonnull)darkBackground SWIFT_WARN_UNUSED_RESULT;
@end


/// A configuration to adjust the lighting of a document with GSKScanProcessor.
SWIFT_CLASS("_TtC5GSSDK40GSKFilterLightingCorrectionConfiguration")
@interface GSKFilterLightingCorrectionConfiguration : NSObject
/// A configuration that doesn’t adjust the lighting of a document.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterLightingCorrectionConfiguration * _Nonnull noOp;)
+ (GSKFilterLightingCorrectionConfiguration * _Nonnull)noOp SWIFT_WARN_UNUSED_RESULT;
/// A configuration to adjust the lighting of document containing text.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterLightingCorrectionConfiguration * _Nonnull textDocument;)
+ (GSKFilterLightingCorrectionConfiguration * _Nonnull)textDocument SWIFT_WARN_UNUSED_RESULT;
/// A configuration to adjust the lighting of a document looking like a photo.
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKFilterLightingCorrectionConfiguration * _Nonnull photos;)
+ (GSKFilterLightingCorrectionConfiguration * _Nonnull)photos SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly) CGFloat minThreshold;
@property (nonatomic, readonly) CGFloat maxThreshold;
- (nonnull instancetype)initWithMinThreshold:(CGFloat)minThreshold maxThreshold:(CGFloat)maxThreshold OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKFilterLightingCorrectionConfiguration (SWIFT_EXTENSION(GSSDK))
@property (nonatomic, readonly, copy) NSString * _Nonnull description;
@end


@interface GSKFilterLightingCorrectionConfiguration (SWIFT_EXTENSION(GSSDK))
- (BOOL)isEqual:(id _Nullable)object SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly) NSUInteger hash;
@end




/// A document image processor that performs no operation and returns the input file as an output
SWIFT_CLASS("_TtC5GSSDK29GSKNoopDocumentImageProcessor")
@interface GSKNoopDocumentImageProcessor : NSObject <GSKDocumentImageProcessor>
- (NSString * _Nullable)process:(NSString * _Nonnull)inputFilePath SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end

@protocol GSKLogger;
@class GSKOCRConfiguration;
@class GSKOCRResult;

/// A type that performs Optical Character Recognition (OCR) on a scanned document.
SWIFT_CLASS("_TtC5GSSDK6GSKOCR")
@interface GSKOCR : NSObject
- (nonnull instancetype)initWithLogger:(id <GSKLogger> _Nonnull)logger OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init;
/// Recognize the text in the provided image
/// \param imagePath The path of the image to recognize. Ideally, provide the original, cropped image, and not the enhanced image.
/// The OCR decides what post-processing to apply for the best results.
///
/// \param configuration Configuration for the OCR process, in particular the language in which the OCR is
/// performed. Note that you must provided the appropriate trained data.
///
/// \param progressBlock The progress between 0 and 1. Called on the same thread.
///
///
/// returns:
/// An OCR result.
- (void)recognizeTextForImageAtPath:(NSString * _Nonnull)imagePath ocrConfiguration:(GSKOCRConfiguration * _Nonnull)configuration onProgress:(void (^ _Nullable)(float))progressBlock completionHandler:(void (^ _Nonnull)(GSKOCRResult * _Nullable, NSError * _Nullable))completionHandler;
@end


/// The configuration for an OCR operation.
SWIFT_CLASS("_TtC5GSSDK19GSKOCRConfiguration")
@interface GSKOCRConfiguration : NSObject
/// Initialize an OCR configuration for the modern OCR engine.
/// \param languageTags The language codes to perform OCR with.
///
+ (GSKOCRConfiguration * _Nonnull)configurationWithLanguageTags:(NSArray<NSString *> * _Nonnull)languageTags SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

@class GSKTextLayout;

/// The results of an OCR operation
SWIFT_CLASS("_TtC5GSSDK12GSKOCRResult")
@interface GSKOCRResult : NSObject
/// The recognized text, formatted.
@property (nonatomic, readonly, copy) NSString * _Nonnull text;
/// The recognized text, as a structured text layout.
@property (nonatomic, readonly, strong) GSKTextLayout * _Nonnull textLayout;
- (nonnull instancetype)initWithText:(NSString * _Nonnull)text textLayout:(GSKTextLayout * _Nonnull)textLayout;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

@class NSDate;
@class GSKPDFPage;

/// Describes the structure of a PDF document for the PDF generator.
SWIFT_CLASS("_TtC5GSSDK14GSKPDFDocument")
@interface GSKPDFDocument : NSObject
/// If provided, this title will be included in the PDF document properties
@property (nonatomic, readonly, copy) NSString * _Nullable title;
/// If provided, this password will be used to protect the PDF document.
/// It will need to be entered to view or edit the document.
/// RC4 encryption algorithm is used with a 128-bit key.
@property (nonatomic, readonly, copy) NSString * _Nullable password;
/// If provided, the keywords will be included in the PDF document properties
@property (nonatomic, readonly, copy) NSString * _Nullable keywords;
/// If provided, this date will be included in the PDF document properties
@property (nonatomic, readonly, copy) NSDate * _Nullable creationDate;
/// If provided, this date will be included in the PDF document properties
@property (nonatomic, readonly, copy) NSDate * _Nullable lastUpdateDate;
/// List of pages that will be included in the PDF document
@property (nonatomic, readonly, copy) NSArray<GSKPDFPage *> * _Nonnull pages;
- (nonnull instancetype)initWithTitle:(NSString * _Nullable)title password:(NSString * _Nullable)password keywords:(NSString * _Nullable)keywords creationDate:(NSDate * _Nullable)creationDate lastUpdate:(NSDate * _Nullable)lastUpdate pages:(NSArray<GSKPDFPage *> * _Nonnull)pages OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@interface GSKPDFDocument (SWIFT_EXTENSION(GSSDK))
/// Initialize a GSKPDFDocument with a dictionary.
/// This is used for Genius Scan SDK’s cross-platform plugins integration and shouldn’t be relied on.
- (nullable instancetype)initWithDictionary:(NSDictionary<NSString *, id> * _Nonnull)dictionary error:(NSError * _Nullable * _Nullable)error;
@end

@class GSKPDFSize;

/// Describes a page of a PDF document for the PDF generator.
SWIFT_CLASS("_TtC5GSSDK10GSKPDFPage")
@interface GSKPDFPage : NSObject
@property (nonatomic, readonly, copy) NSString * _Nonnull filePath;
@property (nonatomic, readonly, strong) GSKPDFSize * _Nonnull inchesSize;
@property (nonatomic, readonly, strong) GSKTextLayout * _Nullable textLayout;
- (nonnull instancetype)initWithFilePath:(NSString * _Nonnull)filePath inchesSize:(GSKPDFSize * _Nonnull)inchesSize textLayout:(GSKTextLayout * _Nullable)textLayout OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


/// Physical size of a PDF page in inches.
/// If the aspect ratio doesn’t match the aspect ratio of the page in pixels,
/// margins will be added on both sides of the page image.
/// If 0 is provided for the width or height, it is computed to match the aspect ratio
/// of the image. Eg, for a receipt, we usually use width = 3.54f and height = 0.
SWIFT_CLASS("_TtC5GSSDK10GSKPDFSize")
@interface GSKPDFSize : NSObject
@property (nonatomic, readonly) double width;
@property (nonatomic, readonly) double height;
- (nonnull instancetype)initWithWidth:(double)width height:(double)height OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

typedef SWIFT_ENUM(NSInteger, GSKReceiptCategory, open) {
  GSKReceiptCategoryGas = 0,
  GSKReceiptCategoryTransportation = 1,
  GSKReceiptCategoryAccomodation = 2,
  GSKReceiptCategoryRestaurant = 3,
  GSKReceiptCategorySupermarket = 4,
  GSKReceiptCategoryOther = 5,
};


/// A VAT rate and its associated amount detected on a receipt.
SWIFT_CLASS("_TtC5GSSDK13GSKReceiptVAT")
@interface GSKReceiptVAT : NSObject
- (BOOL)isEqual:(id _Nullable)object SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

@class GSKScanFlowConfiguration;

/// A high-level scanner module.
/// You present it and when the user is done, you obtain a result object containing the scanned documents.
/// The scan flow can be customized with a <code>GSKScanFlowConfiguration</code> instance.
SWIFT_CLASS("_TtC5GSSDK11GSKScanFlow")
@interface GSKScanFlow : NSObject
- (nonnull instancetype)initWithConfiguration:(GSKScanFlowConfiguration * _Nonnull)configuration OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

@class GSKScanFlowResult;

@interface GSKScanFlow (SWIFT_EXTENSION(GSSDK))
/// Instantiates a <code>GSKScanFlow</code> instance with the provided configuration.
/// This initializer is only available from Objective-C.
+ (nonnull instancetype)scanFlowWithConfiguration:(GSKScanFlowConfiguration * _Nonnull)configuration SWIFT_WARN_UNUSED_RESULT;
/// Present the scan flow.
/// @param viewController The view controller to present the scan flow from.
/// @param completionBlock A completion block/closure that will be called on the main
/// thread upon completion of the scan flow. It receives a <code>GSKScanFlowResult</code> object as
/// a parameter. This object gives you access to the scanned documents.
/// @param errorBlock A block/closure called if an error was encountered.
- (void)startFromViewController:(UIViewController * _Nonnull)viewController onSuccess:(void (^ _Nonnull)(GSKScanFlowResult * _Nonnull))completionBlock failure:(void (^ _Nonnull)(NSError * _Nonnull))errorBlock;
@end


enum GSKScanFlowSource : NSUInteger;
@class NSURL;
enum GSKScanOrientation : NSInteger;
enum GSKScanFlowFilterType : NSInteger;
enum GSKScanFlowPDFPageSize : NSUInteger;
enum GSKScanFlowFlashMode : NSUInteger;
enum GSKScanFlowMultiPageFormat : NSUInteger;
@class UIColor;
@class GSKScanFlowOCRConfiguration;

/// Enables configuration of a <code>GSKScanFlow</code> instance.
/// Pass an instance of this class to the initializer of <code>GSKScanFlow</code>
/// to build the desired scan flow.
SWIFT_CLASS("_TtC5GSSDK24GSKScanFlowConfiguration")
@interface GSKScanFlowConfiguration : NSObject
/// Specifies the source for the scanned documents (eg. the camera, …).
/// If source is <code>.imageURL</code>, then you must assign a <code>sourceImageURL</code>.
@property (nonatomic) enum GSKScanFlowSource source;
/// The image URL if the <code>source</code> is <code>.imageURL</code>.
@property (nonatomic, copy) NSURL * _Nullable sourceImageURL;
/// Whether multi page mode should be used. Only applies when the source
/// is <code>.camera</code>. When multipage mode is active, the user will have the
/// opportunity to snap multiple scans in a row and the output document
/// will contain all those pages. When multipage mode is off, the user
/// will only scan a single page. The output document will always contain
/// a single page. Defaults to <code>true</code>.
@property (nonatomic) BOOL multiPage;
/// What orientation that a scan should be rotated to after it’s been captured.
/// Defaults to <code>automatic</code>. See <code>GSKScanOrientation</code> for more information.
@property (nonatomic) enum GSKScanOrientation defaultScanOrientation;
/// Any specific kind of post-processing to use. Defaults to <code>.automatic</code>.
@property (nonatomic) enum GSKScanFlowFilterType defaultFilter;
/// The minimum readability level that scanned documents are required to have. If a scan has a lower
/// readability level, then a warning will be shown as part of the scanning flow, and the user will be
/// prompted to retry the scan in question.
@property (nonatomic) GSKReadabilityLevel requiredReadabilityLevel;
/// Whether to skip showing the post-processing screen. We only recommend
/// enabling this option when scanning structured data. Generally, you want
/// the user to visually confirm the quality of each scan.
@property (nonatomic) BOOL skipPostProcessingScreen;
/// Select which actions to display within the post-processing screen.
/// Defaults to all actions.
@property (nonatomic) GSKScanFlowPostProcessingActions postProcessingActions;
/// Determines the size of the pages when generating PDFs. Defaults to <code>fit</code>.
@property (nonatomic) enum GSKScanFlowPDFPageSize pdfPageSize;
/// Whether the flash button should be hidden. Defaults to <code>false</code>.
@property (nonatomic) BOOL flashButtonHidden;
/// Whether the photo library button should be hidden during camera-based scan flows. Defaults to <code>false</code>.
@property (nonatomic) BOOL photoLibraryButtonHidden;
/// Determines the default flash mode. Combine this with <code>flashButtonHidden</code>
/// if you want to only allow a specific flash mode. Defaults to <code>.auto</code>.
@property (nonatomic) enum GSKScanFlowFlashMode defaultFlashMode;
/// Determines the document format. Defaults to <code>.PDF</code>.
@property (nonatomic) enum GSKScanFlowMultiPageFormat multiPageFormat;
/// Custom font file used during PDF generation to embed an invisible text
/// layer. If <code>nil</code>, a default font is used, which only supports Latin languages.
@property (nonatomic, copy) NSURL * _Nullable pdfFontFileURL;
/// The background color used for the UI. Defaults to <code>.black</code>.
@property (nonatomic, strong) UIColor * _Nonnull backgroundColor;
/// The foreground color used for the UI (text and icons). Defaults to <code>.white</code>.
@property (nonatomic, strong) UIColor * _Nonnull foregroundColor;
/// The highlight color used for the UI (document detection overlay). Defaults
/// to <code>.blue</code>.
@property (nonatomic, strong) UIColor * _Nonnull highlightColor;
/// The menu color used for the UI. Defaults to <code>nil</code>, meaning that the system
/// default color will be used (blue on iOS, for example).
@property (nonatomic, strong) UIColor * _Nullable menuColor;
/// JPEG quality used to compress captured images. Between 0 and 100, with 100
/// being the best quality. Defaults to <code>60</code>.
@property (nonatomic) NSInteger jpegQuality;
/// Max scan dimension in pixels when generating PDF files. All scans included
/// in PDF files will be scaled so that both their height and width are smaller
/// than this value, while maintaining their aspect ratio. Defaults to <code>0</code>, which
/// means no scaling is applied.
@property (nonatomic) NSInteger pdfMaxScanDimension;
/// The configuration for Optical Character Recognition. Default is <code>nil</code>, which
/// means no OCR is performed.
@property (nonatomic, strong) GSKScanFlowOCRConfiguration * _Nullable ocrConfiguration;
/// The types of structured data you want to extract from the document. This is
/// an option set so you can combine multiple values.
@property (nonatomic) GSKScanFlowStructuredData structuredData;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end



@interface GSKScanFlowConfiguration (SWIFT_EXTENSION(GSSDK))
/// Create a configuration from a dictionary.
/// This is particularly useful for interfacing with React Native but shouldn’t
/// be used in native projects.
+ (nullable instancetype)configurationWithDictionary:(NSDictionary * _Nonnull)dictionary error:(NSError * _Nullable * _Nullable)error SWIFT_WARN_UNUSED_RESULT;
@end



@interface GSKScanFlowConfiguration (SWIFT_EXTENSION(GSSDK))
- (BOOL)validate:(NSError * _Nullable * _Nullable)error;
@end

/// Enum that defines various errors that can occur during a scan flow.
typedef SWIFT_ENUM(NSInteger, GSKScanFlowError, open) {
/// User has canceled the scan flow
  GSKScanFlowUserCancelationError SWIFT_COMPILE_NAME("userCancellation") = 999,
/// A general error due to a bad input parameter. Verify that your
/// inputs match the API requirements.
  GSKScanFlowBadInputError SWIFT_COMPILE_NAME("badInput") = 1000,
};

/// The different possible filters for the scanner UI.
/// All cases match <code>GSKFilterType</code> values except <code>.automatic</code>.
typedef SWIFT_ENUM(NSInteger, GSKScanFlowFilterType, open) {
  GSKScanFlowFilterNone SWIFT_COMPILE_NAME("none") = 0,
/// Automatic filter
  GSKScanFlowFilterAutomatic SWIFT_COMPILE_NAME("automatic") = 1,
/// Automatic filter with a monochrome output
  GSKScanFlowFilterAutomaticDocumentMonochrome SWIFT_COMPILE_NAME("automaticDocumentMonochrome") = 2,
/// Automatic filter with a grayscale output
  GSKScanFlowFilterAutomaticDocumentGrayscale SWIFT_COMPILE_NAME("automaticDocumentGrayscale") = 3,
/// Automatic filter with a color output
  GSKScanFlowFilterAutomaticDocumentColor SWIFT_COMPILE_NAME("automaticDocumentColor") = 4,
/// A soft gray scale filter, ideal for documents containing both text and photos, or for text documents with
/// a low-contrast between the text and the background.
  GSKScanFlowFilterSoftGrayscale SWIFT_COMPILE_NAME("softGrayscale") = 5,
/// A soft color filter, ideal for documents containing both text and photos
  GSKScanFlowFilterSoftColor SWIFT_COMPILE_NAME("softColor") = 6,
/// A strong monochrome filter, ideal for text documents
  GSKScanFlowFilterStrongMonochrome SWIFT_COMPILE_NAME("strongMonochrome") = 7,
/// A strong grayscale filter, ideal for text documents
  GSKScanFlowFilterStrongGrayscale SWIFT_COMPILE_NAME("strongGrayscale") = 8,
/// A strong color filter, ideal for text documents with some color
  GSKScanFlowFilterStrongColor SWIFT_COMPILE_NAME("strongColor") = 9,
/// A filter that ensures best results for documents with a dark background
  GSKScanFlowFilterDarkBackground SWIFT_COMPILE_NAME("darkBackground") = 10,
/// A filter designed to improve scans of photos.
  GSKScanFlowFilterPhoto SWIFT_COMPILE_NAME("photo") = 11,
};

/// The capture screen flash mode.
typedef SWIFT_ENUM(NSUInteger, GSKScanFlowFlashMode, open) {
/// Let the system determine whether to turn on the flash based on the lighting conditions.
  GSKScanFlowFlashModeAuto = 0,
/// Force the flash on.
  GSKScanFlowFlashModeOn = 1,
/// Force the flash off.
  GSKScanFlowFlashModeOff = 2,
};

/// The format of the exported document.
typedef SWIFT_ENUM(NSUInteger, GSKScanFlowMultiPageFormat, open) {
  GSKScanFlowNone SWIFT_COMPILE_NAME("none") = 0,
  GSKScanFlowPDF SWIFT_COMPILE_NAME("PDF") = 1,
  GSKScanFlowTIFF SWIFT_COMPILE_NAME("TIFF") = 2,
};


/// The configuration for text recognition
SWIFT_CLASS("_TtC5GSSDK27GSKScanFlowOCRConfiguration")
@interface GSKScanFlowOCRConfiguration : NSObject
/// The BCP47 language tags to process OCR with.
@property (nonatomic, copy) NSArray<NSString *> * _Nonnull languageTags;
/// The formats in which the OCR result is made available in
/// the ScanFlow result. Defaults to all formats.
@property (nonatomic) GSKScanFlowOCROutputFormats outputFormats;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end





/// The result of the text recognition.
SWIFT_CLASS("_TtC5GSSDK20GSKScanFlowOCRResult")
@interface GSKScanFlowOCRResult : NSObject
/// The raw text recognized in the document.
@property (nonatomic, copy) NSString * _Nullable text;
/// The text layout of the recognized text.
@property (nonatomic, copy) NSString * _Nullable hocrTextLayout;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end



/// The generated PDF paper size.
typedef SWIFT_ENUM(NSUInteger, GSKScanFlowPDFPageSize, open) {
/// PDF page with a width of 8.27 inch (A4 width) and fitting height.
  GSKScanFlowPDFPageFit SWIFT_COMPILE_NAME("fit") = 0,
/// ISO A4 (21cm x 29.7cm).
  GSKScanFlowPDFPageA4 SWIFT_COMPILE_NAME("A4") = 1,
/// US Letter (8.5in x 11in).
  GSKScanFlowPDFPageLetter SWIFT_COMPILE_NAME("letter") = 2,
};

@class GSKScanFlowScan;

/// The result of a scan flow.
SWIFT_CLASS("_TtC5GSSDK17GSKScanFlowResult")
@interface GSKScanFlowResult : NSObject
/// Document containing the pages that were scanned during the scan
/// flow. The format is specified by <code>multiPageFormat</code> property of
/// the used <code>GSKScanFlowConfiguration</code>. Is <code>nil</code> if no format was
/// specified or if generation failed.
@property (nonatomic, copy) NSURL * _Nullable multiPageDocumentURL;
/// The individual scans taken during the scan flow.
/// Each scan object contains both the original and the enhanced scans.
@property (nonatomic, copy) NSArray<GSKScanFlowScan *> * _Nonnull scans;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end


@interface GSKScanFlowResult (SWIFT_EXTENSION(GSSDK))
/// A dictionary representation of the result.
/// Convenient for interfacing with React Native, probably no reason to
/// use it with native code.
@property (nonatomic, readonly, copy) NSDictionary<NSString *, id> * _Nonnull dictionary;
@end

@class GSKScanFlowStructuredDataResult;

/// A page captured by the scan flow.
SWIFT_CLASS("_TtC5GSSDK15GSKScanFlowScan")
@interface GSKScanFlowScan : NSObject
/// The original JPEG out of the camera.
/// Note that this image might be rotated, and needs to be read
/// with its EXIF orientation to be properly displayed. <code>UIImage</code>
/// methods will properly take care of that.
@property (nonatomic, copy) NSString * _Nonnull originalFilePath;
/// The enhanced, processed, image.
@property (nonatomic, copy) NSString * _Nonnull enhancedFilePath;
/// If OCR was performed, the recognized text.
@property (nonatomic, strong) GSKScanFlowOCRResult * _Nullable ocrResult;
/// If structured data extraction was performed, the structured data.
@property (nonatomic, strong) GSKScanFlowStructuredDataResult * _Nullable structuredDataResult;
- (nonnull instancetype)initWithOriginalFilePath:(NSString * _Nonnull)originalFilePath enhancedFilePath:(NSString * _Nonnull)enhancedFilePath OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


/// The source for a scan flow
typedef SWIFT_ENUM(NSUInteger, GSKScanFlowSource, open) {
/// Scan using the camera
  GSKScanFlowSourceCamera = 0,
/// Import a file from a URL
  GSKScanFlowSourceImageURL = 1,
/// Import a file from the user’s photo library
  GSKScanFlowSourceLibrary = 2,
};

@class GSKStructuredDataBankDetails;
@class GSKStructuredDataContact;
@class GSKStructuredDataReceipt;

/// The result of a structured data extraction.
SWIFT_CLASS("_TtC5GSSDK31GSKScanFlowStructuredDataResult")
@interface GSKScanFlowStructuredDataResult : NSObject
/// Present if bank details extraction was requested, <code>nil</code> otherwise.
@property (nonatomic, strong) GSKStructuredDataBankDetails * _Nullable bankDetails;
/// Present if business card contact extraction was requested and a contact was
/// successfully extracted, <code>nil</code> otherwise.
@property (nonatomic, strong) GSKStructuredDataContact * _Nullable businessCardContact;
/// Present if receipt extraction was requested and a receipt/invoice was
/// successfully extracted, <code>nil</code> otherwise.
@property (nonatomic, strong) GSKStructuredDataReceipt * _Nullable receipt;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end


/// Enum that describes how a document should be oriented/rotated
/// after it’s been captured.
typedef SWIFT_ENUM(NSInteger, GSKScanOrientation, open) {
/// The document’s original orientation should be used. No rotation
/// should be applied.
  GSKScanOrientationOriginal = 0,
/// The document should be automatically rotated to its ideal orientation.
  GSKScanOrientationAutomatic = 1,
};


/// Address data extracted from a business card document through OCR.
SWIFT_CLASS("_TtC5GSSDK24GSKStructuredDataAddress")
@interface GSKStructuredDataAddress : NSObject
/// The city component of the address.
@property (nonatomic, readonly, copy) NSString * _Nullable city;
/// The postal/zip code component of the address.
@property (nonatomic, readonly, copy) NSString * _Nullable postalCode;
/// The street name component of the address.
@property (nonatomic, readonly, copy) NSString * _Nullable street;
/// The state component of the address.
@property (nonatomic, readonly, copy) NSString * _Nullable state;
/// The country component of the address.
@property (nonatomic, readonly, copy) NSString * _Nullable country;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end



/// The bank details extracted from a document through OCR.
SWIFT_CLASS("_TtC5GSSDK28GSKStructuredDataBankDetails")
@interface GSKStructuredDataBankDetails : NSObject
/// The IBAN if successfully extracted, otherwise is <code>nil</code>.
@property (nonatomic, copy) NSString * _Nullable iban;
/// The BIC code if successfully extracted, otherwise is <code>nil</code>.
@property (nonatomic, copy) NSString * _Nullable bic;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@class GSKStructuredDataPhoneNumber;
@class CNContact;

/// Contact data extracted from a business card document through OCR.
SWIFT_CLASS("_TtC5GSSDK24GSKStructuredDataContact")
@interface GSKStructuredDataContact : NSObject
/// Any name that appears on the business card. Contains the full name, including all components.
@property (nonatomic, readonly, copy) NSString * _Nullable name;
/// Any organization that appears on the business card.
@property (nonatomic, readonly, copy) NSString * _Nullable organization;
/// Any address that appears on the business card.
@property (nonatomic, readonly, strong) GSKStructuredDataAddress * _Nullable address;
/// The phone numbers that appear on the business card.
@property (nonatomic, readonly, copy) NSArray<GSKStructuredDataPhoneNumber *> * _Nonnull phoneNumbers;
/// The links/URLs that appear on the business card.
@property (nonatomic, readonly, copy) NSArray<NSURL *> * _Nonnull links;
/// The email addresses that appear on the business card.
@property (nonatomic, readonly, copy) NSArray<NSString *> * _Nonnull emailAddresses;
/// Return a <code>CNContact</code> representation of the contact data within this instance.
- (CNContact * _Nonnull)asCNContact SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end



/// Class that enables structured data to be extracted from
/// scanned documents.
SWIFT_CLASS("_TtC5GSSDK26GSKStructuredDataExtractor")
@interface GSKStructuredDataExtractor : NSObject
- (nonnull instancetype)init;
@end



@interface GSKStructuredDataExtractor (SWIFT_EXTENSION(GSSDK))
/// Extract any bank details that were found in a given document by
/// passing in the result of performing OCR on that document. Use
/// <code>GSKOCR</code> to obtain a <code>GSKOCRResult</code> instance. Note that if OCR
/// was performed for languages that don’t support structured data extraction,
/// then this method will throw an error.
- (void)bankDetailsFromOCRResult:(GSKOCRResult * _Nonnull)ocrResult completionHandler:(void (^ _Nonnull)(GSKStructuredDataBankDetails * _Nullable, NSError * _Nullable))completionHandler;
/// Extract any business card contact that was found in a given document
/// by passing in the result of performing OCR on that document. Use
/// <code>GSKOCR</code> to obtain a <code>GSKOCRResult</code> instance. Note that if OCR
/// was performed for languages that don’t support structured data extraction,
/// then this method will throw an error.
- (void)businessCardContactFromOCRResult:(GSKOCRResult * _Nonnull)ocrResult completionHandler:(void (^ _Nonnull)(GSKStructuredDataContact * _Nullable, NSError * _Nullable))completionHandler;
/// Extract any receipt/invoice information that was found in a given
/// document by passing in the result of performing OCR on that document.
/// Use <code>GSKOCR</code> to obtain a <code>GSKOCRResult</code> instance. Note that if OCR
/// was performed for languages that don’t support structured data extraction,
/// then this method will throw an error.
- (void)receiptFromOCRResult:(GSKOCRResult * _Nonnull)ocrResult completionHandler:(void (^ _Nonnull)(GSKStructuredDataReceipt * _Nullable, NSError * _Nullable))completionHandler;
@end

/// Enum defining errors that can be thrown by <code>GSKStructuredDataExtractor</code>.
/// Note that thrown errors will be wrapped in <code>NSError</code> containers.
typedef SWIFT_ENUM(NSInteger, GSKStructuredDataExtractorError, open) {
  GSKStructuredDataExtractorErrorMissingRequiredOCRMetadata = -1,
};
static NSString * _Nonnull const GSKStructuredDataExtractorErrorDomain = @"GSSDK.GSKStructuredDataExtractorError";


/// Phone number data extracted from a business card document through OCR.
SWIFT_CLASS("_TtC5GSSDK28GSKStructuredDataPhoneNumber")
@interface GSKStructuredDataPhoneNumber : NSObject
/// The label of the phone number. For example “Main”, “Office”, etc.
@property (nonatomic, readonly, copy) NSString * _Nonnull label;
/// A string representation of the phone number itself.
@property (nonatomic, readonly, copy) NSString * _Nonnull number;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


@class NSLocale;

/// Receipt/invoice details extracted from a document through OCR.
SWIFT_CLASS("_TtC5GSSDK24GSKStructuredDataReceipt")
@interface GSKStructuredDataReceipt : NSObject
/// The locale that the receipt is in, if successfully extracted, otherwise <code>nil</code>.
@property (nonatomic, readonly, copy) NSLocale * _Nullable locale;
/// The merchant that the receipt is from, if successfully extracted, otherwise <code>nil</code>.
@property (nonatomic, readonly, copy) NSString * _Nullable merchant;
/// The code of currency that the receipt is in, if successfully extracted, otherwise <code>nil</code>.
@property (nonatomic, readonly, copy) NSString * _Nullable currency;
/// Any date that appears on the receipt, if successfully extracted, otherwise <code>nil</code>.
@property (nonatomic, readonly, copy) NSDate * _Nullable date;
/// The VAT number of the merchant, if successfully extracted, otherwise <code>nil</code>.
@property (nonatomic, readonly, copy) NSString * _Nullable vatNumber;
/// The value-added tax (VAT) details.
/// This property is an array because a receipt may display multiple VAT rates applying to different items
@property (nonatomic, readonly, copy) NSArray<GSKReceiptVAT *> * _Nonnull vatValues;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end



SWIFT_CLASS("_TtC5GSSDK13GSKTextLayout")
@interface GSKTextLayout : NSObject
@property (nonatomic, readonly, copy) NSString * _Nullable hocr;
- (nonnull instancetype)initWithHocr:(NSString * _Nullable)hocr OBJC_DESIGNATED_INITIALIZER;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end

@class GSKTextLayoutToTextConverterResult;

SWIFT_CLASS("_TtC5GSSDK28GSKTextLayoutToTextConverter")
@interface GSKTextLayoutToTextConverter : NSObject
- (GSKTextLayoutToTextConverterResult * _Nullable)convert:(GSKTextLayout * _Nonnull)textLayout error:(NSError * _Nullable * _Nullable)error SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end


SWIFT_CLASS("_TtC5GSSDK34GSKTextLayoutToTextConverterResult")
@interface GSKTextLayoutToTextConverterResult : NSObject
/// The text reconstructed from the text layout.
@property (nonatomic, readonly, copy) NSString * _Nonnull text;
/// The average word confidence of the recognized text.
/// A value between 0 and 100
@property (nonatomic, readonly) NSInteger averageWordConfidence;
/// The number of words in the recognized text.
/// This is the number of words on which the average word confidence has been computed.
@property (nonatomic, readonly) NSInteger wordCount;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
@end


SWIFT_CLASS("_TtC5GSSDK25GSKUIBackgroundProcessing")
@interface GSKUIBackgroundProcessing : NSObject
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) GSKUIBackgroundProcessing * _Nonnull shared;)
+ (GSKUIBackgroundProcessing * _Nonnull)shared SWIFT_WARN_UNUSED_RESULT;
@property (nonatomic, readonly, strong) dispatch_queue_t _Nonnull documentGenerationQueue;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end



@interface GSKView (SWIFT_EXTENSION(GSSDK))
- (void)startSearchAnimation;
- (void)startSnapAnimationWithDuration:(NSTimeInterval)duration;
- (void)endSnapAnimation;
@end


SWIFT_CLASS("_TtC5GSSDK14GSSDKResources")
@interface GSSDKResources : NSObject
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSBundle * _Nonnull bundle;)
+ (NSBundle * _Nonnull)bundle SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
@end










@interface UIViewController (SWIFT_EXTENSION(GSSDK))
/// Return a status bar style appropriate for this view controller
/// based on the contrast between the status bar’s contents and the
/// view controller’s background color.
@property (nonatomic, readonly) UIStatusBarStyle gsk_statusBarStyleBasedOnContrast;
/// Return the interface orientations that this view controller
/// should support based on the current device.
@property (nonatomic, readonly) UIInterfaceOrientationMask gsk_supportedInterfaceOrientations;
@end


#endif
#if __has_attribute(external_source_symbol)
# pragma clang attribute pop
#endif
#if defined(__cplusplus)
#endif
#pragma clang diagnostic pop
#endif

#else
#error unsupported Swift architecture
#endif
