Resolve the user's preference store¶
Construct the clsPreferences instance used to read and write the SHOWAPPS layout preference, or determine that preferences are unavailable. This operation is implemented by SAIFMenu.Preferences.
| Field | Value |
|---|---|
| Operation ID | OP-MENU-008 |
| Trigger | SAIFMenu.Preferences property access (called from Restore menu state on page pre-load and Expand or collapse the applications section). |
| Inputs | HttpContext.Current.User.Identity.Name. |
| Outputs | A clsPreferences instance scoped to <username>/BOMENU, or Nothing. |
| Primary components | SAIFMenu.Preferences |
| Entry point | SAIF.Presentation.Web.Controls.V2.Menu/SAIFMenu.vb |
Steps¶
- Split
HttpContext.Current.User.Identity.Nameon\. Enforces BR-MENU-041. - Only when the split yields exactly two parts, construct
New clsPreferences(<username>, "BOMENU"); otherwise the property returnsNothingand all preference handling is skipped. Enforces BR-MENU-042, BR-MENU-043. - Delegates to
clsPreferences(SAIF.Presentation), which opens an Oracle data layer as DB userCLM.
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
Start(["SAIFMenu.Preferences property access"]) --> Split["Split User.Identity.Name on backslash"]
Split --> Check{Exactly two parts?}
Check -->|Yes| Construct(["New clsPreferences(username, 'BOMENU')"])
Check -->|No| Nothing(["Return Nothing; preference handling skipped"])
Failure and edge-case behavior¶
- Identity not in
DOMAIN\userform (0 or 1 parts, or more than 2): property returnsNothing; callers must null-check before using it (BR-MENU-043).
Related documentation¶
Sources¶
SAIF.Presentation.Web.Controls.V2.Menu/SAIFMenu.vb