Exemple #1
0
 public ExprTimePeriodEvalDeltaConst Make(
     string validateMsgName,
     string validateMsgValue,
     AgentInstanceContext agentInstanceContext)
 {
     object time = _secondsEvaluator.Evaluate(new EvaluateParams(null, true, agentInstanceContext));
     if (!ExprTimePeriodUtil.ValidateTime(time, agentInstanceContext.StatementContext.TimeAbacus))
     {
         throw new EPException(ExprTimePeriodUtil.GetTimeInvalidMsg(validateMsgName, validateMsgValue, time));
     }
     return new ExprTimePeriodEvalDeltaConstGivenDelta(_timeAbacus.DeltaForSecondsNumber(time));
 }
 public ExprTimePeriodEvalDeltaConstGivenDtxAdd(
     ExprTimePeriodImpl.TimePeriodAdder[] adders,
     int[] added,
     TimeZoneInfo timeZone,
     TimeAbacus timeAbacus)
 {
     _iLock             = LockManager.CreateLock(MethodBase.GetCurrentMethod().DeclaringType);
     _adders            = adders;
     _added             = added;
     _dateTime          = new DateTimeEx(DateTimeOffset.Now, timeZone);
     _timeAbacus        = timeAbacus;
     _indexMicroseconds = ExprTimePeriodUtil.FindIndexMicroseconds(adders);
 }
Exemple #3
0
 public ExprTimePeriodEvalDeltaNonConstDtxAdd(TimeZoneInfo timeZone, ExprTimePeriodImpl parent)
 {
     _parent            = parent;
     _dateTime          = new DateTimeEx(DateTimeOffsetHelper.Now(timeZone), timeZone);
     _indexMicroseconds = ExprTimePeriodUtil.FindIndexMicroseconds(parent.Adders);
 }