コード例 #1
0
ファイル: MonitorService.cs プロジェクト: RacerData/RacerData
 public void Unregister(IMonitorClient client)
 {
     LiveFeedStarted     -= client.Monitor_LiveFeedStarted;
     LiveFeedUpdated     -= client.Monitor_LiveFeedUpdated;
     ServiceStateChanged -= client.Monitor_ServiceStateChanged;
     ServiceActivity     -= client.Monitor_ServiceActivity;
 }
コード例 #2
0
 private MonitorManager(RestClient restClient, string subscriptionId) :
     base(restClient, subscriptionId, GetInnerClient(restClient, subscriptionId))
 {
     InnerEx = new MonitorClient(new Uri(restClient.BaseUri),
                                 restClient.Credentials,
                                 restClient.RootHttpHandler,
                                 restClient.Handlers.ToArray())
     {
         SubscriptionId = subscriptionId
     };
 }
コード例 #3
0
        /// <summary>
        /// Dispose the resources
        /// </summary>
        /// <param name="disposing">Indicates whether the managed resources should be disposed or not</param>
        protected override void Dispose(bool disposing)
        {
            if (!this.disposed)
            {
                if (this.MonitorClient != null)
                {
                    this.MonitorClient.Dispose();
                    this.MonitorClient = null;
                }

                this.disposed = true;
            }
            base.Dispose(disposing);
        }
コード例 #4
0
 public MonitorService(ILogger <MonitorService> logger, IMonitorClient client)
 {
     _logger = logger;
     _Client = client;
 }