@rdlabo/capacitor-brotherprint 0.0.2 → 2.0.0-0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +97 -0
- package/RdlaboCapacitorBrotherprint.podspec +8 -2
- package/android/.gradle/5.6.4/executionHistory/executionHistory.bin +0 -0
- package/android/.gradle/5.6.4/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/5.6.4/fileChanges/last-build.bin +0 -0
- package/android/.gradle/5.6.4/fileContent/fileContent.lock +0 -0
- package/android/.gradle/5.6.4/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/5.6.4/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/5.6.4/fileHashes/resourceHashesCache.bin +0 -0
- package/android/.gradle/5.6.4/gc.properties +0 -0
- package/android/.gradle/5.6.4/javaCompile/classAnalysis.bin +0 -0
- package/android/.gradle/5.6.4/javaCompile/jarAnalysis.bin +0 -0
- package/android/.gradle/5.6.4/javaCompile/javaCompile.lock +0 -0
- package/android/.gradle/5.6.4/javaCompile/taskHistory.bin +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/caches/build_file_checksums.ser +0 -0
- package/android/.idea/codeStyles/Project.xml +116 -0
- package/android/.idea/gradle.xml +22 -0
- package/android/.idea/jarRepositories.xml +30 -0
- package/android/.idea/libraries/Gradle__androidx_activity_activity_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_annotation_annotation_1_1_0_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_appcompat_appcompat_1_1_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_appcompat_appcompat_resources_1_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_arch_core_core_common_2_1_0_jar.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_arch_core_core_runtime_2_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_browser_browser_1_2_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_cardview_cardview_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_collection_collection_1_1_0_jar.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_coordinatorlayout_coordinatorlayout_1_1_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_core_core_1_2_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_cursoradapter_cursoradapter_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_customview_customview_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_documentfile_documentfile_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_drawerlayout_drawerlayout_1_0_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_exifinterface_exifinterface_1_2_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_fragment_fragment_1_1_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_interpolator_interpolator_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_legacy_legacy_support_core_utils_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_common_2_1_0_jar.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_2_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_core_2_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_runtime_2_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_viewmodel_2_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_loader_loader_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_localbroadcastmanager_localbroadcastmanager_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_print_print_1_0_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_recyclerview_recyclerview_1_1_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_savedstate_savedstate_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_test_core_1_2_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_test_espresso_espresso_core_3_2_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_test_espresso_espresso_idling_resource_3_2_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_test_ext_junit_1_1_1_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_test_monitor_1_2_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_test_runner_1_2_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__androidx_transition_transition_1_2_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_1_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_animated_1_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_versionedparcelable_versionedparcelable_1_1_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__androidx_viewpager2_viewpager2_1_0_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__androidx_viewpager_viewpager_1_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__artifacts_BrotherPrintLibrary_unspecified_jar.xml +11 -0
- package/android/.idea/libraries/Gradle__com_google_android_datatransport_transport_api_2_2_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_android_datatransport_transport_backend_cct_2_2_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_android_datatransport_transport_runtime_2_2_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_base_17_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_basement_17_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_location_17_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_places_placereport_17_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_stats_17_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_tasks_17_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_android_material_material_1_1_0_rc02_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_google_auto_value_auto_value_annotations_1_6_5_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__com_google_code_findbugs_jsr305_2_0_1_jar.xml +9 -0
- package/android/.idea/libraries/Gradle__com_google_dagger_dagger_2_24_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_common_19_3_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_components_16_0_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_datatransport_17_0_3_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_encoders_json_16_0_0_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_iid_20_1_1_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_iid_interop_17_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_installations_16_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_installations_interop_16_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_measurement_connector_18_0_0_aar.xml +10 -0
- package/android/.idea/libraries/Gradle__com_google_firebase_firebase_messaging_20_1_2_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__com_google_guava_listenablefuture_1_0_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__com_squareup_javawriter_2_1_1_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__javax_inject_javax_inject_1_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__junit_junit_4_12_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__net_bytebuddy_byte_buddy_1_9_7_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__net_bytebuddy_byte_buddy_agent_1_9_7_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__net_sf_kxml_kxml2_2_3_0_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_apache_cordova_framework_7_0_0_aar.xml +12 -0
- package/android/.idea/libraries/Gradle__org_hamcrest_hamcrest_core_1_3_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_hamcrest_hamcrest_integration_1_3_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_hamcrest_hamcrest_library_1_3_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_json_json_20140107_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_mockito_mockito_core_2_25_1_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_mockito_mockito_inline_2_25_1_jar.xml +13 -0
- package/android/.idea/libraries/Gradle__org_objenesis_objenesis_2_6_jar.xml +13 -0
- package/android/.idea/misc.xml +14 -0
- package/android/.idea/modules/-485579866/capacitor-android.iml +171 -0
- package/android/.idea/modules/BrotherPrintLibrary/BrotherPrintLibrary.iml +27 -0
- package/android/.idea/modules/android.iml +110 -0
- package/android/.idea/modules.xml +10 -0
- package/android/.idea/runConfigurations.xml +12 -0
- package/android/.idea/vcs.xml +6 -0
- package/android/.idea/workspace.xml +83 -0
- package/android/BrotherPrintLibrary/BrotherPrintLibrary.aar +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/AndroidManifest.xml +11 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jars/classes.jar +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jars/libs/MobilePrintLib.jar +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/arm64-v8a/libcreatedata.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/armeabi/libAndrJFPDFEMB.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/armeabi/libcreatedata.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/armeabi-v7a/libAndrJFPDFEMB.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/armeabi-v7a/libcreatedata.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/x86/libcreatedata.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a/jetified-BrotherPrintLibrary/jni/x86_64/libcreatedata.so +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/25e734394246e1bfc2863356368dd65a.bin +1 -0
- package/android/BrotherPrintLibrary/build/.transforms/8f03997c59bfcdf41861a60561d5d5af.bin +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/b3cb8a1794c15332bde93f2b78199c73/jetified-BrotherPrintLibrary.aar +0 -0
- package/android/BrotherPrintLibrary/build/.transforms/b3cb8a1794c15332bde93f2b78199c73.bin +1 -0
- package/android/BrotherPrintLibrary/build/.transforms/bb913df08d40846b1bc63945606f217a.bin +2 -0
- package/android/BrotherPrintLibrary/build/.transforms/cf1dcc0f016004f76302659fc63c1d4f.bin +1 -0
- package/android/BrotherPrintLibrary/build.gradle +2 -0
- package/android/build.gradle +2 -0
- package/android/local.properties +8 -0
- package/android/settings.gradle +1 -0
- package/android/src/main/AndroidManifest.xml +12 -0
- package/android/src/main/java/jp/rdlabo/capacitor/plugin/brotherprint/BrotherPrint.java +149 -6
- package/dist/docs.json +105 -0
- package/dist/esm/definitions.d.ts +12 -9
- package/dist/esm/definitions.js +1 -0
- package/dist/esm/definitions.js.map +1 -1
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +6 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/web.d.ts +14 -7
- package/dist/esm/web.js +15 -18
- package/dist/esm/web.js.map +1 -1
- package/dist/plugin.cjs.js +43 -0
- package/dist/plugin.cjs.js.map +1 -0
- package/dist/plugin.js +28 -18
- package/dist/plugin.js.map +1 -1
- package/ios/Plugin/Plugin.h +0 -1
- package/ios/Plugin/Plugin.m +4 -1
- package/ios/Plugin/Plugin.swift +150 -7
- package/ios/Plugin/module.modulemap +9 -0
- package/ios/Plugin.xcodeproj/project.pbxproj +47 -1
- package/ios/Plugin.xcodeproj/project.xcworkspace/xcuserdata/sakakibara.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- package/ios/Plugin.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/xcschememanagement.plist +27 -0
- package/ios/Plugin.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
- package/ios/Plugin.xcworkspace/xcuserdata/sakakibara.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- package/ios/Podfile +2 -1
- package/ios/Podfile.lock +8 -1
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/BRLMPrinterKit +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/BluetoothViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/CutterViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/ExtraFeedViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/GenericMobileLabelModelPaperSizeViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BMSPrinterDriver.h +727 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BMSPrinterKit.h +60 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRCustomPaperInfoCommand.h +107 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMChannel.h +33 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMCustomPaperSize.h +69 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMError.h +25 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMGetStatusError.h +27 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMMWPrintSettings.h +35 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMOpenChannelError.h +27 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPJPrintSettings.h +84 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPJPrintSettingsCustomPaperSize.h +25 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPJPrintSettingsPaperSize.h +35 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPTPrintSettings.h +53 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrintError.h +52 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrintImageSettings.h +77 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrintSettingsProtocol.h +25 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterClassifier.h +31 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterDefine.h +59 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterDriver.h +54 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterDriverGenerator.h +34 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterKit+BRPtouchPrinterKit+BMSPrinterKit.h +18 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterKit.h +32 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMPrinterStatus.h +55 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMQLPrintSettings.h +64 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMRJPrintSettings.h +48 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMTDPrintSettings.h +47 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRLMValidatePrintSettings.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchBLEManager.h +28 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchBatteryInfo.h +26 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchBluetoothManager.h +59 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchDeviceInfo.h +23 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchLabelInfoStatus.h +119 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchLabelParam.h +27 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchNetworkManager.h +44 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchPrintInfo.h +136 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchPrinter.h +272 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchPrinterData.h +16 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchPrinterKit.h +18 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchPrinterStatus.h +58 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BRPtouchTemplateInfo.h +23 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/GenericMobileLabelModelPrintSettings.h +211 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/GenericMobileLabelModelPrintSettingsViewController.h +50 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/GenericPocketJetPrintSettings.h +99 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/GenericPocketJetPrintSettingsViewController.h +47 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ673PrintSettings.h +43 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ673PrintSettingsViewController.h +40 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ763MFIPrintSettingsViewController.h +41 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ763MFiPrintSettings.h +45 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ773PrintSettings.h +46 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PJ773PrintSettingsViewController.h +41 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PrintSettingTableViewController.h +51 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PrintSettings.h +467 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/PrintSettingsViewController.h +203 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2050PrintSettings.h +81 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2050PrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2140PrintSettings.h +81 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2140PrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2150PrintSettings.h +81 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ2150PrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3050AIPrintSettings.h +81 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3050AiPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3050PrintSettings.h +81 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3050PrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3150AiPrintSettings.h +82 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3150AiPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3150PrintSettings.h +82 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ3150PrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4030AiPrintSettings.h +103 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4030AiPrintSettingsViewController.h +41 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4040PrintSettings.h +102 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4040PrintSettingsViewController.h +41 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4230BPrintSettings.h +107 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4230BPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4250WBPrintSettings.h +108 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/RJ4250WBPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD2120NPrintSettings.h +83 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD2120NPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD2130NPrintSettings.h +82 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD2130NPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD4550DNWBPrintSettings.h +76 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/TD4550DNWBPrintSettingsViewController.h +42 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/IPAddressHelp.pdf +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/IPAddressViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Info.plist +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/MarginViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PJCustomPaperViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PrintProgressViewControllerWithFilename_BMSSDK~ipad.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PrintProgressViewControllerWithFilename_BMSSDK~iphone.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PrintProgressViewController_BMSSDK~ipad.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PrintProgressViewController_BMSSDK~iphone.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/PrinterList.plist +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/ThresholdViewController.nib +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsj673ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bspe55ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bspp75ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsq71wad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsq72wad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr305ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr315ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr403ad.txt +91 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr403aiad.txt +91 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr404ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr404ad.txt +91 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr423ad.txt +666 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bsr425ad.txt +610 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst212ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst213ad.ptd +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst40ad.txt +482 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst41nad.txt +310 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst441ad.txt +495 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst442ad.txt +495 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst451ad.txt +495 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst452ad.txt +495 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/bst455ad.txt +495 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/checkbox_checked.png +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/checkbox_unchecked.png +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/en.lproj/InfoPlist.strings +0 -0
- package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/modulemap/module.modulemap +9 -0
- package/ios/Pods/BRLMPrinterKit/LICENSE +19 -0
- package/ios/Pods/BRLMPrinterKit/README.md +34 -0
- package/ios/Pods/Manifest.lock +8 -1
- package/ios/Pods/Pods.xcodeproj/project.pbxproj +274 -155
- package/ios/Pods/Pods.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/BRLMPrinterKit.xcscheme +60 -0
- package/ios/Pods/Pods.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/CapacitorCordova.xcscheme +11 -13
- package/ios/Pods/Pods.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/Pods-Plugin.xcscheme +11 -13
- package/ios/Pods/Pods.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/Pods-PluginTests.xcscheme +11 -13
- package/ios/Pods/Pods.xcodeproj/xcuserdata/sakakibara.xcuserdatad/xcschemes/xcschememanagement.plist +15 -0
- package/ios/Pods/Target Support Files/BRLMPrinterKit/BRLMPrinterKit.debug.xcconfig +11 -0
- package/ios/Pods/Target Support Files/BRLMPrinterKit/BRLMPrinterKit.release.xcconfig +11 -0
- package/ios/Pods/Target Support Files/Pods-Plugin/Pods-Plugin-acknowledgements.markdown +23 -0
- package/ios/Pods/Target Support Files/Pods-Plugin/Pods-Plugin-acknowledgements.plist +29 -0
- package/ios/Pods/Target Support Files/Pods-Plugin/Pods-Plugin.debug.xcconfig +3 -2
- package/ios/Pods/Target Support Files/Pods-Plugin/Pods-Plugin.release.xcconfig +3 -2
- package/ios/Pods/Target Support Files/Pods-PluginTests/Pods-PluginTests-acknowledgements.markdown +23 -0
- package/ios/Pods/Target Support Files/Pods-PluginTests/Pods-PluginTests-acknowledgements.plist +29 -0
- package/ios/Pods/Target Support Files/Pods-PluginTests/Pods-PluginTests-frameworks.sh +2 -0
- package/ios/Pods/Target Support Files/Pods-PluginTests/Pods-PluginTests.debug.xcconfig +3 -2
- package/ios/Pods/Target Support Files/Pods-PluginTests/Pods-PluginTests.release.xcconfig +3 -2
- package/package.json +29 -16
- package/android/.npmignore +0 -1
package/ios/Pods/BRLMPrinterKit/BRLMPrinterKit/BRLMPrinterKit.framework/Headers/BMSPrinterDriver.h
ADDED
|
@@ -0,0 +1,727 @@
|
|
|
1
|
+
//
|
|
2
|
+
// BMSPrinterDriver.h
|
|
3
|
+
// BMSPrinterKit
|
|
4
|
+
//
|
|
5
|
+
// Created by BMS on 10/2/12.
|
|
6
|
+
// Copyright (c) 2012 Brother Mobile Solutions, Inc. All rights reserved.
|
|
7
|
+
//
|
|
8
|
+
|
|
9
|
+
#import <Foundation/Foundation.h>
|
|
10
|
+
#import <CoreGraphics/CoreGraphics.h>
|
|
11
|
+
#import <UIKit/UIKit.h> // for UIViewController definition
|
|
12
|
+
|
|
13
|
+
#ifndef REMOVE_BRPTOUCH_SDK
|
|
14
|
+
// NOTE: This is now preprocessor definition in the RemoveBRPtouchSDK version of the project.
|
|
15
|
+
|
|
16
|
+
// NOTE: We can NOT use the following "framework" syntax here (i.e. <BRPtouchPrinterKit/BRPtouchPrinterKit.h>)
|
|
17
|
+
// However, we CAN use the "BRPtouchPrinterKit.h" syntax, since we have added the BIL SDK .h
|
|
18
|
+
// files to our project.
|
|
19
|
+
//#import <BRPtouchPrinterKit/BRPtouchPrinterKit.h>
|
|
20
|
+
#import "BRPtouchPrinterKit.h"
|
|
21
|
+
|
|
22
|
+
#endif
|
|
23
|
+
|
|
24
|
+
#import "PrintSettings.h"
|
|
25
|
+
|
|
26
|
+
//*** NOTIFICATIONS
|
|
27
|
+
// Register for these if you wish to receive notifications for the following messages.
|
|
28
|
+
// Typically, you will only want to register for these if you are creating your own Custom Progress View.
|
|
29
|
+
|
|
30
|
+
// *************************************************************************************
|
|
31
|
+
// 1. Use this notification instead of sendData return value if you are making a Progress ViewController.
|
|
32
|
+
// With PJ7 printers, especially PJ-763MFi, "sendDataToChannel" may not return immediately on the final band,
|
|
33
|
+
// because it needs to check printer status to wait for the page to be printed before more data can be sent.
|
|
34
|
+
// This notification will be sent as soon as the data has been sent, allowing you to update your Progress GUI quicker.
|
|
35
|
+
// NOTE: KEY_BYTESWRITTEN is used when processing the SENDDATA notification.
|
|
36
|
+
// NOTE: If you are creating a ProgressView, this notification will work with ALL print APIs, even "simple" ones.
|
|
37
|
+
// So, it's recommended to use this instead of the return value of "sendDataToChannel". Refer to CustomProgress in SDK Sample.
|
|
38
|
+
#define NOTIFICATION_SENDDATA @"SendDataNotification"
|
|
39
|
+
#define NOTIFICATION_SENDDATA_KEY_BYTESWRITTEN @"Bytes Written"
|
|
40
|
+
// *************************************************************************************
|
|
41
|
+
|
|
42
|
+
// *************************************************************************************
|
|
43
|
+
// 2. MFi Bluetooth models MUST process STATUS RESPONSES for each page BEFORE sending data for the next page.
|
|
44
|
+
// This is being done to fix problems related to data handshake that cause Apple to disconnect the MFi device.
|
|
45
|
+
// The status response will not come until the page has been printed, which may take some time.
|
|
46
|
+
//
|
|
47
|
+
// This notification lets you know when this event occurs, in case you are creating a custom progress and want
|
|
48
|
+
// to inform the user. Even though you probably already know this will happen, the sendDataToChannel API will not return
|
|
49
|
+
// until the status response has been received. So, this notification allows you to update your Progress GUI
|
|
50
|
+
// at the moment this event occurs.
|
|
51
|
+
//
|
|
52
|
+
// * NOTE: SDK 2.1 decided NOT to send this notification for RJ-4030Ai (and other new RJ models). So, it is only being sent for PJ-763MFi.
|
|
53
|
+
//
|
|
54
|
+
// The main reason why is that RJ4 pages typically send AND print much faster than PJ pages because they are shorter,
|
|
55
|
+
// particularly if you are printing labels. So, if you are printing a large batch of labels, then the progress GUI
|
|
56
|
+
// (at least the one built-in to the SDK) looks strange when processing this message, because it spends most of its
|
|
57
|
+
// time showing this message, instead of some potentially more valuable messages for the user.
|
|
58
|
+
|
|
59
|
+
// Also, RJ models will always be using Roll Paper (continuous or labels), so it is not necessary (typically) to remind user to insert paper
|
|
60
|
+
// for each page, like it is for PJ users who use Cutsheet paper.
|
|
61
|
+
//
|
|
62
|
+
// So, a better approach for RJ4 may be to add other notifications instead of this one, as we read them.
|
|
63
|
+
// This could allow sending notifications if various errors occur DURING printing, such as "Cover Open",
|
|
64
|
+
// "No Paper", "Printer Overheat", "Low Battery", etc.
|
|
65
|
+
//
|
|
66
|
+
// TODO: Add these new notifications. These could be applicable with PJ763Mfi too, but only if we enable the
|
|
67
|
+
// unsolicited status responses.
|
|
68
|
+
//
|
|
69
|
+
#define NOTIFICATION_WAITING_FOR_STATUSRESPONSE @"WaitStatusResponseNotification"
|
|
70
|
+
// *************************************************************************************
|
|
71
|
+
|
|
72
|
+
// *************************************************************************************
|
|
73
|
+
// 3. Use NOTIFICATION_PRINTER_STATUS to receive notifications about printer status issues while printing,
|
|
74
|
+
// such as "cooling on/off", "coverOpen", "paperOut", etc.
|
|
75
|
+
// Refer to CustomProgressView in SDK Sample App for example of how to process this notification.
|
|
76
|
+
// The "userInfo" will contain Dictionary with 1 key/value pair.
|
|
77
|
+
// * Use KEY_STATUSNUMBER (NSNumber object) to process the notification.
|
|
78
|
+
//
|
|
79
|
+
// *** IMPORTANT NOTE: For now, this notification is ONLY supported for the BLUETOOTH channel, since it's the only channel
|
|
80
|
+
// that can read printer status for the "unsolicited" responses. In the future, this might be applicable for WIFI.
|
|
81
|
+
#define NOTIFICATION_PRINTER_STATUS @"PrinterStatusNotification"
|
|
82
|
+
#define NOTIFICATION_PRINTER_STATUS_KEY_STATUSNUMBER @"Status Number"
|
|
83
|
+
|
|
84
|
+
//*** Possible values returned for KEY_STATUSNUMBER
|
|
85
|
+
// These values are sent to Apps that register for NOTIFICATION_PRINTER_STATUS notifications.
|
|
86
|
+
// These values are defined arbitrarily and have no correspondence to the values returned in PTSTATUSINFO.
|
|
87
|
+
// NOTE: Not all status responses will generate a notification. And, not all are supported for each printer and channel.
|
|
88
|
+
// And, you are not required to handle all or any of them.
|
|
89
|
+
|
|
90
|
+
#define NOTIFICATION_PRINTER_STATUSNUMBER_COOLING_BEGIN 2001
|
|
91
|
+
#define NOTIFICATION_PRINTER_STATUSNUMBER_COOLING_END 2002
|
|
92
|
+
#define NOTIFICATION_PRINTER_STATUSNUMBER_MEDIAEMPTY_BEGIN 2003
|
|
93
|
+
#define NOTIFICATION_PRINTER_STATUSNUMBER_COVEROPEN_BEGIN 2004
|
|
94
|
+
#define NOTIFICATION_PRINTER_STATUSNUMBER_WAITINGFORPEELER_BEGIN 2005 // only sent for printers with peeler available and enabled.
|
|
95
|
+
|
|
96
|
+
// NOTE: MEDIAEMPTY, COVEROPEN, and WAITINGFORPEELER do NOT have a corresponding "_END" notification.
|
|
97
|
+
// The main reason is that the printers don't generate an "unsolicited" status response notification for these "end" conditions.
|
|
98
|
+
// These conditions can be detected internally, but it's not useful for an app because it requires sending another page(s) of data.
|
|
99
|
+
//
|
|
100
|
+
// --------------------------------
|
|
101
|
+
// With MEDIAEMPTY and COVEROPEN:
|
|
102
|
+
// --------------------------------
|
|
103
|
+
// In a multi-page job, the RJ/TD printers continue to receive data and send status responses indicating that printing is successful.
|
|
104
|
+
// Only on the LAST page of a job does the printer WAIT to send "printing completed" status.
|
|
105
|
+
// So, as long as the job doesn't overflow the internal buffer, the printer can receive all the data for the job before
|
|
106
|
+
// you insert paper or close the cover. Then, if cover is closed or media inserted, printing should complete NORMALLY!!
|
|
107
|
+
// This is why they are NOT being treated as "fatal errors". And, for this reason, you may not even need to handle these notifications.
|
|
108
|
+
//
|
|
109
|
+
// The concerns are:
|
|
110
|
+
// a) a statusResponseTimeout error could occur before media is changed after the final page of data has been sent.
|
|
111
|
+
// So, the print API return code will indicate error.
|
|
112
|
+
// But, everything should print OK anyway after you close the cover or insert more paper.
|
|
113
|
+
// b) If too many pages are sent after the error occurs, the printer's internal buffer may fill up which could cause a "fatal" error.
|
|
114
|
+
//
|
|
115
|
+
// If you wish o prevent these concerns, you will have to use the "Manual APIs".
|
|
116
|
+
//
|
|
117
|
+
// Here is an algorithm that may be useful:
|
|
118
|
+
// 1. When you receive the notification, set a flag indicating mediaEmpty or coverOpen.
|
|
119
|
+
// 2. If flag is set, STOP sending data at the BEGINNING of a page
|
|
120
|
+
// 3."Poll" the printer status manually using "getPTStatus", and check the appropriate bits in the status response
|
|
121
|
+
// to determine when the condition goes away.
|
|
122
|
+
// 4. Allow user to cancel, in case there's a problem with the "polling".
|
|
123
|
+
//
|
|
124
|
+
// Refer to the Custom Progress View in SDK Sample App for an example.
|
|
125
|
+
//
|
|
126
|
+
// --------------------------------
|
|
127
|
+
// With WAITINGFORPEELER:
|
|
128
|
+
// --------------------------------
|
|
129
|
+
// There is no reason to check for the "end" notification anyway, because "sendDataToChannel" will not return
|
|
130
|
+
// until after the label is peeled (or a timeout occurs). But, you can use the "begin" notification to post
|
|
131
|
+
// a notice to users as a reminder they need to peel.
|
|
132
|
+
//
|
|
133
|
+
// *************************************************************************************
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
//*** Used to assure that the CGBitmap is 32-pixel aligned
|
|
137
|
+
// NOTE: Need to cast the division result to (int) in case a float type
|
|
138
|
+
// is passed in for x so we get the expected truncation.
|
|
139
|
+
#define ALIGN32(x) ((int)((x+31)/32) * 32)
|
|
140
|
+
|
|
141
|
+
// *************************************************************************************
|
|
142
|
+
//*** API Function Possible Return Codes ***
|
|
143
|
+
|
|
144
|
+
#ifndef REMOVE_BRPTOUCH_SDK
|
|
145
|
+
// NOTE: This is now a preprocessor definition in the RemoveBRPtouchSDK version of the project.
|
|
146
|
+
|
|
147
|
+
// NOTE: Some API functions will return values defined in BRPtouchPrinter.h,
|
|
148
|
+
// such as RET_TRUE, RET_FALSE, ERROR_TIMEOUT, etc.
|
|
149
|
+
// For clarity, the return codes defined in this module will begin at -1000.
|
|
150
|
+
|
|
151
|
+
#else
|
|
152
|
+
// When BRPtouch SDK is removed, we need to define these constants.
|
|
153
|
+
|
|
154
|
+
#define RET_FALSE 0
|
|
155
|
+
#define RET_TRUE 1
|
|
156
|
+
#define ERROR_TIMEOUT -3
|
|
157
|
+
|
|
158
|
+
#endif
|
|
159
|
+
|
|
160
|
+
#define RET_PARAMETER_ERROR -1000
|
|
161
|
+
#define RET_FILEPATHURL_ERROR -1001
|
|
162
|
+
#define RET_PDFPAGE_ERROR -1002
|
|
163
|
+
#define RET_PRINTSETTINGS_ERROR -1003
|
|
164
|
+
#define RET_PARENTVIEW_ERROR -1004
|
|
165
|
+
#define RET_DATABUFFER_ERROR -1005
|
|
166
|
+
#define RET_PRINTERMODEL_ERROR -1006
|
|
167
|
+
|
|
168
|
+
// Channel related errors
|
|
169
|
+
// These are generic for EACH channel (WIFI, BT, FILE)
|
|
170
|
+
#define RET_CHANNEL_NOTOPEN_ERROR -1007 // if use Manual APIs on channel that has not been opened successfully
|
|
171
|
+
#define RET_CHANNEL_CREATE_ERROR -1008 // if error creating WIFI/FILE streams or BluetoothSessionController. Memory related.
|
|
172
|
+
#define RET_CHANNEL_WRITE_ERROR -1009 // error occurred while writing data, such as if channel disconnected
|
|
173
|
+
#define RET_CHANNEL_READ_ERROR -1010 // error occurred while reading data, such as if channel disconnected
|
|
174
|
+
|
|
175
|
+
// This is used only by WIFI and FILE channel.
|
|
176
|
+
// In previous SDKs, RET_CHANNEL_CREATEERROR was used instead, but now we differentiate between these cases.
|
|
177
|
+
// NOTE: With WIFI channel especially, this can occur when user tries to start a job too quickly after a failure.
|
|
178
|
+
// Generally, using "isPrinterReady" API before calling openChannel can avoid this.
|
|
179
|
+
#define RET_CHANNEL_STREAMSTATUS_ERROR -1011
|
|
180
|
+
|
|
181
|
+
// These are used only for BT channel
|
|
182
|
+
#define RET_BLUETOOTHCHANNEL_NOCONNECTEDPRINTERS_ERROR -1012 // No BT printers are connected
|
|
183
|
+
#define RET_BLUETOOTHCHANNEL_CHANNELDISCONNECTED_ERROR -1013 // BT Session disconnected while sending data
|
|
184
|
+
#define RET_BLUETOOTHCHANNEL_OPENSESSION_ERROR -1014 // unable to open EASession
|
|
185
|
+
// Added this in SDK 2.1.0 to allow distinguishing this from ERROR_TIMEOUT. Only applicable for MFi models.
|
|
186
|
+
// This error may occur if all data was sent successfully for a page, but the SDK timed out waiting for
|
|
187
|
+
// a status response from the printer, which may occur if paper is not inserted on time to print the whole page
|
|
188
|
+
// before the "statusReponseTimeout" has been reached.
|
|
189
|
+
#define RET_BLUETOOTHCHANNEL_STATUSTIMEOUT_ERROR -1015
|
|
190
|
+
|
|
191
|
+
// These are also only used with BT channel, since it's currently the only Bi-Di channel.
|
|
192
|
+
// However, these are generally related to errors received when processing printer status.
|
|
193
|
+
// So, in case WIFI is ever able to be Bi-Di, let's use a more generic name for these #define constants
|
|
194
|
+
#define RET_PRINTERSTATUS_ERROR_PRINTERTURNEDOFF -1016
|
|
195
|
+
#define RET_PRINTERSTATUS_ERROR_BATTERYWEAK -1017
|
|
196
|
+
#define RET_PRINTERSTATUS_ERROR_EXPANSIONBUFFERFULL -1018
|
|
197
|
+
#define RET_PRINTERSTATUS_ERROR_COMMUNICATIONERROR -1019
|
|
198
|
+
#define RET_PRINTERSTATUS_ERROR_OVERHEATINGERROR -1020
|
|
199
|
+
#define RET_PRINTERSTATUS_ERROR_MEDIACANNOTBEFED -1021 // This is different from media empty. Treated as an error.
|
|
200
|
+
#define RET_PRINTERSTATUS_ERROR_UNKNOWNERROR -1022 // If status response processor gets unhandled error
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
// *************************************************************************************
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
// *************************************************************************************
|
|
207
|
+
// SENDDATAMODE - new parameter added to "sendDataToChannel" and "sendNSDataToChannel".
|
|
208
|
+
//
|
|
209
|
+
// With Bluetooth Printers, it is REQUIRED to know EXACTLY when the FORM FEED command occurs in the data stream.
|
|
210
|
+
//
|
|
211
|
+
// NOTE: By "Form Feed", this means "the last byte(s) of data sent for a PAGE of data", which cause it to
|
|
212
|
+
// print the page.
|
|
213
|
+
// * for PJ models, this typically means "Esc ~ \0C" or "Esc ^ \0C"
|
|
214
|
+
// * for RJ/TD models, this typically means "\1A" or "\0C".
|
|
215
|
+
//
|
|
216
|
+
// The reason is that BT printers typically send several "status" responses while printing a page.
|
|
217
|
+
// In some cases, the printer will NOT ACCEPT DATA until the page completes printing.
|
|
218
|
+
// And, with Bluetooth MFi, Apple will SHUT DOWN THE CONNECTION if it cannot send data to the printer within
|
|
219
|
+
// about 5 seconds. Yet, Apple seems to take the data in some cases before it reports FALSE for "hasSpaceAvailable".
|
|
220
|
+
// As such, there seems to be a TIMING PROBLEM with either the Printer Firmware or Apple's EASession, or both!!
|
|
221
|
+
// So, we need to AVOID sending data to Apple when the printer will stop accepting it.
|
|
222
|
+
//
|
|
223
|
+
// So the "sendDataToChannel" and "sendNSDataToChannel" APIs need to know when the printer will begin printing a
|
|
224
|
+
// page, so we can stop sending data until all the status responses have been processed.
|
|
225
|
+
//
|
|
226
|
+
// NOTE: WIFI models do NOT send status responses over Port9100 connections.
|
|
227
|
+
// So, it is not possible to handle them in the same way as required with Bluetooth models.
|
|
228
|
+
// In this SDK, status is being IGNORED with WIFI connections. But, in the future, it may be necessary to handle it
|
|
229
|
+
// a different way. So, even WIFI models MAY benefit from this new option eventually.
|
|
230
|
+
//
|
|
231
|
+
// Options:
|
|
232
|
+
// 1. kSendDataMode_NoFormFeed:
|
|
233
|
+
// * This buffer of data does NOT contain a form feed.
|
|
234
|
+
// * So, all bytes will be sent and the method will return immediately (as soon as possible)
|
|
235
|
+
//
|
|
236
|
+
// 2. kSendDataMode_FormFeedAtEnd:
|
|
237
|
+
// * This buffer DOES contain a form feed, and this is at the END of the buffer.
|
|
238
|
+
// * NOTE: This can normally be determined easily, since this will be the last buffer of data for the page,
|
|
239
|
+
// where the data was generated by one of the "generatePrintData" APIs below.
|
|
240
|
+
// * So, the sendDataXX methods will process the printer status before returning.
|
|
241
|
+
// * WARNING: Do not use this mode if you generate/send your own ZPL/CPCL/ESCP data!! Some printers (RJ4030Ai at least)
|
|
242
|
+
// do not send status responses except for Raster Mode data.
|
|
243
|
+
//
|
|
244
|
+
// 3. kSendDataMode_FormFeedIndeterminate:
|
|
245
|
+
// * This buffer MAY OR MAY NOT contain a form feed, and it could be anywhere in the buffer.
|
|
246
|
+
// * So, the code may "search" the data buffer to see if it contains the Form Feed, if applicable.
|
|
247
|
+
// * NOTE: Since PJ models contain a 3-byte FormFeed command, it is possible to find it. However, since
|
|
248
|
+
// other models only have a 1-byte command, it is not practical to try to find the byte in the data,
|
|
249
|
+
// because it could be a valid byte of actual PRINT data, NOT a command byte. It is impossible to
|
|
250
|
+
// distinguish without writing a full parser.
|
|
251
|
+
// So, only PJ763 will treat this differently than the "NoFormFeed" option.
|
|
252
|
+
// * NOTE: However, even with PJ, it is possible for the print data to RANDOMLY contain the 3-bytes as PRINT DATA.
|
|
253
|
+
// If this occurs, it WILL cause a PROBLEM.
|
|
254
|
+
// * NOTE: This case is mostly applicable when sending multiple page PRN data, such as with one of the
|
|
255
|
+
// "sendFile" APIs.
|
|
256
|
+
//
|
|
257
|
+
// * We recommend NOT using this option, if it is at all possible to avoid it.
|
|
258
|
+
//
|
|
259
|
+
// Generally, the SDK will handle this internally for the "Simple APIs", e.g. "printPDFFilePathURL".
|
|
260
|
+
// So, you the ISV will only need to care about this when you are using the "Manual APIs".
|
|
261
|
+
//
|
|
262
|
+
// We recommend using options 1 and 2 only if you are using Manual APIs to send PDF or IMAGE data.
|
|
263
|
+
// However, for PRN data, particularly in a FILE, it may be necessary to use option 3 ("Indeterminate").
|
|
264
|
+
//
|
|
265
|
+
// WARNING: If your app generates its own PRN data (e.g. ESC/P, ZPL, CPCL, etc) which you use with "sendDataToChannel",
|
|
266
|
+
// you might think you can use option 1,2 instead of option 3. However, **DO NOT USE** Option 2 ("FormFeedAtEnd")
|
|
267
|
+
// with RJ4030Ai, unless data is "Raster Mode". Unfortunately, the printer does NOT send "unsolicited status" responses
|
|
268
|
+
// for ESC/P, ZPL, CPCL, etc. So, the SDK will lock up waiting for status responses that will never come, and this will
|
|
269
|
+
// result in a STATUSTIMEOUT_ERROR.
|
|
270
|
+
//
|
|
271
|
+
// Refer to SDK Sample App code for more details of how to use this.
|
|
272
|
+
//
|
|
273
|
+
typedef enum
|
|
274
|
+
{
|
|
275
|
+
kSendDataMode_NoFormFeed=1,
|
|
276
|
+
kSendDataMode_FormFeedAtEnd,
|
|
277
|
+
kSendDataMode_FormFeedIndeterminate,
|
|
278
|
+
} SENDDATAMODE;
|
|
279
|
+
// *************************************************************************************
|
|
280
|
+
|
|
281
|
+
|
|
282
|
+
@interface BMSPrinterDriver : NSObject
|
|
283
|
+
{
|
|
284
|
+
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
//******** Designated Initializers ********
|
|
288
|
+
- (id) initWithPrintSettings:(PrintSettings *)printSettings; // use this for PDF or IMAGE
|
|
289
|
+
- (id) initWithModel:(PRINTERMODEL)theModel; // use this for PRN file/data
|
|
290
|
+
|
|
291
|
+
//******** Class Properties ********
|
|
292
|
+
@property (nonatomic, assign) PRINTERMODEL printerModel;
|
|
293
|
+
@property (nonatomic, retain) PrintSettings *printSettings;
|
|
294
|
+
|
|
295
|
+
// Caller MUST set these as appropriate when printing multiple pages (when using the "Manual APIs").
|
|
296
|
+
@property (nonatomic, assign) BOOL isFirstPage;
|
|
297
|
+
@property (nonatomic, assign) BOOL isLastPage;
|
|
298
|
+
|
|
299
|
+
//*** Optional Properties:
|
|
300
|
+
|
|
301
|
+
// *************************************************************************************
|
|
302
|
+
// antiAliasMode:
|
|
303
|
+
//
|
|
304
|
+
// This property is now provided to override the (new) default handling of "anti-aliasing".
|
|
305
|
+
// When Anti-Alias is ENABLED, font characters will be "smoothed" by Apple by adding a "light-gray outline".
|
|
306
|
+
// This is Apple's default behavior, and it was our SDK's default behavior in v1.1.1 and earlier.
|
|
307
|
+
//
|
|
308
|
+
// DEFAULT driver behavior (new in SDK 2.0):
|
|
309
|
+
// * If Halftone is kHalftoneDiffusion, anti-alias is DISABLED, because halftoning may produce "stray dots" on
|
|
310
|
+
// characters that can decrease clarity.
|
|
311
|
+
// * If Halftone is kHalftoneThreshold, anti-alias is ENABLED, because Threshold Value can be used to "thicken"
|
|
312
|
+
// the font characters by increasing the Threshold Value, so that the "light-gray outline" is printed BLACK
|
|
313
|
+
// instead of WHITE as it normally does at the default threshold value of 128.
|
|
314
|
+
//
|
|
315
|
+
// In some cases, you might want to force the anti-alias on/off. This property is provided for that purpose.
|
|
316
|
+
//
|
|
317
|
+
// For example, when printing barcodes, generally you will want to use Threshold halftone because Diffusion
|
|
318
|
+
// could make them unreadable. However, with AntiAlias ENABLED, it could result in thicker bars which MAY
|
|
319
|
+
// confuse a barcode reader. If that happens, then you should force AntiAliasing to be disabled.
|
|
320
|
+
//
|
|
321
|
+
// Another example: some pixels in the anti-alias "gray outline" might be darker gray than the Threshold Value,
|
|
322
|
+
// which would result in "stray dots". So, you could DISABLE anti-alias in this case to remove these
|
|
323
|
+
// stray dots, but then modifying Threshold Value would have NO effect in "thickening" the text characters.
|
|
324
|
+
//
|
|
325
|
+
// In most cases, it is a very subtle change, and most users will not notice the difference either way.
|
|
326
|
+
// But, we are providing this property as an option to an ISV just in case it will be required.
|
|
327
|
+
typedef enum
|
|
328
|
+
{
|
|
329
|
+
kAntiAliasMode_UseDriverDefault=1,
|
|
330
|
+
kAntiAliasMode_ForceEnabled,
|
|
331
|
+
kAntiAliasMode_ForceDisabled,
|
|
332
|
+
} ANTIALIASMODE;
|
|
333
|
+
@property (nonatomic, assign) ANTIALIASMODE antiAliasMode;
|
|
334
|
+
// *************************************************************************************
|
|
335
|
+
|
|
336
|
+
|
|
337
|
+
// *************************************************************************************
|
|
338
|
+
// interpolationQuality - Added at SDK 2.3.0
|
|
339
|
+
// Previous SDKs did not set a value when drawing the PDF/Image on the CGContext.
|
|
340
|
+
// So, presumably it was using "kCGInterpolationDefault".
|
|
341
|
+
// However, recent tests indicate that using "kCGInterpolationNone" can produce better quality
|
|
342
|
+
// output, especially when using ErrorDiffusion. So, "none" will be the new default.
|
|
343
|
+
// If ISV notices any problems in output quality with the new SDK, this property is provided to
|
|
344
|
+
// allow you to change this setting to one of the other values.
|
|
345
|
+
// NOTE: Not adding a new enum as we did with ANTIALIASMODE, since Apple already provides one.
|
|
346
|
+
@property (nonatomic, assign) CGInterpolationQuality interpolationQuality;
|
|
347
|
+
// *************************************************************************************
|
|
348
|
+
|
|
349
|
+
|
|
350
|
+
// *************************************************************************************
|
|
351
|
+
// statusResponseTimeout:
|
|
352
|
+
//
|
|
353
|
+
// Timeout for Status Response - applicable for MFi (Bluetooth) printer models only.
|
|
354
|
+
// In case STATUS_RESPONSE_TIMEOUT_DEFAULT is not sufficient, we provide this property to allow ISV to change it.
|
|
355
|
+
//
|
|
356
|
+
// Quick Summary:
|
|
357
|
+
// * The value of statusResponseTimeout should be large enough to handle the AMOUNT OF TIME it takes to print a WORST CASE
|
|
358
|
+
// page. The response(s) do not come until the page completes printing.
|
|
359
|
+
// * So, you should consider "WORST CASE" as follows:
|
|
360
|
+
// - page has a lot of graphics, paper may not be inserted, print head overheats while printing the page, etc.
|
|
361
|
+
//
|
|
362
|
+
//
|
|
363
|
+
// IMPORTANT: If you do wish to set this, set it BEFORE calling "openChannel" (if using "Manual APIs") or BEFORE any of the
|
|
364
|
+
// "simple APIs" (e.g. "printPDFFilePathURL").
|
|
365
|
+
// Also, this ONLY applies DURING printing. It does not affect the "getPTStatus" API.
|
|
366
|
+
//
|
|
367
|
+
// NOTES:
|
|
368
|
+
// * This timeout is applicable only when "sendDataToChannel" is called with the kSendDataMode_FormFeedAtEnd, or if
|
|
369
|
+
// kSendDataMode_FormFeedIndeterminate (and SDK code detects that a form feed exists in the data).
|
|
370
|
+
// Since all APIs use this function, it is important to understand this.
|
|
371
|
+
// * Well, it is also applicable if kCloseBluetoothChannelFlushMode_UseStatusRequest is enabled.
|
|
372
|
+
//
|
|
373
|
+
// * PJ763Mfi handles this by sending a status request command and then waiting for the printer response, which does not
|
|
374
|
+
// arrive until the page has completed printing.
|
|
375
|
+
// * RJ4030Ai handles this by reading responses that the printer sends automatically, without sending the request.
|
|
376
|
+
// The final response does not arrive until the page has nearly completed printing.
|
|
377
|
+
// Because these responses come only in Raster Mode, do NOT set "FormFeedAtEnd" unless you are sending Raster mode data.
|
|
378
|
+
//
|
|
379
|
+
// * Bluetooth models seems to require this to avoid what seems to be an Apple Bug with "handshaking" when printing
|
|
380
|
+
// MULTIPLE PAGE jobs, especially with PJ763MFi. This printer will stop taking data for next page while the previous
|
|
381
|
+
// page is being printed. However, the outputStream in EASession does not stop taking data on time.
|
|
382
|
+
// So, if you write to EASession outputStream, but EASession cannot write to the printer within about 5 seconds,
|
|
383
|
+
// then Apple shuts down the MFi connection. So, to get around this problem, the SDK performs this status check
|
|
384
|
+
// between each page.
|
|
385
|
+
|
|
386
|
+
#define STATUS_RESPONSE_TIMEOUT_DEFAULT 60.0 // max # seconds we wait for a response from printer, by default
|
|
387
|
+
@property (nonatomic, assign) CFTimeInterval statusResponseTimeout;
|
|
388
|
+
// *************************************************************************************
|
|
389
|
+
|
|
390
|
+
|
|
391
|
+
// *************************************************************************************
|
|
392
|
+
// closeBluetoothChannelFlushMode:
|
|
393
|
+
//
|
|
394
|
+
// This property will affect only the "closeChannel" API (used by all printing APIs) for the MFi printers only.
|
|
395
|
+
// It is provided JUST IN CASE you run into a problem where Apple disconnects the Bluetooth device, or if all the data
|
|
396
|
+
// seems to have been sent correctly, but the printer doesn't print anything and needs to be power-cycled.
|
|
397
|
+
// If the Bluetooth channel (EASession) is closed before Apple sends all of the data to the printer, one of the two
|
|
398
|
+
// problems mentioned above might occur.
|
|
399
|
+
//
|
|
400
|
+
// 1. kCloseBluetoothChannelFlushMode_UsePrinterDefault (DEFAULT)
|
|
401
|
+
// Each printer model will initialize this to the setting that works best for that model.
|
|
402
|
+
// Choose one of the other settings to override the SDK's default value.
|
|
403
|
+
//
|
|
404
|
+
// 2. kCloseBluetoothChannelFlushMode_None
|
|
405
|
+
// The channel is closed immediately.
|
|
406
|
+
// Because we added the "Status Check" at the END of each page, as determined by kSendDataMode_FormFeedAtEnd,
|
|
407
|
+
// this now seems to work correctly in most cases for RASTER MODE data (PDF, IMAGE, and Raster Mode PRN).
|
|
408
|
+
// This is the default setting for PJ763MFi and RJ/TD Series models.
|
|
409
|
+
//
|
|
410
|
+
// 3. kCloseBluetoothChannelFlushMode_UseStatusRequest
|
|
411
|
+
// Send a status request and wait for the response before closing the channel.
|
|
412
|
+
// This was the best solution, until we added the status check at the end of each page, for each MFi model.
|
|
413
|
+
// This assured that all data was sent before closing the channel, otherwise we would not receive the status response.
|
|
414
|
+
// But, now it is redundant (with Image and PDF printing).
|
|
415
|
+
//
|
|
416
|
+
// IMPORTANT: When sending PRN data (ESC/P, ZPL, CPCL, etc) over MFi Bluetooth, you MUST set this UseStatusRequest option!
|
|
417
|
+
// Otherwise, it is highly likely the channel stream will be shut down before all the data has been sent to the printer.
|
|
418
|
+
// This will result in failure to print the final page, and likely Apple will forcefully disconnect the MFi device.
|
|
419
|
+
//
|
|
420
|
+
// 4. kCloseBluetoothChannelFlushMode_UseFixedDelay
|
|
421
|
+
// This was the first solution before we used the status option. But, the delay needed to be quite large (10 sec) to
|
|
422
|
+
// be reliable. However, this adds this much delay every time the channel is closed.
|
|
423
|
+
//
|
|
424
|
+
// While testing this with a 10 page ESC/P PRN file, because we cannot detect each page break in this case to send the status
|
|
425
|
+
// check during printing, we found that Apple will disconnect the printer when we use the "None" option. So, we provide
|
|
426
|
+
// these other options just in case you run into a problem. In most cases, changing the default will NOT be necessary.
|
|
427
|
+
|
|
428
|
+
typedef enum
|
|
429
|
+
{
|
|
430
|
+
kCloseBluetoothChannelFlushMode_UsePrinterDefault=0,
|
|
431
|
+
kCloseBluetoothChannelFlushMode_None,
|
|
432
|
+
kCloseBluetoothChannelFlushMode_UseStatusRequest,
|
|
433
|
+
kCloseBluetoothChannelFlushMode_UseFixedDelay,
|
|
434
|
+
} CLOSE_BLUETOOTHCHANNEL_FLUSH_MODE;
|
|
435
|
+
@property (nonatomic, assign) CLOSE_BLUETOOTHCHANNEL_FLUSH_MODE closeBluetoothChannelFlushMode;
|
|
436
|
+
// *************************************************************************************
|
|
437
|
+
|
|
438
|
+
|
|
439
|
+
//******** MAIN API FUNCTIONS ********
|
|
440
|
+
|
|
441
|
+
// *** BRPtouchSDK function WRAPPERS ***
|
|
442
|
+
// NOTE: These methods are now fully implemented in the BMS SDK. They are no longer wrappers.
|
|
443
|
+
|
|
444
|
+
// wrappers for sendFile and sendFileEx
|
|
445
|
+
- (int) sendFile: (NSString *)filePath
|
|
446
|
+
channelType: (CHANNELTYPE)channelType
|
|
447
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName
|
|
448
|
+
timeout:(int)nTimeout;
|
|
449
|
+
|
|
450
|
+
- (int) sendFileEx: (NSString *)filePath
|
|
451
|
+
channelType: (CHANNELTYPE)channelType
|
|
452
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName
|
|
453
|
+
timeout:(int)nTimeout;
|
|
454
|
+
|
|
455
|
+
// wrappers for sendData and sendDataEx.
|
|
456
|
+
- (int) sendData:(NSData *)printData
|
|
457
|
+
channelType:(CHANNELTYPE)channelType
|
|
458
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName
|
|
459
|
+
timeout:(int)nTimeout;
|
|
460
|
+
|
|
461
|
+
- (int) sendDataEx:(NSData *)printData
|
|
462
|
+
channelType:(CHANNELTYPE)channelType
|
|
463
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName
|
|
464
|
+
timeout:(int)nTimeout;
|
|
465
|
+
|
|
466
|
+
|
|
467
|
+
// "wrappers" for isPrinterReady and getPTStatus.
|
|
468
|
+
// * isPrinterReady is useful to check for connectivity before attempting to print.
|
|
469
|
+
// * getPTStatus allows to you determine things like the actual connected model, paper inserted, cover open, etc.
|
|
470
|
+
// Refer to the BRPtouchSDK documentation for more details about the format and meaning of the status response.
|
|
471
|
+
|
|
472
|
+
// TAG: REMOVE_BRPTOUCH_SDK
|
|
473
|
+
// When using the "RemoveBRPtouchSDK" framework, isPrinterReady and getPTStatus are NOT supported
|
|
474
|
+
// for the WIFI channel, because WIFI channel requires using the BRPtouchSDK API.
|
|
475
|
+
// However, for the Bluetooth channel, these functions are implemented internally to the BMS SDK, so you may still
|
|
476
|
+
// use these two APIs.
|
|
477
|
+
|
|
478
|
+
- (BOOL)isPrinterReady:(PRINTERMODEL)model
|
|
479
|
+
channelType:(CHANNELTYPE)channelType
|
|
480
|
+
channelString:(NSString *)channelString; // IPAddress or BTDeviceName
|
|
481
|
+
|
|
482
|
+
#ifdef REMOVE_BRPTOUCH_SDK
|
|
483
|
+
typedef struct _PTSTATUSINFO {
|
|
484
|
+
Byte byHead; // Head mark
|
|
485
|
+
Byte bySize; // Size
|
|
486
|
+
Byte byBrotherCode; // Brother code
|
|
487
|
+
Byte bySeriesCode; // Serial code
|
|
488
|
+
Byte byModelCode; // Model code
|
|
489
|
+
Byte byNationCode; // Nation code
|
|
490
|
+
Byte byFiller; // information about cover
|
|
491
|
+
Byte byFiller2; // Not used
|
|
492
|
+
Byte byErrorInf; // Error information 1
|
|
493
|
+
Byte byErrorInf2; // Error information 2
|
|
494
|
+
Byte byMediaWidth; // Media width
|
|
495
|
+
Byte byMediaType; // Media type
|
|
496
|
+
Byte byColorNum; // The number of colors
|
|
497
|
+
Byte byFont; // Font
|
|
498
|
+
Byte byJapanesFont; // Japanese font
|
|
499
|
+
Byte byMode; // Mode
|
|
500
|
+
Byte byDensity; // Density
|
|
501
|
+
Byte byMediaLength; // Media Length
|
|
502
|
+
Byte byStatusType; // Status Type
|
|
503
|
+
Byte byPhaseType; // Phase type
|
|
504
|
+
Byte byPhaseNoHi; // Upper bytes of phase number
|
|
505
|
+
Byte byPhaseNoLow; // Lower bytes of phase number
|
|
506
|
+
Byte byNoticeNo; // Notice number
|
|
507
|
+
Byte byExtByteNum; // Total bytes of extended part
|
|
508
|
+
Byte byLabelColor; // Color of label
|
|
509
|
+
Byte byFontColor; // Color of font
|
|
510
|
+
Byte byHardWareSetting[4]; // Settings of hardware
|
|
511
|
+
Byte byNoUse[2]; // Not Use
|
|
512
|
+
} PTSTATUSINFO, *LPPTSTATUSINFO;
|
|
513
|
+
#endif
|
|
514
|
+
|
|
515
|
+
- (int) getPTStatus:(PTSTATUSINFO *)status
|
|
516
|
+
model:(PRINTERMODEL)model
|
|
517
|
+
channelType:(CHANNELTYPE)channelType
|
|
518
|
+
channelString:(NSString *)channelString; // IPAddress or BTDeviceName
|
|
519
|
+
|
|
520
|
+
// note: wrappers for printImage and printPDFAtPath are NOT provided
|
|
521
|
+
|
|
522
|
+
|
|
523
|
+
|
|
524
|
+
//******* BMS new functionality functions **********
|
|
525
|
+
|
|
526
|
+
//***** Misc Utilities
|
|
527
|
+
- (CGRect) getPrintableRectFromCurrentSettings;
|
|
528
|
+
- (CGRect) getPaperRectFromCurrentSettings;
|
|
529
|
+
|
|
530
|
+
//********************************************************************************
|
|
531
|
+
// SIMPLE APIs
|
|
532
|
+
//
|
|
533
|
+
// These printing APIs will handle the whole job for you (including openChannel, sendDataToChannel, closeChannel).
|
|
534
|
+
// See also the "Manual APIs", which give you more control of the printing process.
|
|
535
|
+
|
|
536
|
+
//***** FILE Printing Functions (see also sendFile and sendFileEx above)
|
|
537
|
+
// NOTE: new prototype in SDK 2.0
|
|
538
|
+
- (int) sendFileWithProgressView:(NSURL *)filePathURL
|
|
539
|
+
channelType:(CHANNELTYPE)channelType
|
|
540
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName
|
|
541
|
+
copies:(int)numCopies
|
|
542
|
+
writeTimeout:(NSTimeInterval)timeout
|
|
543
|
+
usingParentView:(UIViewController *)parentViewController;
|
|
544
|
+
|
|
545
|
+
//***** PDF Printing Functions (see also Manual APIs below)
|
|
546
|
+
|
|
547
|
+
// send PDF file without a ProgresView
|
|
548
|
+
// This is a BLOCKING function only
|
|
549
|
+
// NOTE: SDK 1.1.0 changed this prototype to add "copies" and "collate" parameters.
|
|
550
|
+
// NOTE: The "collate" parameter value only matters when printing multiple copies of a multi-page PDF file.
|
|
551
|
+
- (int) printPDFFilePathURL:(NSURL *)filePathURL
|
|
552
|
+
firstPage:(int)firstPage
|
|
553
|
+
lastPage:(int)lastPage
|
|
554
|
+
timeout:(CFTimeInterval)nTimeout
|
|
555
|
+
copies:(int)copies
|
|
556
|
+
collate:(BOOL)bCollate;
|
|
557
|
+
|
|
558
|
+
// send PDF file with a MODAL ProgressView
|
|
559
|
+
// NOTE: new prototype in SDK 2.0
|
|
560
|
+
- (int) printPDFFileWithProgressView:(NSURL *)filePathURL
|
|
561
|
+
firstPage:(int)firstPage
|
|
562
|
+
lastPage:(int)lastPage
|
|
563
|
+
copies:(int)numCopies
|
|
564
|
+
collate:(BOOL)bCollate
|
|
565
|
+
writeTimeout:(NSTimeInterval)timeout
|
|
566
|
+
usingParentView:(UIViewController *)parentViewController;
|
|
567
|
+
|
|
568
|
+
// Print an ARRAY of NSURLs that reference a PDF file.
|
|
569
|
+
// All pages from EACH PDF file will be printed.
|
|
570
|
+
// NOTE: The same printSettings will apply to EACH PDF file in the array.
|
|
571
|
+
-(int) printPDFURLArray:(NSArray *)array
|
|
572
|
+
timeout:(CFTimeInterval)nTimeout
|
|
573
|
+
copies:(int)copies
|
|
574
|
+
collate:(BOOL)bCollate;
|
|
575
|
+
|
|
576
|
+
|
|
577
|
+
//***** Image Printing Functions (see also Manual APIs below)
|
|
578
|
+
// print Image with a MODAL ProgressView
|
|
579
|
+
// NOTE: new prototype in SDK 2.0
|
|
580
|
+
- (int) printCGImageRefWithProgressView:(CGImageRef)imageRef
|
|
581
|
+
copies:(int)numCopies
|
|
582
|
+
writeTimeout:(NSTimeInterval)timeout
|
|
583
|
+
usingParentView:(UIViewController *)parentViewController;
|
|
584
|
+
|
|
585
|
+
|
|
586
|
+
|
|
587
|
+
// Print 1 or more copies of a single image, without a ProgressView.
|
|
588
|
+
// NOTE: The printCGImageRef:blocking:timeout API has been REMOVED in SDK 2.0.0
|
|
589
|
+
// The printCGImageRef:timeout:copies is now used instead.
|
|
590
|
+
// WARNING: Do NOT use this API to send more than 1 image back-to-back.
|
|
591
|
+
// Instead, see printImageURLArray or sendCGImageRefToChannel below.
|
|
592
|
+
- (int) printCGImageRef:(CGImageRef)imageRef
|
|
593
|
+
timeout:(CFTimeInterval)nTimeout
|
|
594
|
+
copies:(int)copies;
|
|
595
|
+
|
|
596
|
+
// Print an ARRAY of NSURLs that reference an IMAGE file, e.g. JPG, PNG, etc
|
|
597
|
+
// NOTE: The same printSettings will apply to EACH image in the array.
|
|
598
|
+
-(int) printImageURLArray:(NSArray *)array
|
|
599
|
+
timeout:(CFTimeInterval)nTimeout
|
|
600
|
+
copies:(int)copies;
|
|
601
|
+
|
|
602
|
+
//********************************************************************************
|
|
603
|
+
// Manual API Control of the Data Channel. These all work together!!
|
|
604
|
+
//
|
|
605
|
+
// NOTE: ALL "Manual API" prototypes have CHANGED in SDK 2.0!!
|
|
606
|
+
// * Previous SDKs only used WIFI channel, so Manual APIs had "WIFI" in the name.
|
|
607
|
+
// * Since SDK 2.0 now supports WIFI and Bluetooth (and also File), the APIs have all been RENAMED!!
|
|
608
|
+
// * But, they are all very similar to the API names in older SDKs.
|
|
609
|
+
//
|
|
610
|
+
// How to use the Manual APIs:
|
|
611
|
+
// 1. You MUST call openChannelWithTimeout (PDF or Image) or openChannelOfType (PRN) first
|
|
612
|
+
// * For PDF/Image, the printSettings property of BMSPrinterDriver class is used to determine channelType/String
|
|
613
|
+
// * For PRN, printSettings are N/A, so channelType/String need to be specified in the openChannelOfType parameters.
|
|
614
|
+
// 2. Call one (or more) of the other APIs for sending print data to the current channel
|
|
615
|
+
// 3. Call closeChannel
|
|
616
|
+
//
|
|
617
|
+
// Advantages to using the Manual APIs compared to the simpler APIs:
|
|
618
|
+
// 1. Sending data this way allows you to send data in bands and display your own progress indicator.
|
|
619
|
+
// 2. You can use different timeouts for openChannel and sending the data. This allows timing out more quickly if
|
|
620
|
+
// (for example) there is a WIFI connection issue (i.e. not connected to the printer, wrong IPAddress, etc.)
|
|
621
|
+
//
|
|
622
|
+
// *** WARNING: PJ7 models will very likely require a LARGER TIMEOUT for SENDING the print data compared to other models,
|
|
623
|
+
// especially when printing MULTIPLE PAGE jobs. PJ7 will STOP accepting data during printing (i.e. when paper is moving).
|
|
624
|
+
// If the print head overheats during printing, the printer will stop printing until the head cools down, which lengthens
|
|
625
|
+
// the amount of time needed for the timeout.
|
|
626
|
+
// * We recommend setting AT LEAST 60 seconds for the SEND timeout when using PJ7 models, unless you know you will only
|
|
627
|
+
// be printing single page jobs or jobs without a significant page coverage.
|
|
628
|
+
// * We strongly recommend that you test a WORST CASE print job to assure that your SEND timeout setting is large enough.
|
|
629
|
+
|
|
630
|
+
// Use this with PDF/Image. The printSettings property is used to get the channel info.
|
|
631
|
+
- (int) openChannelWithTimeout:(CFTimeInterval)nTimeout;
|
|
632
|
+
|
|
633
|
+
// Use this with PRN, since printSettings are N/A.
|
|
634
|
+
- (int) openChannelOfType:(CHANNELTYPE)channelType
|
|
635
|
+
channelString:(NSString *)channelString // IPAddress or BTDeviceName or FilePath (Print to File)
|
|
636
|
+
timeout:(CFTimeInterval)nTimeout;
|
|
637
|
+
|
|
638
|
+
// Data Generation APIs for Image and PDF, so you can retrieve the print data to send in any way that you prefer.
|
|
639
|
+
- (int) generatePrintData:(NSMutableData *)printData
|
|
640
|
+
fromCGImageRef:(CGImageRef)imageRef;
|
|
641
|
+
|
|
642
|
+
- (int) generatePrintData:(NSMutableData *)printData
|
|
643
|
+
fromPDFPageRef:(CGPDFPageRef) pdfPageRef;
|
|
644
|
+
|
|
645
|
+
// NOTE: ALL other "Manual APIs" below use the CHANNELTYPE specified in printSettings or openChannelOfType.
|
|
646
|
+
|
|
647
|
+
|
|
648
|
+
// This must be called when finished sending data to the channel opened by openChannelWithTimeout or
|
|
649
|
+
// openChannelOfType
|
|
650
|
+
// TODO: Consider returning "int" code instead of "void". May need to propagate errors that may occur when closing
|
|
651
|
+
// bluetooth channel back to ISV.
|
|
652
|
+
// But, these errors typically will occur only when kCloseBluetoothChannelFlushMode_UseStatusRequest is specified,
|
|
653
|
+
// and this is not currently the default setting for any of the MFi models. So, "void" is OK for now.
|
|
654
|
+
- (void) closeChannel;
|
|
655
|
+
|
|
656
|
+
// This is the best API to use if you want to make your own progress indicator.
|
|
657
|
+
- (int) sendDataToChannel:(const uint8_t *)data
|
|
658
|
+
length:(int)length
|
|
659
|
+
sendDataMode:(SENDDATAMODE)sendDataMode
|
|
660
|
+
timeout:(CFTimeInterval)nTimeout
|
|
661
|
+
errorCode:(int *)pErrorCode;
|
|
662
|
+
|
|
663
|
+
// similar to sendDataToChannel, but easier to use since you don't have to manage the buffer.
|
|
664
|
+
// However, it is not as useful if you wish to make your own progress indicator.
|
|
665
|
+
// NOTE: The data will actually be sent in 16K bands, and the timeout parameter will apply to each band separately.
|
|
666
|
+
- (int) sendNSDataToChannel:(NSData *)data
|
|
667
|
+
sendDataMode:(SENDDATAMODE)sendDataMode
|
|
668
|
+
timeout:(CFTimeInterval)nTimeout;
|
|
669
|
+
|
|
670
|
+
|
|
671
|
+
// simple manual API to send a CGImageRef to already open channel. Not useful for progress indicator.
|
|
672
|
+
// But, you can use this to print more than 1 image back-to-back.
|
|
673
|
+
- (int) sendCGImageRefToChannel:(CGImageRef)imageRef
|
|
674
|
+
timeout:(CFTimeInterval)nTimeout
|
|
675
|
+
copies:(int)copies;
|
|
676
|
+
|
|
677
|
+
// simple manual API to send a PDF file URL to already open channel. Not useful for progress indicator.
|
|
678
|
+
// But, you can use this to print more than 1 PDF file back-to-back.
|
|
679
|
+
- (int) sendPDFFilePathURLToChannel:(NSURL *)filePathURL
|
|
680
|
+
firstPage:(int)firstPage
|
|
681
|
+
lastPage:(int)lastPage
|
|
682
|
+
timeout:(CFTimeInterval)nTimeout
|
|
683
|
+
copies:(int)copies
|
|
684
|
+
collate:(BOOL)bCollate;
|
|
685
|
+
|
|
686
|
+
// simple manual API to send a PRN file URL to already open channel. Not useful for progress indicator.
|
|
687
|
+
// But, you can use this to print more than 1 PRN file back-to-back.
|
|
688
|
+
- (int) sendPRNFilePathURLToChannel:(NSURL *)filePathURL
|
|
689
|
+
timeout:(CFTimeInterval)nTimeout;
|
|
690
|
+
|
|
691
|
+
// Used with Manual APIs to handle possible "Cancel" button on a Custom Progress ViewController, if desired.
|
|
692
|
+
// Sends data to printer to clear out a partial page and eject the paper.
|
|
693
|
+
// NOTE: Only use this with PDF and IMAGE printing. It is N/A when sending PRN data.
|
|
694
|
+
- (int) sendCancelPrintingDataToChannel;
|
|
695
|
+
|
|
696
|
+
|
|
697
|
+
// Primarily used for RJ4 MCR reader applications!!
|
|
698
|
+
- (int) readDataFromChannel:(uint8_t *)buffer
|
|
699
|
+
maxLength:(int)maxLength
|
|
700
|
+
errorCode:(int *)pErrorCode;
|
|
701
|
+
|
|
702
|
+
|
|
703
|
+
// End of the Manual APIs
|
|
704
|
+
//********************************************************************************
|
|
705
|
+
|
|
706
|
+
@end
|
|
707
|
+
|
|
708
|
+
/////////////////////////////////////////////////////////////////////////////
|
|
709
|
+
// This defines the DataControllerProtocol that MUST be used for developing
|
|
710
|
+
// new printer drivers for a printer model. The DataControllers are used to
|
|
711
|
+
// generate model-specific print data based on the current printSettings.
|
|
712
|
+
@protocol DataControllerProtocol <NSObject>
|
|
713
|
+
// everything is required!
|
|
714
|
+
@required
|
|
715
|
+
|
|
716
|
+
// Properties
|
|
717
|
+
@property (nonatomic, assign) BOOL isFirstPage;
|
|
718
|
+
@property (nonatomic, assign) BOOL isLastPage;
|
|
719
|
+
@property (nonatomic, retain) PrintSettings *printSettings;
|
|
720
|
+
|
|
721
|
+
// Methods
|
|
722
|
+
- (CGRect) getPaperRectFromCurrentSettings;
|
|
723
|
+
- (CGRect) getPrintableRectFromCurrentSettings;
|
|
724
|
+
- (BOOL) generatePrintData: (NSMutableData *)printData fromCGContextRef: (CGContextRef) context;
|
|
725
|
+
- (BOOL) generateCancelPrintingData:(NSMutableData *)printData;
|
|
726
|
+
@end
|
|
727
|
+
/////////////////////////////////////////////////////////////////////////////
|