public PublishedCameraConfigurationViewModel(PublishedCameraModel model, MediaService service, Camera camera) { if (model == null) throw new ArgumentNullException("model"); if (service == null) throw new ArgumentNullException("service"); if (camera == null) throw new ArgumentNullException("camera"); Model = model; SelectedService = service; SelectedCamera = camera; DestinationPort = 9999; }
private static MediaService GetMediaPublisherServiceSync(string hostUri) { MediaService service = null; foreach (var item in ServiceProvider.GetServices<IMediaPublisherService>()) { if (item.Value.Uri.ToString() == hostUri) { service = new MediaService() { Id = item.Value.Uri.ToString(), Name = item.Value.Name, ContractName = item.Value.Name, HostName = item.Value.HostName, Uri = item.Value.Uri, }; } } return service; }
public PublishPair(MediaService service, Camera camera) : this() { Service = service; Camera = camera; }
public override void Cleanup() { base.Cleanup(); Model = null; SelectedService = null; SelectedCamera = null; }