initialize method
Must be called before you can use any function from this class.
_callback
This will be invoked everytime sendTransaction is called.
Implementation
PosUsbOTGConnector initialize(PosUsbConnectionCallback callback) {
if (!Platform.isAndroid) {
throw PosConnectorException(PosConnectorException.unsupportedPlatform,
"Only Android is supported.");
}
_callback = callback;
_abaPosSdkFlutterPlugin = _abaPosSdkFlutterPlugin ?? AbaPosSdkFlutter();
_registerUsbAttachedOrDetachedEvent();
return this;
}