OSDC.Drilling.EarthGravity.WebPages
1.0.1
dotnet add package OSDC.Drilling.EarthGravity.WebPages --version 1.0.1
NuGet\Install-Package OSDC.Drilling.EarthGravity.WebPages -Version 1.0.1
<PackageReference Include="OSDC.Drilling.EarthGravity.WebPages" Version="1.0.1" />
<PackageVersion Include="OSDC.Drilling.EarthGravity.WebPages" Version="1.0.1" />
<PackageReference Include="OSDC.Drilling.EarthGravity.WebPages" />
paket add OSDC.Drilling.EarthGravity.WebPages --version 1.0.1
#r "nuget: OSDC.Drilling.EarthGravity.WebPages, 1.0.1"
#:package OSDC.Drilling.EarthGravity.WebPages@1.0.1
#addin nuget:?package=OSDC.Drilling.EarthGravity.WebPages&version=1.0.1
#tool nuget:?package=OSDC.Drilling.EarthGravity.WebPages&version=1.0.1
OSDC.Drilling.EarthGravity.WebPages
Author: Eric Cayeux
Company: NORCE Research
Reusable server-side Blazor pages for the OSDC Earth Gravity service. The package consumes the generated ModelSharedOut NSwag client and uses OSDC.UnitConversion.DrillingRazorMudComponents so users can work in a selected OSDC unit system while the Earth Gravity API remains strictly SI.
Included pages
/Home: service purpose and SI/WGS84 conventions./EarthGravityCalculation: unit-aware single-position gravity evaluation./EarthGravityModel: EGM96 provenance and coefficient hash./StatisticsEarthGravity: per-replica operational counters.
EarthGravityCalculation uses:
MudUnitAndReferenceChoiceTagfor the selected OSDC unit system.MudInputAngleWithUnitAdornmentfor sexagesimal latitude/longitude entry.MudInputWithUnitAdornmentwithPlaneAngleGeodesic,DepthDrilling, andAccelerationDrilling.
The generated client always sends radians, metres, and metres per second squared. The WGS84 depth reference is fixed by the Earth Gravity contract and is not user-selectable; only display units change.
Package dependencies
MudBlazorOSDC.DotnetLibraries.Drilling.WebAppUtilsOSDC.UnitConversion.DrillingRazorMudComponents- Generated
ModelSharedOut/EarthGravityMergedModel.cs
The generated client and PseudoConstructors.cs are linked into this Razor class library at build time.
Host configuration
The host must implement IEarthGravityWebPagesConfiguration:
public sealed class WebPagesHostConfiguration : IEarthGravityWebPagesConfiguration
{
public string EarthGravityHostURL { get; set; } = string.Empty;
public string? UnitConversionHostURL { get; set; } = string.Empty;
}
Both values are host roots, normally with trailing slashes. APIUtils appends EarthGravity/api/ and UnitConversion/api/.
Register the pages and API utilities:
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
builder.Services.AddMudServices();
builder.Services.AddSingleton<IEarthGravityWebPagesConfiguration>(configuration);
builder.Services.AddSingleton<IEarthGravityAPIUtils, APIUtils>();
Add this assembly to the Blazor router:
<Router AppAssembly="@typeof(App).Assembly"
AdditionalAssemblies="new[] { typeof(OSDC.Drilling.EarthGravity.WebPages.EarthGravityCalculation).Assembly }">
...
</Router>
The host layout must include MudBlazor providers, CSS, and JavaScript, and must map the Blazor hub. See the repository WebApp project for a complete host.
Build and package
From the repository root:
dotnet build WebPages/WebPages.csproj -c Release
dotnet pack WebPages/WebPages.csproj -c Release -p:PackageVersion=1.0.0
The project currently generates a package during Release builds. The GitHub workflow publishes OSDC.Drilling.EarthGravity.WebPages for webpages-v* tags or a manually supplied version.
Regenerate ModelSharedOut before building the package whenever the service API changes.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- MudBlazor (>= 8.14.0)
- OSDC.DotnetLibraries.Drilling.WebAppUtils (>= 1.1.2)
- OSDC.UnitConversion.DrillingRazorMudComponents (>= 3.3.47)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.