UnitStatServices¶
UnitStatServices is a public class in SAIF.Business that supplies unit-stat reporting helpers for NCCI policy-number formatting, policy-unit splitting, and valuation-cycle date calculations.
Purpose¶
- Retrieves formatted NCCI policy numbers and active policy-unit effective dates through data-portal queries.
- Splits extended policy periods into one or two reportable unit ranges for NCCI reporting.
- Builds valuation schedules and derives first, last, and current valuation-cycle dates for a unit.
- Exposes the
UREStartDatecutoff used to choose five versus ten valuation periods.
Context¶
- Namespace:
SAIF.Business - Assembly/package:
SAIF.Business
Public members¶
| Member | Signature | Purpose |
|---|---|---|
UREStartDate |
Public Const UREStartDate As Date = #1/1/2002# |
Defines the cutoff date used when choosing whether a unit receives 5 or 10 report valuation periods. |
GetNCCIPolicyNumber |
Public Shared Function GetNCCIPolicyNumber(ByVal inDPI As IDataPortalInfo, ByVal inPolicyNumber As Decimal, ByVal inPolicyPeriodEffectiveDate As Date) As String |
Queries and returns the formatted NCCI policy number built from market type, policy number, subcode, and policy suffix. |
GetUnitSplitDate |
Public Shared Function GetUnitSplitDate(ByVal inPolicyPeriodEffectiveDate As Date, ByVal inPolicyPeriodExpirationDate As Date) As Date |
Returns the split date used to divide extended policy periods into two NCCI reporting units. |
GetPolicyPeriodUnits |
Public Shared Function GetPolicyPeriodUnits(ByVal inPolicyPeriodEffectiveDate As Date, ByVal inPolicyPeriodExpirationDate As Date, ByVal inCancelDate As Date) As List(Of DateRange) |
Builds the one or two DateRange unit periods that should be reported for the policy term and cancel date. |
GetReportValuationPeriods |
Public Shared Function GetReportValuationPeriods(ByVal inUnitEffectiveDate As Date) As Generic.List(Of clsReportValuationPeriod) |
Generates the ordered list of report valuation periods for a unit, including SAIF and NCCI valuation dates. |
GetValuationNumber |
Public Shared Function GetValuationNumber(ByVal inProcessDate As Date, ByVal inUnitEffectiveDate As Date) As Decimal |
Returns the valuation-cycle number that contains the supplied process date. |
GetFirstValuationDate |
Public Shared Function GetFirstValuationDate(ByVal inUnitEffectiveDate As Date) As Date |
Returns the valuation date for the first original report on the unit. |
GetLastValuationDate |
Public Shared Function GetLastValuationDate(ByVal inUnitEffectiveDate As Date) As Date |
Returns the end date of the final generated report valuation period. |
GetPolicyUnitEffectiveDate |
Public Shared Function GetPolicyUnitEffectiveDate(ByVal inDPI As IDataPortalInfo, ByVal inPolicyNumber As Decimal, ByVal inProcessDate As Date) As Date |
Looks up the effective date of the active policy unit covering the supplied process date. |
clsReportValuationPeriod |
Public Class clsReportValuationPeriod |
Defines the public nested value object used to hold valuation number, begin/end dates, and valuation dates for a report cycle. |
Behavioral notes¶
GetUnitSplitDatereturnsDate.MinValueunless the expiration date is more than one year and 16 days after the effective date.GetPolicyPeriodUnitsemits one unit for unsplit periods and otherwise creates two units unless the cancel date falls on or before the split date.GetReportValuationPeriodsstarts the first report cycle 18 months after the first day of the unit effective month and creates 5 cycles beforeUREStartDate, otherwise 10.GetValuationNumberreturns0before the first cycle and the last cycle number after the final cycle.
Constraints and usage notes¶
GetNCCIPolicyNumberandGetPolicyUnitEffectiveDaterequire a validIDataPortalInfowith access to the underlying policy tables.GetPolicyUnitEffectiveDatereturnsDate.MinValuewhen no matching active unit is found.GetNCCIPolicyNumberconverts the first portal-request result directly toString, so callers should expect the database query to supply a scalar result.
Sources¶
Business\SAIF.Business\UnitStatServices.vb