PolicyStatusEnums¶
This module is the library's shared translation table between persisted policy-status codes and the enum values used by BOF policy objects. clsPolicyData and clsPolicyPeriod rely on it when they turn stored status strings into display and workflow state, while the grouped constants let callers reason about application, active, pending-cancel, cancelled, and PMS-specific statuses from one place.*
Purpose¶
- Centralize the raw string codes used to identify policy and PMS statuses.
- Provide bidirectional conversion between persisted status codes and the
Statusesenum consumed by policy-view logic. - Provide bidirectional conversion between status-group codes and the
StatusGroupsenum used for broader status categorization.*
Context¶
- Namespace:
SAIF.Business.View.Policy - Assembly/package:
SAIF.Business.View.Policy(embedded)
Public members¶
| Member | Signature | Purpose |
|---|---|---|
ACTIVE |
Public Const ACTIVE As String = "0" |
Canonical raw code for an active policy status. |
FINALIZED |
Public Const FINALIZED As String = "F" |
Canonical raw code for a finalized policy status. |
APPLICATION |
Public Const APPLICATION As String = "P0" |
Canonical raw code for an application status. |
QUOTED |
Public Const QUOTED As String = "P2" |
Canonical raw code for a quoted status. |
PENDING_CANCELLATION |
Public Const PENDING_CANCELLATION As String = "3" |
Canonical raw code used when a policy is pending cancellation. |
PENDING_APPLICATION |
Public Const PENDING_APPLICATION As String = "P1" |
Canonical raw code for a pending-application status. |
REJECTED_APPLICATION |
Public Const REJECTED_APPLICATION As String = "P9" |
Canonical raw code for a rejected application. |
CANCELLED |
Public Const CANCELLED As String = "5" |
Canonical raw code for a cancelled policy. |
PMS_PROSPECT |
Public Const PMS_PROSPECT As String = "PP" |
Canonical raw code for a PMS prospect state. |
PMS_ACTIVE |
Public Const PMS_ACTIVE As String = "PA" |
Canonical raw code for a PMS active state. |
PMS_CLOSED |
Public Const PMS_CLOSED As String = "PC" |
Canonical raw code for a PMS closed state. |
APPLICATION_GROUP |
Public Const APPLICATION_GROUP As String = "APP" |
Group code representing application-oriented statuses. |
ACTIVE_GROUP |
Public Const ACTIVE_GROUP As String = "ACTIVE" |
Group code representing active statuses. |
PENDING_CANCEL_GROUP |
Public Const PENDING_CANCEL_GROUP As String = "PENDCA" |
Group code representing pending-cancellation statuses. |
CANCEL_GROUP |
Public Const CANCEL_GROUP As String = "CANCEL" |
Group code representing cancelled statuses. |
Statuses |
Public Enum Statuses |
Enumerates the named policy-status values used by conversion callers, including Unknown, All, Quoted, Application, Active, PendingCancellation, PendingApplication, RejectedApplication, Finalized, Cancelled, PMSProspect, PMSActive, and PMSClosed. |
StatusGroups |
Public Enum StatusGroups |
Enumerates the broader status buckets exposed by the module: Unknown, Application, Active, PendingCancel, and Cancelled. |
ConvertPolicyStatus |
Public Function ConvertPolicyStatus(ByVal inStatus As Statuses) As String |
Converts a named status enum into the raw code expected by persistence and comparison logic. |
ConvertPolicyStatus |
Public Function ConvertPolicyStatus(ByVal inStatus As String) As Statuses |
Converts a raw stored status code into the corresponding named enum value for policy-view logic. |
ConvertPolicyStatusGroup |
Public Function ConvertPolicyStatusGroup(ByVal inStatusGroup As StatusGroups) As String |
Converts a named status-group enum into the persisted group code. |
ConvertPolicyStatusGroup |
Public Function ConvertPolicyStatusGroup(ByVal inStatusGroupCode As String) As StatusGroups |
Converts a raw status-group code into the corresponding named bucket enum. |
Behavioral notes¶
- Unknown status or status-group inputs convert to an empty string or
Unknownrather than throwing, which lets callers tolerate unmapped codes from data retrieval. - This module supports status interpretation across policy retrieval paths, including status-dependent behaviors such as BR-VP-016 context and BR-VP-017 checks that depend on consistent status values.*
- The public surface visible in
Enums.vbcontains the full nestedStatusesandStatusGroupsmember lists documented above; no additional nested enum members were identified in the analysis or source.
Constraints and usage notes¶
- The module is a code/enum mapping layer only; it does not retrieve status data from the database.
Statuses.Allexists in the enum but has no string-code mapping inConvertPolicyStatus(Statuses), so callers cannot round-trip that value through the string converter.
Note: Statements marked with * were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts.
Sources¶
SAIF.Business.View.Policy/Enums.vb