setSuffixFromKeys method

Future<CommandResponse> setSuffixFromKeys({
  1. required dynamic deviceId,
  2. required List<DirectInputKey> keys,
  3. FormattableSymbology symbology = FormattableSymbology.allCodes,
})

Sets the suffix formatting using a list of DirectInputKey.

deviceId - The identifier of the target device. keys - A list of DirectInputKey values to be used for the suffix.

Returns a CommandResponse indicating the success or failure of the operation.

Implementation

Future<CommandResponse> setSuffixFromKeys(
    {required deviceId,
    required List<DirectInputKey> keys,
    FormattableSymbology symbology = FormattableSymbology.allCodes}) async {
  final directInputKeysCodes =
      _getDirectInputKeysCodes(keys, _maxSuffixChars);
  return sendCommand(deviceId, _suffixSymbologyCodesMap[symbology]!,
      parameters: directInputKeysCodes);
}