AdvertisementData constructor

AdvertisementData({
  1. String? localName,
  2. Int32Value? txPowerLevel,
  3. bool? connectable,
  4. Map<int, List<int>>? manufacturerData,
  5. Map<String, List<int>>? serviceData,
  6. Iterable<String>? serviceUuids,
})

Implementation

factory AdvertisementData({
  $core.String? localName,
  Int32Value? txPowerLevel,
  $core.bool? connectable,
  $core.Map<$core.int, $core.List<$core.int>>? manufacturerData,
  $core.Map<$core.String, $core.List<$core.int>>? serviceData,
  $core.Iterable<$core.String>? serviceUuids,
}) {
  final _result = create();
  if (localName != null) {
    _result.localName = localName;
  }
  if (txPowerLevel != null) {
    _result.txPowerLevel = txPowerLevel;
  }
  if (connectable != null) {
    _result.connectable = connectable;
  }
  if (manufacturerData != null) {
    _result.manufacturerData.addAll(manufacturerData);
  }
  if (serviceData != null) {
    _result.serviceData.addAll(serviceData);
  }
  if (serviceUuids != null) {
    _result.serviceUuids.addAll(serviceUuids);
  }
  return _result;
}