Files
DP44/docs/ai/DataPRO/Modules/Reports/PedestrianAndHeadReports.md
2026-04-17 14:55:32 -04:00

3.1 KiB

source_files, generated_at, model, schema_version, sha256
source_files generated_at model schema_version sha256
DataPRO/Modules/Reports/PedestrianAndHeadReports/PedestrianAndHeadReportsModule.cs
2026-04-17T16:47:14.036604+00:00 zai-org/GLM-5-FP8 1 5f34559ec2b43579

Documentation: PedestrianAndHeadReportsModule

1. Purpose

This module is a Prism-based module responsible for registering pedestrian and head report components within the application's Unity dependency injection container. It serves as the entry point for the PedestrianAndHeadReports feature area, registering input/output views and their corresponding view models for head reports and TRL (Transport Research Laboratory) reports. The module also provides assembly metadata via a custom attribute for display on the main screen.


2. Public Interface

PedestrianAndHeadReportsModule Class

A Prism module implementation that registers views and view models with the Unity container.

Constructor:

public PedestrianAndHeadReportsModule(IUnityContainer unityContainer)
  • Accepts an IUnityContainer instance via dependency injection and stores it in a readonly field _unityContainer.

Method:

public void Initialize()
  • Registers the following type mappings with the Unity container:
    • IHeadReportInputViewHeadReportInputView
    • IHeadReportOutputViewHeadReportOutputView
    • IHeadReportViewModelHeadReportViewModel
    • ITRLReportInputViewTRLReportInputView
    • ITRLReportOutputViewTRLReportOutputView
    • ITRLReportViewModelTRLReportViewModel

PedestrianAndHeadReportsImageAttribute Class

An attribute class extending ImageAttribute that provides assembly metadata for display in the application's main screen.

Constructor:

public PedestrianAndHeadReportsImageAttribute()
public PedestrianAndHeadReportsImageAttribute(string s)
  • Parameterless constructor chains to the string overload with null.
  • The string parameter s is accepted but not used in the implementation.

Properties:

Property Return Type Implementation
AssemblyImage BitmapImage Returns image from AssemblyInfo.GetImage(AssemblyNames.DB.ToString())
AssemblyName string Returns AssemblyNames.PowerAndBattery.ToString()
AssemblyGroup string Returns eAssemblyGroups.Administrative.ToString()
AssemblyRegion eAssemblyRegion Throws NotImplementedException

Methods:

Method Return Type Implementation
GetAttributeType() Type Returns typeof(ImageAttribute)
GetAssemblyImage() BitmapImage Returns AssemblyImage property
GetAssemblyName() string Returns AssemblyName property
GetAssemblyGroup() string Returns AssemblyGroup property
GetAssemblyRegion() eAssemblyRegion Throws NotImplementedException

3. Invariants

  • The _unityContainer field is readonly and must be provided at construction time.
  • The Initialize() method must be called for any views or view models in this module to be res