Build the policy header settings¶
This operation constructs the standard header-settings object that governs association-type visibility, selected association state, demo-mode behavior, and non-production diagnostics.
| Field | Value |
|---|---|
| Operation ID | OP-04 |
| Trigger | First read of PolicyHeaderSettings |
| Inputs | DPI, security principal, selected association type, totals-selection state |
| Outputs | Initialized IPolicyHeaderSettings implementation |
| Primary components | PolicyAppManager.PolicyHeaderSettings, GetPolicyHeaderSettings, clsStandardPolicyHeaderSettings |
| Entry point | Application\SAIF.Application.Policy\PolicyAppManager.vb |
Steps¶
- Construct
clsStandardPolicyHeaderSettings(DPI, SecurityPrincipal)through the overridableGetPolicyHeaderSettings()factory. - Push the manager's totals-selection state into the settings object.
- If no association type has been selected, compute the default association type from the currently available header associations (BR-117).
- Load the candidate association-type target set from
clsAssociationTypeCodeCollection.GetAssociationTypeCodes(DPI)and keep only rows markedIsDefaultPolicyHeaderType(BR-110). - Resolve the principal's validated association types and cache them per user name.
- Evaluate
IsTestInformationViewablefromNot AppGlobal.EnvironmentService.IsProduction(BR-111). - Evaluate
DemoModefromclsUserType(SecurityPrincipal).IsDemoUser.
Process flow¶
The following diagram visualizes header-settings construction.
flowchart TD
Start([Header settings requested]) --> Create[Construct clsStandardPolicyHeaderSettings]
Create --> Targets[Load default header association types]
Targets --> Validated[Resolve validated association types]
Validated --> Default{Selected type already set?}
Default -->|No| Pick[Pick default association type]
Default -->|Yes| Flags[Evaluate demo and test-information flags]
Pick --> Flags
Flags --> Done([Return settings])
Failure and edge-case behavior¶
- Per-user association-type security is cached for the process lifetime.*
- Test-information visibility depends entirely on the host's environment-service implementation.**
Note: Statements marked with
*were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts. Statements marked with**could not be confirmed; treat as unknown until verified.
Related documentation¶
Sources¶
Application\SAIF.Application.Policy\PolicyAppManager.vbApplication\SAIF.Application.Policy\PolicyHeader\clsStandardPolicyHeaderSettings.vb