showLogMessages method

Future<void> showLogMessages(
  1. bool show
)

Sets whether to show log messages.

show: A boolean indicating whether to show log messages.

Example usage:

bool showLogs = true;
_barkoder.showLogMessages(showLogs);
print('Log messages visibility set to: $showLogs');

Implementation

Future<void> showLogMessages(bool show) {
  if (_isBarkoderViewNotMounted) {
    return Future.error(PlatformException(
        code: BarkoderErrors.barkoderViewNotMounted,
        message: BarkoderErrors.barkodeViewNotMountedDesc));
  }

  return _methodChannel.invokeMethod('showLogMessages', show);
}