Skip to content

clsSAIFPlusDiscount

Represents the effective-dated SAIF Plus discount rate and caps. The class feeds the library's factor-selection pipeline and falls back to the neutral factor when its row does not apply.

Purpose

  • Represents the effective-dated SAIF Plus discount rate and caps.
  • The class feeds the library's factor-selection pipeline and falls back to the neutral factor when its row does not apply.

Context

  • Namespace: SAIF.Business.Policy.Rating
  • Assembly/package: SAIF.Business.Policy.Rating

Public members

Member Signature Purpose
EffectiveDate Public Property EffectiveDate() As Date Effective date on which this SAIF Plus discount row begins to apply.
Rate Public Property Rate() As Decimal SAIF Plus discount rate returned as the adjusted-rate factor when the row is valid.
AdjustedRateFactor Public Property AdjustedRateFactor(ByVal inAdjustedRateProvider As iAdjustedRateProvider) As Decimal Implements iAdjustedRateFactor.Factor Returns the stored SAIF Plus discount rate when the row is valid; otherwise returns the neutral factor.
MaximumDiscountAmount Public Property MaximumDiscountAmount() As Decimal Per-row cap on the SAIF Plus discount amount.
ExpirationDate Public Property ExpirationDate() As Date End date after which this SAIF Plus discount row no longer applies; empty means open-ended.
MaximumCombinationDiscountAmount Public Property MaximumCombinationDiscountAmount() As Decimal Cap on the combined discount amount when SAIF Plus is used with other discounts.
AppliesTo Public ReadOnly Property AppliesTo(ByVal inAsOfDate As Date) As Boolean True when the supplied date falls within this discount row's effective window.
IsExpirationDateNull Public Function IsExpirationDateNull() As Boolean Indicates whether the expiration date is unset for this discount row.
IsMaximumCombinationDiscountAmountNull Public Function IsMaximumCombinationDiscountAmountNull() As Boolean Indicates whether the combined-discount cap is unset for this row.
Equals Public Overloads Shared Function Equals(ByVal objA As Object, ByVal objB As Object) As Boolean Returns True only when both operands are SAIF Plus discount rows with the same effective date, expiration date, and rate.
Equals Public Overloads Overrides Function Equals(ByVal inObject As Object) As Boolean Uses the typed SAIF Plus comparison for another clsSAIFPlusDiscount; otherwise returns False.
Equals Public Overloads Function Equals(ByVal inObject As clsSAIFPlusDiscount) As Boolean Treats two SAIF Plus discount rows as equal when their effective date, expiration date, and rate match.
GetHashCode Public Overrides Function GetHashCode() As Integer Hashes Rate, the value this type uses as its identity key in keyed collections.
ToString Public Overrides Function ToString() As String Uses the SAIF Plus rate as the object's string representation.
GetSAIFPlusDiscount Public Shared Function GetSAIFPlusDiscount(ByVal inDataportal As IDataPortalInfo, ByVal inAsOfDate As Date) As clsSAIFPlusDiscount Retrieves the effective-dated SAIF Plus discount rate and caps identified by the key values or effective-date criteria supplied by the caller.
ValidSAIFPlusDiscount Public Function ValidSAIFPlusDiscount(ByVal target As Object, ByVal e As clsRuleArgs) As Boolean Validation rule implementing BR-028, rejecting rows whose EffectiveDate is Date.MinValue.
EffectiveDate Public Property EffectiveDate() As Date As-of date supplied to retrieval SQL to select the SAIF Plus discount row currently in force.
New Public Sub New(ByVal inDataPortalInfo As IDataPortalInfo) Creates an empty BOF object shell that shared factory methods or retrieval logic can populate with a loaded row.
New Public Sub New(ByVal inDataPortalInfo As IDataPortalInfo, ByVal inEffectiveDate As Date) Creates a criteria-backed instance seeded with inEffectiveDate so the next retrieval runs in the caller's requested context.
## Inherited public members
Member Signature Purpose
--- --- ---
Rules Property Rules As clsRulesManager Owns the BOF rules manager used to evaluate registered validation logic.†
BeginEdit Sub BeginEdit() Opens an n-level edit session for the business object.†
CancelEdit Sub CancelEdit() Rolls back the active edit scope.†
ApplyEdit Sub ApplyEdit() Commits the active edit scope.†
Error ReadOnly Property Error As String Surfaces aggregate broken-rule text through IDataErrorInfo.†
## Behavioral notes
- When callers ask for an applied factor, the type returns either its stored multiplier or the neutral factor defined by the policy contracts.
## Constraints and usage notes
- Prefer the provider-aware factor member when composing rates so the type's applicability checks run before a multiplier is used.
> Note: Statements marked with † are derived from dependency library
> documentation via the Legends CLI. They describe inherited behavior from the
> indicated origin library and should be verified if the dependency version changes.
## Sources
- Business\SAIF.Business.Policy.Rating\clsSAIFPlusDiscount.vb