public ServicePublisher(IServiceCore core) { _service = core; LocalName = Environment.MachineName; _service.PacketReceived += _service_PacketReceived; //_listener.FindService //listener.FindServices += listener_FindServices; }
public ServiceRequestRepeater(IServiceCore service, string protocol, ITimer timer) { _service = service; _timer = timer; _proto = protocol; _waiting = !_service.Connected; _timer.Fired += _timer_Fired; _service.NetworkStatusChanged += _service_NetworkStatusChanged; _waiting = true; }
public void Init(IServiceCore service) { ResSections = service .AppResourceSectionService .Select(s => new ResSectionDto { Id = s.Id, Name = s.Name, DateCreate = s.DateCreate }) .ToList(); }
public SectionEditModel(IServiceCore service, int id = 0) { var settings = service.SectionSettingsService.Settings; Overflow = service.SectionService .Where(s => s.IsActive && !s.IsDefault && !s.IsDelete) .Count() >= settings.MaxAllowedSections; OverflowOnTop = service .SectionService .Where(x => x.IsActive && !x.IsDefault && !x.IsDelete && x.OnAside) .Count() >= settings.MaxAllowedSectionsOnTop; TotalAll = service.SectionService .Where(s => s.IsActive && !s.IsDelete && !s.IsDefault) .Count(); TotalOnTop = service.SectionService .Where(s => s.IsActive && !s.IsDelete && !s.IsDefault && s.OnAside) .Count(); TotalOther = service.SectionService .Where(s => s.IsActive && !s.IsDelete && !s.IsDefault && !s.OnAside) .Count(); AllowSections = settings.MaxAllowedSections; AllowOnTopSection = settings.MaxAllowedSectionsOnTop; if (id > 0) { var section = service.SectionService[id]; if (section != null) { Id = section.Id; Name = section.Name; Description = section.Description; OnTop = section.OnAside; IsActive = section.IsActive; IsDelete = section.IsDelete; ImageId = section.ImageId; } } }
public CitiesController(IServiceCore serviceCore) { _serviceCore = serviceCore ?? throw new ArgumentNullException(nameof(serviceCore)); }
public ServiceWatchManager(IServiceCore core) { _service = core; _service.PacketReceived += _service_PacketReceived; _service.Start(); }
public ControllerCore(IServiceCore <TViewModel, TEntity, TId> service) => _service = service;
public ResSectionController(IServiceCore service) { this.service = service; }
public SectionController(IServiceCore service, ISectionService sectionService) { this.service = service; this.sectionService = sectionService; }
public UsersIndexViewModel(IServiceCore service) { this.service = service; //TODO описать для юзеров }