Methods CreateDbEntity and CreateFromDbEntity moved from XyzCfg to ComponentCfgBase, factories modified accordingly.

This commit is contained in:
Milan Hanajik
2014-12-29 18:33:27 +01:00
parent 8ef0cea1ff
commit 0ac7ba05d6
67 changed files with 540 additions and 1266 deletions
@@ -16,9 +16,7 @@ namespace TBF.BenchControl.MettlerToledo
public IComponentCfg DefaultConfig(IList<Entities.Component> components)
{
return new BalanceCfg(this, "Balance1", 3, 2400, System.IO.Ports.Parity.Even, 7,
System.IO.Ports.StopBits.One, System.IO.Ports.Handshake.XOnXOff,
200.0f, 20.0f, 180); // kg, kg, s
return new BalanceCfg(this);
}
public IComponentCfgCtrl CreateCfgCtrl()
@@ -33,7 +31,7 @@ namespace TBF.BenchControl.MettlerToledo
public IComponentCfg CmpntCfgFromCmpntEntity(Entities.Component component)
{
return MettlerToledo.BalanceCfg.CreateFromDbEntity(component, this);
return ComponentCfgBase.CreateFromDbEntity(typeof(BalanceCfg), component, this);
}
public void ResetStaticProperties() { BalanceNewDev.ResetStaticProperties(); }