/// <summary> /// ProjectExtentsResult create instance /// </summary> public static ProjectExtentsResult CreateProjectExtentsResult(BoundingBox3DGrid convertedExtents) { return(new ProjectExtentsResult { ProjectExtents = convertedExtents }); }
private void Clear() { startTime = DateTime.MinValue; endTime = DateTime.MinValue; cellSize = Double.MinValue; indexOriginOffset = Int32.MinValue; extents = null; }
public ElevationStatisticsResult(BoundingBox3DGrid convertExtents, double minElevation, double maxElevation, double totalCoverageArea) { BoundingExtents = convertExtents; MinElevation = minElevation; MaxElevation = maxElevation; TotalCoverageArea = totalCoverageArea; Message = convertExtents == null ? "No elevation range" : DefaultMessage; Code = convertExtents == null ? ContractExecutionStatesEnum.FailedToGetResults : ContractExecutionStatesEnum.ExecutedSuccessfully; }
public static SummaryThicknessResult Create(BoundingBox3DGrid convertExtents, double aboveTarget, double belowTarget, double matchTarget, double noCoverageArea) { return(new SummaryThicknessResult { BoundingExtents = convertExtents, AboveTarget = aboveTarget, BelowTarget = belowTarget, NoCoverageArea = noCoverageArea, MatchTarget = matchTarget, }); }
/// <summary> /// Static constructor. /// </summary> public static SummaryVolumesResult Create(BoundingBox3DGrid convertExtents, double cut, double fill, double totalCoverageArea, double cutArea, double fillArea) { return(new SummaryVolumesResult { BoundingExtents = convertExtents, Cut = cut, Fill = fill, TotalCoverageArea = totalCoverageArea, CutArea = cutArea, FillArea = fillArea }); }
/// <summary> /// Creates an instance of the SurveyedSurfaceDetails class. /// </summary> public static SurveyedSurfaceDetails CreateSurveyedSurfaceDetails( long id, DesignDescriptor surveyedSurface, DateTime asAtDate, BoundingBox3DGrid extents ) { return(new SurveyedSurfaceDetails { Id = id, SurveyedSurface = surveyedSurface, AsAtDate = asAtDate, Extents = extents }); }
/// <summary> /// Calls raptor to get project extents /// </summary> protected override async Task <ContractExecutionResult> ProcessAsyncEx <T>(T item) { try { var request = CastRequestObjectTo <ExtentRequest>(item); bool success; BoundingBox3DGrid bbExtents = null; #if RAPTOR if (UseTRexGateway("ENABLE_TREX_GATEWAY_TILES")) { #endif var siteModelId = request.ProjectUid.ToString(); bbExtents = await trexCompactionDataProxy.SendDataGetRequest <BoundingBox3DGrid>(siteModelId, $"/sitemodels/{siteModelId}/extents", customHeaders); success = bbExtents != null; #if RAPTOR } else { success = raptorClient.GetDataModelExtents(request.ProjectId ?? VelociraptorConstants.NO_PROJECT_ID, RaptorConverters.convertSurveyedSurfaceExlusionList(request.excludedSurveyedSurfaceIds), out var extents); bbExtents = RaptorConverters.ConvertExtents(extents); } #endif if (success) { if (bbExtents.ValidExtents) { return(ProjectExtentsResult.CreateProjectExtentsResult(bbExtents)); } } throw CreateServiceException <ProjectExtentsSubmitter>(); } finally { ContractExecutionStates.ClearDynamic(); // clear memory } }
public void Empty() { startTime = DateTime.UtcNow.AddMilliseconds(-1); endTime = DateTime.UtcNow; extents = new BoundingBox3DGrid(); }
public ProjectExtentsResult(BoundingBox3DGrid extents, int code, string message = "") : base(code, message) { ProjectExtents = extents; }