Table of Contents

Class S125DatasetProcessor

Namespace
EncDotNet.S100.Datasets.Pipelines
Assembly
EncDotNet.S100.Datasets.Pipelines.dll

Dataset processor that loads an S-125 Marine Aids to Navigation GML dataset, executes the bundled XSLT portrayal pipeline, and produces a Mapsui layer ready for display in the viewer.

public sealed class S125DatasetProcessor : GmlDatasetProcessorBase<S125Feature>, IDatasetProcessor, IVectorPortrayalSource, IHeadlessImageRenderer, IDisplayModeAwareDatasetProcessor, ILoadedDatasetProjection
Inheritance
S125DatasetProcessor
Implements
Inherited Members

Remarks

The S-125 Edition 1.0.0 Portrayal Catalogue portrays only AtoN status indications and data coverage — it is designed as an overlay on the ENC's own AtoN symbology. When a Lua engine and the S-101 portrayal and feature catalogues are available, this processor also portrays the aids themselves with the bundled S-101 AtoN rules (an implementation choice, see S125AtonPortrayalProjection), merging both outputs into one layer. Without them the dataset renders the S-125 catalogue output only.

Constructors

S125DatasetProcessor(IAssetSource, string, PortrayalCatalogueManager, IDisplayPlaneAuthorityProvider, FeatureCatalogueManager?, ILuaEngine?)

Initializes a new S125DatasetProcessor by reading the dataset file relativePath from source. Used by exchange-set bulk loading.

public S125DatasetProcessor(IAssetSource source, string relativePath, PortrayalCatalogueManager catalogueManager, IDisplayPlaneAuthorityProvider authorityProvider, FeatureCatalogueManager? featureCatalogueManager = null, ILuaEngine? luaEngine = null)

Parameters

source IAssetSource

Asset source holding the dataset.

relativePath string

Path of the dataset within source.

catalogueManager PortrayalCatalogueManager

Supplies the S-125 (and, for AtoN symbology, S-101) portrayal catalogues.

authorityProvider IDisplayPlaneAuthorityProvider

Resolves the S-98 display plane.

featureCatalogueManager FeatureCatalogueManager

Supplies the feature catalogues (S-125 decoding; S-101 for AtoN symbology).

luaEngine ILuaEngine

Lua engine for the S-101 AtoN rules; null renders the S-125 catalogue output (status indications) only.

S125DatasetProcessor(string, PortrayalCatalogueManager, IDisplayPlaneAuthorityProvider, FeatureCatalogueManager?, ILuaEngine?)

Initializes a new S125DatasetProcessor.

public S125DatasetProcessor(string path, PortrayalCatalogueManager catalogueManager, IDisplayPlaneAuthorityProvider authorityProvider, FeatureCatalogueManager? featureCatalogueManager = null, ILuaEngine? luaEngine = null)

Parameters

path string

Path to the S-125 GML dataset.

catalogueManager PortrayalCatalogueManager

Supplies the S-125 (and, for AtoN symbology, S-101) portrayal catalogues.

authorityProvider IDisplayPlaneAuthorityProvider

Resolves the S-98 display plane.

featureCatalogueManager FeatureCatalogueManager

Supplies the feature catalogues (S-125 decoding; S-101 for AtoN symbology).

luaEngine ILuaEngine

Lua engine for the S-101 AtoN rules; null renders the S-125 catalogue output (status indications) only.

Properties

Features

The parsed features from the dataset.

protected override IReadOnlyList<S125Feature> Features { get; }

Property Value

IReadOnlyList<S125Feature>

ProductDescription

Human-readable product description for info strings (e.g. "Navigational Warnings", "Marine Aids to Navigation").

protected override string ProductDescription { get; }

Property Value

string

Methods

BuildFeatureReferences(S125Feature)

Builds feature references for the pick UI. Override to expose xlink/information references as navigable links.

protected override IReadOnlyList<FeatureReference> BuildFeatureReferences(S125Feature feature)

Parameters

feature S125Feature

Returns

IReadOnlyList<FeatureReference>

BuildInfoSuffix()

Appends spec-specific lines to the info string. Override to add counts like "Information types: N".

protected override string BuildInfoSuffix()

Returns

string

BuildSupplementalPortrayalAsync(RenderContext?, CancellationToken)

Builds portrayal from a second, non-XSLT source that is merged with the product's own XSLT output — e.g. S-125, whose own catalogue portrays only AtoN status indications, supplements it with the S-101 AtoN rules. Returns null (the default) when the product has no supplemental portrayal. Called under the render gate.

protected override Task<GmlDatasetProcessorBase<S125Feature>.SupplementalPortrayal?> BuildSupplementalPortrayalAsync(RenderContext? context, CancellationToken cancellationToken)

Parameters

context RenderContext

The render context (palette, mariner settings, ECDIS display state).

cancellationToken CancellationToken

Cancellation token.

Returns

Task<GmlDatasetProcessorBase<S125Feature>.SupplementalPortrayal>

Remarks

Portrays the aids to navigation with the bundled S-101 AtoN rules. The S-101 palette replaces the S-125 one: the S-125 colour profile's tokens are the S-52 / S-101 colour tokens, and the S-125 catalogue's own instructions only reference its CHNG* symbols, whose colours come from the S-125 stylesheets.

CreateFeatureXmlSource()

Creates the spec-appropriate feature XML source.

protected override IFeatureXmlSource CreateFeatureXmlSource()

Returns

IFeatureXmlSource

CreateLoadedData()

Allocates the LoadedDatasetData variant wrapping this processor's already-parsed model. Never re-reads the source bytes.

public override LoadedDatasetData CreateLoadedData()

Returns

LoadedDatasetData

The catalog payload wrapping the resident model (e.g. an S125DatasetData or S102CoverageData).

Remarks

Each GML subclass wraps its resident, already-parsed model in the matching LoadedDatasetData variant (e.g. new S125DatasetData(_dataset)) — no second parse.

ValidateDataset()

Runs the product's rule pack, or returns null when the product has none. Called once by Validate(), which caches the result.

protected override ValidationReport? ValidateDataset()

Returns

ValidationReport

Remarks

Overrides should typically delegate to ValidationRunner.Run(...) so that an InvalidOperationException from the typed projection (e.g. an empty dataset) surfaces as an empty report rather than propagating out of Validate().