/// /// Copyright (c) 2019 Sensus Slovensko a.s. /// using System; using Users; using log4net; namespace TBF.BenchControl.BackupAndSecurity.Default { /// /// Holds backup and security options. /// public class Component : ComponentBase, GenericDevices.IBackupAndSecurity { private static readonly ILog log = LogManager.GetLogger(typeof(Component)); public override string ToString() { return string.Format("BackupAndSecurity.Default({0})", Cfg.ToString(1)); } readonly ComponentCfg myCfg; public int MinPasswdLength { get { return myCfg.MinPasswdLength; } } public int PasswdExpirationPeriodDays { get { return myCfg.PasswdExpirationPeriodDays; } } public Component() { } public Component(Generic.IComponentCfg cfg) : base(cfg) { myCfg = cfg as ComponentCfg; GlobalData.MinPasswdLength = myCfg.MinPasswdLength; GlobalData.PasswdExpirationPeriodDays = myCfg.PasswdExpirationPeriodDays; log.Debug(this.ToString()); } } }