using System.Collections.Generic; using System.Collections.ObjectModel; using System.IO; namespace Inspectron.Camera.Emulation { public class EmulationCameraProvider:ICameraProvider { private EmulationCamera _emulationCamera; public EmulationCameraProvider(params string[] emulationFolders) { List cameras = new List(); foreach (string s in emulationFolders) { _emulationCamera = new EmulationCamera(this); _emulationCamera.Name = "Emulation "+Path.GetFileNameWithoutExtension(s); _emulationCamera.SetFolder(s); cameras.Add(_emulationCamera); } Cameras=new ReadOnlyCollection(cameras); } public string Name { get; } = "Emulation camera provider"; public ReadOnlyCollection Discover() { return Cameras; } public ReadOnlyCollection Cameras { get; } } }