Skip to content

Retrieve policy header data

Loads and populates a clsPolicyData object — the library's principal factory surface — used as the entry point for most policy lookups by the Claims Legal front end.

Field Value
Operation ID OP-VP-001
Trigger Caller invokes clsPolicyData.GetPolicyData(DPI, PolicyNum[, UserAccessLevel])
Inputs Policy number (or batch of policy numbers), optional UserAccessLevel
Outputs Populated, read-only clsPolicyData object (or an object with an attached error message if not found)
Primary components clsPolicyData.GetPolicyData
Entry point SAIF.Business.View.Policy\clsPolicyData.vb

Steps

  1. Caller invokes one of four GetPolicyData overloads (by Criteria, by policy number, by a batch of policy numbers, by policy number + UserAccessLevel). The call delegates to a Criteria object and IDataPortalInfo.DataAccessLayer.RetrieveObject.
  2. Delegates to a referenced/framework operation: the actual RetrieveObject call is implemented in the BOF Framework's data access layer (saif.framework.core), which executes the IDataRequest against the configured IDataPortalInfo and returns an IBusinessObject.

    Origin: RetrieveObject lifecycle (BeforeRetrieve/execute/AfterRetrieve) is implemented in clsBusinessBase (saif.framework.core, frameworkDensity=20). No concrete, domain-specific step-level description was available from the dependency documentation lookup for this base class beyond the generic mechanism. 2. BeforeRetrieve builds the request (SQL-VP-008): sets CommandType=StoredProcedure, RequestType=Reader, adds parameter apolicynum and a cursor parameter recordset. 3. AfterRetrieve reads the first row of the returned clsSAIFDataReader and calls Fill(Reader) to populate all properties (policy number, name, status, secure-policy code, agency, associations metadata, etc.), then calls MarkOld(). 4. Business rule enforced: PolicyNum must be greater than zero (BR-VP-001). - On failure: IsValid is set to False and a broken-rule message ("Error: Invalid policy number.") is attached to the object; no exception is thrown. 5. Result: a populated, read-only clsPolicyData object is returned to the caller. - If no row is found: an error message is added to the object instead of throwing.

Process flow

flowchart TD
    Start([Caller invokes GetPolicyData]) --> Build[BeforeRetrieve builds StoredProcedure request]
    Build --> Exec[Execute SQL-VP-008 via RetrieveObject]
    Exec --> Found{Row returned?}
    Found -->|Yes| Fill[AfterRetrieve calls Fill and MarkOld]
    Fill --> Rule{PolicyNum > 0?}
    Rule -->|Yes| Ok([Valid clsPolicyData returned])
    Rule -->|No| Invalid([IsValid=False, broken-rule message attached])
    Found -->|No| NotFound([Error message attached to object])

Failure and edge-case behavior

  • No row found for the requested policy number: an error message is attached to the returned object rather than an exception being thrown.
  • PolicyNum <= 0: IsValid becomes False with the broken-rule message "Error: Invalid policy number."

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.

Sources

  • SAIF.Business.View.Policy\clsPolicyData.vb