setOptions method

Future<SetOptionsResponse> setOptions(
  1. String scannerHandle,
  2. List<OptionSetting> options
)

Sends the list of new option values in options as a bundle to be set on scannerHandle. Each option will be set by the backend the order specified. Returns a backend response indicating the result of each option setting and a new set of final option values after all options have been updated. |scannerHandle| : Open scanner handle previously returned from openScanner. |options| : A list of OptionSettings that will be applied to scannerHandle. |callback| : Called with the result.

Implementation

Future<SetOptionsResponse> setOptions(
  String scannerHandle,
  List<OptionSetting> options,
) async {
  var $res = await $js.chrome.documentScan
      .setOptions(
        scannerHandle,
        options.toJSArray((e) => e.toJS),
      )
      .toDart;
  return SetOptionsResponse.fromJS($res);
}