feat: port p-rec-annot elevation subsystem

This commit is contained in:
codex
2026-08-07 11:58:13 +03:00
parent 532c9dc1f2
commit b69a858f8e
12 changed files with 327 additions and 10 deletions
@@ -0,0 +1,15 @@
using PRecAnnot.Abstractions;
using PRecAnnot.Core;
namespace PRecAnnot.Plant3D2026;
internal static class ElevationRuntimeConfiguration
{
public static ElevationAssets Read()
{
var path = Environment.GetEnvironmentVariable("P_REC_ANNOT_LINE_NUMBER_DRAWING_SETTINGS_PATH");
if (string.IsNullOrWhiteSpace(path) || !Path.IsPathFullyQualified(path) || path.StartsWith("\\\\", StringComparison.Ordinal) || !File.Exists(path))
throw new InvalidOperationException("ELEVATION_CONFIGURATION_REQUIRED:P_REC_ANNOT_LINE_NUMBER_DRAWING_SETTINGS_PATH");
return new ElevationSettingsLoader().Load(File.ReadAllText(path));
}
}