///
/// Copyright (c) 2013-2016 Sensus Metering Systems
///
using System.Collections.Generic;
namespace TBF.BenchControl.Generic
{
public interface IComponentFactory
{
string ClassName { get; } /// Name of the class of components (for instance "Valve")
///
/// Returns a dummy component without configuration useful only for runtime class type identification
/// Usage: if (TbfComponents.CmpntFactoryFromClassName(className).DummyComponent() is IValve) { ... }
///
IComponent DummyComponent();
///
/// Returns a component with the given configuration
///
/// Component comfiguration
/// List of all component
/// Component instance
IComponent GetComponent(IComponentCfg cfg, IList components);
///
/// Returns the default configuration
///
IComponentCfg DefaultConfig();
///
/// Converts an Entities.Component object into an instance of an appropriate class implementing IComponentCfg
///
IComponentCfg CmpntCfgFromCmpntEntity(Config.Entities.Component component);
void ResetStaticProperties();
}
}