protected virtual void RaiseServicesDiscovered(ServicesDiscoveredEventArgs args) { if (ServicesDiscovered != null) { ServicesDiscovered(this, args); } }
public void OnServicesDiscovered(object sender, ServicesDiscoveredEventArgs args) { if (_gatt != null) { _services = _gatt.Services.Select(service => new Service(service, _gatt, _gattCallback)).ToList<IService>(); } _gattCallback.ServicesDiscovered -= OnServicesDiscovered; ServicesDiscovered(this, args); }