Beispiel #1
0
 /// <summary>Raises the <see cref="PinRequested" /> event.</summary>
 /// <param name="sender">The object that raised the event.</param>
 /// <param name="macAddress">MAC Address of the inquired device</param>
 /// <param name="name">Name of the inquired device</param>
 protected virtual void OnDeviceInquired(Bluetooth sender, string macAddress, string name)
 {
     if (_onDeviceInquired == null)
     {
         _onDeviceInquired = OnDeviceInquired;
     }
     DeviceInquired?.Invoke(sender, macAddress, name);
 }
Beispiel #2
0
 /// <summary>
 /// Raises the <see cref="PinRequested"/> event.
 /// </summary>
 /// <param name="sender">The object that raised the event.</param>
 /// <param name="macAddress">MAC Address of the inquired device</param>
 /// <param name="name">Name of the inquired device</param>
 protected virtual void OnDeviceInquired(Bluetooth sender, string macAddress, string name)
 {
     if (onDeviceInquired == null)
     {
         onDeviceInquired = new DeviceInquiredHandler(OnDeviceInquired);
     }
     if (Program.CheckAndInvoke(DeviceInquired, onDeviceInquired, sender, macAddress, name))
     {
         DeviceInquired(sender, macAddress, name);
     }
 }
 /// <summary>
 /// Raises the <see cref="PinRequested"/> event.
 /// </summary>
 /// <param name="sender">The object that raised the event.</param>  
 /// <param name="macAddress">MAC Address of the inquired device</param>
 /// <param name="name">Name of the inquired device</param>
 protected virtual void OnDeviceInquired(Bluetooth sender, string macAddress, string name)
 {
     if (onDeviceInquired == null) onDeviceInquired = new DeviceInquiredHandler(OnDeviceInquired);
     if (Program.CheckAndInvoke(DeviceInquired, onDeviceInquired, sender, macAddress, name))
     {
         DeviceInquired(sender, macAddress, name);
     }
 }