Everything works OK after serious changes:
- all components, componentCfg-s and parameter providers use base classes - less boilerplate code, simpler access to test/procedure parameters from code - CreateTestParams(test), CreateProcedureParams(procedure) methods added - TestBenchSim class is made static, it is not inheritted by any device anymore
This commit is contained in:
@@ -2,18 +2,17 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Printing;
|
||||
using log4net;
|
||||
using TBF.BenchControl;
|
||||
|
||||
namespace TBF.BenchControl.ResultsPrinters.Basic
|
||||
{
|
||||
public class Printer : Generic.IComponent, IOperation, GenericDevices.IResultsPrinter
|
||||
public class Printer : ComponentBase, IOperation, GenericDevices.IResultsPrinter
|
||||
{
|
||||
private static readonly ILog log = LogManager.GetLogger(typeof(Printer));
|
||||
public override string ToString() { return string.Format("ResultsPrinters.Basic({0})", Cfg.ToString(1)); }
|
||||
|
||||
readonly PrinterCfg printerCfg;
|
||||
public Generic.IComponentCfg Cfg { get { return printerCfg; } }
|
||||
|
||||
public static void ResetStaticProperties() { }
|
||||
|
||||
public string Name { get { return printerCfg.Name; } }
|
||||
|
||||
/// <summary>
|
||||
/// Data to print
|
||||
@@ -24,9 +23,10 @@ namespace TBF.BenchControl.ResultsPrinters.Basic
|
||||
string title;
|
||||
|
||||
public Printer(PrinterCfg cfg)
|
||||
: base(cfg)
|
||||
{
|
||||
if (cfg == null) throw new ArgumentNullException("cfg");
|
||||
this.printerCfg = cfg;
|
||||
printerCfg = cfg;
|
||||
log.Debug(this.ToString());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user