Package io.anyline2.viewplugin
Class ScanViewPlugin
- java.lang.Object
-
- io.anyline2.viewplugin.ViewPluginBase
-
- io.anyline2.viewplugin.ScanViewPlugin
-
public class ScanViewPlugin extends ViewPluginBase
-
-
Field Summary
Fields Modifier and Type Field Description ScanPlugin
scanPlugin
ScanViewPluginConfig
scanViewPluginConfig
-
Fields inherited from class io.anyline2.viewplugin.ViewPluginBase
errorReceived, resultReceived, resultsReceived, runSkippedReceived, scanInfoReceived, visualFeedbackReceived
-
-
Constructor Summary
Constructors Constructor Description ScanViewPlugin(ScanViewPluginConfig scanViewPluginConfig)
ScanViewPlugin(org.json.JSONObject jsonConfig)
ScanViewPlugin(org.json.JSONObject jsonConfig, AssetContext assetContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
calcCutOutAndImageCropBounds(android.content.Context context, int frameWidth, int frameHeight, int viewWidth, int viewHeight, float scale)
java.util.List<ScanViewPlugin>
children()
void
dispose()
java.util.List<ScanViewPlugin>
getActiveScanViewPlugin()
CutoutRect
getCutoutRect()
ALRect
getROI()
java.lang.String
id()
boolean
isScanPluginRunning()
boolean
isStarted()
void
setROI(ALRect roi)
void
setUIChangeListener(UIChangeListener listener)
void
start()
void
stop()
void
subscribeToImageProvider(ImageProvider imageProvider)
void
subscribeToNativeBarcodeProvider(NativeBarcodeProvider nativeBarcodeProvider, java.util.List<BarcodeFormat> supportedFormats)
void
unsubscribeFromImageProvider(ImageProvider imageProvider)
void
unsubscribeFromNativeBarcodeProvider(NativeBarcodeProvider nativeBarcodeProvider)
-
Methods inherited from class io.anyline2.viewplugin.ViewPluginBase
getFirstActiveScanViewPlugin, playBeepSound, vibrate
-
-
-
-
Field Detail
-
scanPlugin
public ScanPlugin scanPlugin
-
scanViewPluginConfig
public ScanViewPluginConfig scanViewPluginConfig
-
-
Constructor Detail
-
ScanViewPlugin
public ScanViewPlugin(org.json.JSONObject jsonConfig) throws AnylineException, org.json.JSONException
- Throws:
AnylineException
org.json.JSONException
-
ScanViewPlugin
public ScanViewPlugin(org.json.JSONObject jsonConfig, AssetContext assetContext) throws AnylineException, org.json.JSONException
- Throws:
AnylineException
org.json.JSONException
-
ScanViewPlugin
public ScanViewPlugin(ScanViewPluginConfig scanViewPluginConfig) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-
Method Detail
-
id
public java.lang.String id()
- Specified by:
id
in classViewPluginBase
-
getActiveScanViewPlugin
public java.util.List<ScanViewPlugin> getActiveScanViewPlugin()
- Specified by:
getActiveScanViewPlugin
in classViewPluginBase
-
children
public java.util.List<ScanViewPlugin> children()
- Specified by:
children
in classViewPluginBase
-
subscribeToImageProvider
public void subscribeToImageProvider(ImageProvider imageProvider)
- Specified by:
subscribeToImageProvider
in classViewPluginBase
-
unsubscribeFromImageProvider
public void unsubscribeFromImageProvider(ImageProvider imageProvider)
- Specified by:
unsubscribeFromImageProvider
in classViewPluginBase
-
subscribeToNativeBarcodeProvider
public void subscribeToNativeBarcodeProvider(NativeBarcodeProvider nativeBarcodeProvider, java.util.List<BarcodeFormat> supportedFormats)
- Specified by:
subscribeToNativeBarcodeProvider
in classViewPluginBase
-
unsubscribeFromNativeBarcodeProvider
public void unsubscribeFromNativeBarcodeProvider(NativeBarcodeProvider nativeBarcodeProvider)
- Specified by:
unsubscribeFromNativeBarcodeProvider
in classViewPluginBase
-
setUIChangeListener
public void setUIChangeListener(UIChangeListener listener)
- Specified by:
setUIChangeListener
in classViewPluginBase
-
getROI
public ALRect getROI()
-
setROI
public void setROI(ALRect roi)
-
getCutoutRect
public CutoutRect getCutoutRect()
-
calcCutOutAndImageCropBounds
public void calcCutOutAndImageCropBounds(android.content.Context context, int frameWidth, int frameHeight, int viewWidth, int viewHeight, float scale)
-
isScanPluginRunning
public boolean isScanPluginRunning()
- Specified by:
isScanPluginRunning
in classViewPluginBase
-
isStarted
public boolean isStarted()
- Specified by:
isStarted
in classViewPluginBase
-
start
public void start()
- Specified by:
start
in classViewPluginBase
-
stop
public void stop()
- Specified by:
stop
in classViewPluginBase
-
dispose
public void dispose()
- Specified by:
dispose
in classViewPluginBase
-
-