tbf/TestBenchFramework/BenchControl/ResultsPrinters/Basic/PrinterCfg.cs
Milan Hanajik 7b6c23f3b2 Printing Purchase orders always in landscape OK. Version 1.3.16.
Printing at the end of cycle can be switched off - Supress printing parameter of ResultsPrinter.Basic component.
2015-04-19 16:49:43 +02:00

45 lines
1.1 KiB
C#

///
/// Copyright (c) 2013-2015 Sensus Metering Systems
///
using System;
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
using TBF.BenchControl.Generic;
namespace TBF.BenchControl.ResultsPrinters.Basic
{
public class PrinterCfg : ComponentCfgBase, Generic.IComponentCfg
{
public IComponent GetComponent(IList<IComponent> components) { return new Printer(this); }
public IComponentCfgCtrl GetControl() { return new PrinterCfgCtrl(); }
///
/// Serialized parameters
///
public bool SupressPrinting; /// Bypass printing when true
/// Private parameterless constructor invoked by all other (public) constructors
PrinterCfg()
{
Name = "BasicResultsPrinter";
ParentName = string.Empty;
SupressPrinting = false;
}
public PrinterCfg(IComponentFactory factory)
: this()
{
this.Factory = factory;
}
public string ToString(int i)
{
return string.Format("Name={0}, SupressPrinting={1}",
Name,
SupressPrinting ? "yes" : "no"
);
}
}
}