예제 #1
0
        private DataCoverageResult GetCoverage(ICellRequest cell)
        {
            var timeR = timeCoverageProvider.GetCoverage(cell.Time);
            var latR  = latCoverageProvider.GetCoverage(cell.LatMin, cell.LatMax);
            var lonR  = lonCoverageProvider.GetCoverage(cell.LonMin, cell.LonMax);

            if (timeR == DataCoverageResult.OutOfData || latR == DataCoverageResult.OutOfData || lonR == DataCoverageResult.OutOfData)
            {
                return(DataCoverageResult.OutOfData);
            }
            else if (timeR == DataCoverageResult.DataWithoutUncertainty || latR == DataCoverageResult.DataWithoutUncertainty || lonR == DataCoverageResult.DataWithoutUncertainty)
            {
                return(DataCoverageResult.DataWithoutUncertainty);
            }
            else
            {
                return(DataCoverageResult.DataWithUncertainty);
            }
        }
예제 #2
0
        public DataCoverageResult GetCoverage(ITimeSegment t)
        {
            var componentResult = component.GetCoverage(t);

            if (componentResult == DataCoverageResult.DataWithUncertainty)
            {
                if (t.FirstYear == this.firstDataYear && t.LastYear == this.lastDataYear)
                {
                    return(DataCoverageResult.DataWithUncertainty);
                }
                else
                {
                    return(DataCoverageResult.DataWithoutUncertainty);
                }
            }
            else
            {
                return(componentResult);
            }
        }
예제 #3
0
        public DataCoverageResult GetCoverage(ITimeSegment t)
        {
            var componentResult = component.GetCoverage(t);

            if (componentResult == DataCoverageResult.DataWithUncertainty)
            {
                if (t.LastYear - t.FirstYear + 1 >= this.permitedYearsLength)
                {
                    return(DataCoverageResult.DataWithUncertainty);
                }
                else
                {
                    return(DataCoverageResult.DataWithoutUncertainty);
                }
            }
            else
            {
                return(componentResult);
            }
        }