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

2.3 KiB

source_files, generated_at, model, schema_version, sha256
source_files generated_at model schema_version sha256
DataPRO/Modules/SystemSettings/PowerAndBattery/PowerAndBatteryModule.cs
2026-04-17T16:46:28.309627+00:00 zai-org/GLM-5-FP8 1 8af7653fca429cb0

PowerAndBattery Module Documentation

1. Purpose

This module provides Power and Battery settings functionality within the DTS modular application framework. It serves as a Prism module that registers its View and ViewModel with the Unity dependency injection container, enabling the main application shell to display and manage power-related system settings. The module also exposes metadata (via PowerAndBatteryImageAttribute) that allows the main screen to display it as an available component in the Administrative group.


2. Public Interface

PowerAndBatteryModule (class)

Implements Prism.Modularity.IModule. The primary module entry point.

Member Signature Description
Constructor PowerAndBatteryModule(IUnityContainer unityContainer) Accepts a Unity container via dependency injection and stores it in _unityContainer.
Initialize void Initialize() Registers IPowerAndBatteryViewPowerAndBatteryView and IPowerAndBatteryViewModelPowerAndBatteryViewModel with the Unity container.
OnInitialized void OnInitialized(IContainerProvider containerProvider) Empty implementation—no initialization logic executed.
RegisterTypes void RegisterTypes(IContainerRegistry containerRegistry) Calls Initialize().

PowerAndBatteryImageAttribute (class)

Extends ImageAttribute. Provides assembly metadata for UI display.

Member Signature Description
Constructor PowerAndBatteryImageAttribute() Default constructor; loads assembly image.
Constructor PowerAndBatteryImageAttribute(string s) Overload that ignores the string parameter; loads assembly image.
AssemblyRegion eAssemblyRegion AssemblyRegion { get; } Throws NotImplementedException.
AssemblyImage BitmapImage AssemblyImage { get; } Returns a BitmapImage retrieved via AssemblyInfo.GetImage(AssemblyNames.PowerAndBattery.ToString()).
AssemblyName string AssemblyName { get; } Returns AssemblyNames.PowerAndBattery.ToString().
`AssemblyGroup