コード例 #1
0
        public static void Unregister(Service service)
        {
            if (!IsRegistered(service))
            {
                throw new ServiceSchedulerException("Service " + service.Information.ServiceName + "  is not registered!");
            }

            lock (ServicesBindings) ServicesBindings.Remove(ServicesBindings.FirstOrDefault(s => s.Service == service));
            ServiceEvents.RaiseServiceUnRegistered(service);
        }
コード例 #2
0
        public static void Unregister(Service service)
        {
            if (!IsRegistered(service))
            {
                throw new ServiceSchedulerException("Service " + service.Information.ServiceName + "  is not registered!");
            }

            lock (ServicesBindings) ServicesBindings.Remove(ServicesBindings.FirstOrDefault(s => s.Service == service));
            ServiceEvents.RaiseServiceUnRegistered(service);
            SettingsChangedManager.SetNeedsContactSync(service, true);

            Analytics.RaiseServiceEvent(
                Analytics.EventAction.ServiceUnregistered,
                Analytics.EventCategory.Services,
                service);
        }