Class S125DatasetProcessor
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
sourceIAssetSourceAsset source holding the dataset.
relativePathstringPath of the dataset within
source.catalogueManagerPortrayalCatalogueManagerSupplies the S-125 (and, for AtoN symbology, S-101) portrayal catalogues.
authorityProviderIDisplayPlaneAuthorityProviderResolves the S-98 display plane.
featureCatalogueManagerFeatureCatalogueManagerSupplies the feature catalogues (S-125 decoding; S-101 for AtoN symbology).
luaEngineILuaEngineLua 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
pathstringPath to the S-125 GML dataset.
catalogueManagerPortrayalCatalogueManagerSupplies the S-125 (and, for AtoN symbology, S-101) portrayal catalogues.
authorityProviderIDisplayPlaneAuthorityProviderResolves the S-98 display plane.
featureCatalogueManagerFeatureCatalogueManagerSupplies the feature catalogues (S-125 decoding; S-101 for AtoN symbology).
luaEngineILuaEngineLua 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
ProductDescription
Human-readable product description for info strings (e.g. "Navigational Warnings", "Marine Aids to Navigation").
protected override string ProductDescription { get; }
Property Value
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
featureS125Feature
Returns
BuildInfoSuffix()
Appends spec-specific lines to the info string. Override to add counts like "Information types: N".
protected override string BuildInfoSuffix()
Returns
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
contextRenderContextThe render context (palette, mariner settings, ECDIS display state).
cancellationTokenCancellationTokenCancellation token.
Returns
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
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
S125DatasetDataorS102CoverageData).
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
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().