public ReportSpecification(DateTime fromDateTime, DateTime toDateTime, ReportResolution resolution, TFilter[] filters, TFilter[] excludeFilters)
 {
     _fromDateTime = fromDateTime;
     _toDateTime   = toDateTime;
     _resolution   = resolution;
     buildFilterList(filters);
     buildListOfMeasurementsForTracker(new[] { typeof(TTracker) });
     TypeNames = new[] { typeof(TTracker).FullName };
     buildExcludeFilterList(excludeFilters);
 }
Esempio n. 2
0
        public AggregationResults <T1> Report(DateTime fromUtc, DateTime toUtc, ReportResolution resolution, TimeSpan?offsetTotalsByHours)
        {
            var reportSpecs = new ReportSpecification <T, T1>(fromUtc, toUtc, resolution, Filter);

            if (offsetTotalsByHours != null)
            {
                reportSpecs.OffsetTotalsByHours = offsetTotalsByHours.GetValueOrDefault();
            }

            return(Reporter <T, T1> .Report(fromUtc, toUtc, reportSpecs));
        }
 public ReportSpecification(DateTime fromDateTime, DateTime toDateTime, ReportResolution resolution, TFilter[] filters, TFilter[] excludeFilters, TimeSpan offsetTotalsByHours)
 {
     _fromDateTime = fromDateTime;
     _toDateTime   = toDateTime;
     _resolution   = resolution;
     buildFilterList(filters);
     buildListOfMeasurementsForTracker(new[] { typeof(TTracker) });
     TypeNames = new[] { typeof(TTracker).FullName };
     buildExcludeFilterList(excludeFilters);
     if (offsetTotalsByHours.CompareTo(new TimeSpan(-12, 0, 1)) == 1 && offsetTotalsByHours.CompareTo(new TimeSpan(14, 0, 1)) == -1)
     {
         OffsetTotalsByHours = offsetTotalsByHours;
     }
 }
Esempio n. 4
0
 public MongoTrackerResults(IReportSpecification specification)
 {
     _fromDateUtc = specification.FromDateUtc;
     _toDateUtc   = specification.ToDateUtc;
     _resolution  = specification.Resolution;
 }
Esempio n. 5
0
        public static AggregationResults <T1> Report(DateTime fromUtc, DateTime toUtc, ReportResolution resolution)
        {
            var reportSpecs = new ReportSpecification <EmptyFilter, T1>(fromUtc, toUtc, resolution);

            return(Reporter <EmptyFilter, T1> .Report(fromUtc, toUtc, reportSpecs));
        }
Esempio n. 6
0
 public AggregationResults <T1> Report(DateTime fromUtc, DateTime toUtc, ReportResolution resolution)
 {
     return(Report(fromUtc, toUtc, resolution, null));
 }
Esempio n. 7
0
 public MongoTrackerResults(IReportSpecification specification)
 {
     _fromDateUtc = specification.FromDateUtc;
     _toDateUtc = specification.ToDateUtc;
     _resolution = specification.Resolution;
 }
 public ReportSpecification(DateTime fromDateTime, DateTime toDateTime, ReportResolution resolution)
     : this(fromDateTime, toDateTime, resolution, new TFilter[] {})
 {
 }