Exemple #1
0
        public void UpdateStatus(MicropartType micropartType, Action <MicropartStatusInfo> statusUpdateAction)
        {
            var micropartStatusName         = _micropartMetadata[micropartType];
            var microServiceComponentStatus = Get(micropartStatusName);

            statusUpdateAction(microServiceComponentStatus);
        }
Exemple #2
0
 private void UpdateStatus(MicropartType micropartType, IMicroPartInfo microParInfo)
 {
     UpdateStatus(micropartType, micropartStatusInfo =>
     {
         micropartStatusInfo.MicroPartInstanceName = microParInfo.MicroServicePartName;
         micropartStatusInfo.IsEnabled             = microParInfo.IsEnabled;
     });
 }
Exemple #3
0
        public IMicroPartInfo UpdateStatus <T>(MicropartType micropartType)
            where T : class, IMicroPartInfo
        {
            var micropartInfo = _microServiceParts.FirstOfType <T>();

            UpdateStatus(micropartType, micropartStatusInfo =>
            {
                micropartStatusInfo.MicroPartInstanceName = micropartInfo.MicroServicePartName;
                micropartStatusInfo.IsEnabled             = micropartInfo.IsEnabled;
            });
            return(micropartInfo);
        }