[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 9051064 3/8: Improve label on age-70 row in N
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 9051064 3/8: Improve label on age-70 row in Numeric Summary [388] |
Date: |
Mon, 31 Jul 2017 17:24:17 -0400 (EDT) |
branch: master
commit 9051064407a43809b5b60042b440791d38750941
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Improve label on age-70 row in Numeric Summary [388]
Changed the label to "Age 70" instead of the corresponding duration in
order to make the meaning clearer.
---
ledger_text_formats.cpp | 19 +++++++++++++------
1 file changed, 13 insertions(+), 6 deletions(-)
diff --git a/ledger_text_formats.cpp b/ledger_text_formats.cpp
index 2e55683..2ef740c 100644
--- a/ledger_text_formats.cpp
+++ b/ledger_text_formats.cpp
@@ -1029,7 +1029,11 @@ void FlatTextLedgerPrinter::PrintNumericalSummary() const
os_ << " Year Outlay Value Value Benefit
Value Value Benefit Value Value Benefit" << endrow;
os_ << endrow;
- int summary_rows[] = {4, 9, 19, 69 - value_cast<int>(invar().Age)};
+ // For multi-life contracts (which lmi does not currently support),
+ // substitute duration thirty for age seventy: see illustration reg
+ // section (7)(C)(1).
+
+ std::vector<int> summary_rows = {4, 9, 19, 69 -
value_cast<int>(invar().Age)};
for(auto const& row : summary_rows)
{
@@ -1045,7 +1049,14 @@ void FlatTextLedgerPrinter::PrintNumericalSummary() const
os_.precision(0);
os_.width(7);
- os_ << std::setw( 7) << (1 + row) ;
+ if(&row == &summary_rows.back())
+ {
+ os_ << " Age 70";
+ }
+ else
+ {
+ os_ << std::setw( 7) << (1 + row) ;
+ }
os_.precision(2);
@@ -1066,10 +1077,6 @@ void FlatTextLedgerPrinter::PrintNumericalSummary() const
os_ << endrow;
}
-// TODO ?? Print "Age 70" instead of duration for last row. The NAIC
-// illustration reg (7)(C)(1) requires the numeric summary to show:
-// - durations 5, 10, and 20; and age 70 if applicable; but
-// - durations 5, 10, 20, and 30 for multiple-life policies.
os_ << endrow;
}
- [lmi-commits] [lmi] master updated (e13aa72 -> bd7e567), Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 6ceeaf8 1/8: Say why headers are included if not obvious, Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 8aea003 2/8: Fix defect introduced 20050114T1947Z: range error, Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 5df1ad4 4/8: Resolve several marked defects [384], Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 9051064 3/8: Improve label on age-70 row in Numeric Summary [388],
Greg Chicares <=
- [lmi-commits] [lmi] master 9edce5a 5/8: Crudely paginate text output, Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 615758f 6/8: Improve const-correctness, Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master bd7e567 8/8: Show lapse years in Numeric Summary, Greg Chicares, 2017/07/31
- [lmi-commits] [lmi] master 1622e2f 7/8: Locally cache certain values, Greg Chicares, 2017/07/31