示例#1
0
 //toDo Синхронизировать с наполнением класса
 public AddStrategyClass(AddStrategyClass cln)
     : this(ControllerOfOutput.Instance)
 {
     this.usemask       = cln.usemask;
     this.workInterval  = cln.workInterval;
     this.fileMask      = cln.fileMask;
     this.fileNameUsage = cln.fileNameUsage;
     this.dateRange     = cln.dateRange;
     //this.workDateTime = cln.workDateTime;
     this.checkDateCondition = cln.checkDateCondition;
     this.useCreationDate    = cln.useCreationDate;
 }
示例#2
0
        private DateTime ComputePrevDate(eWorkInterval _int)
        {
            switch (this.workInterval)
            {
            case eWorkInterval.Days:
                return(GlobalUtils.GetNowUtcDateTime().AddDays(-1));

            case eWorkInterval.Months:
                return(GlobalUtils.GetNowUtcDateTime().AddMonths(-1));

            case eWorkInterval.Years:
                return(GlobalUtils.GetNowUtcDateTime().AddYears(-1));

            default:
                return(new DateTime());
            }
        }
 public void ParseWorkIntervalEnum_BadEnterString_EqualFirstPar(eWorkInterval itn, string _s)
 {
     Assert.AreEqual(itn, GlobalUtils.ParseWorkIntervalEnum(_s));
 }