lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [5099] Accommodate deficient admin-system extracts


From: Greg Chicares
Subject: [lmi-commits] [5099] Accommodate deficient admin-system extracts
Date: Thu, 16 Sep 2010 00:39:58 +0000

Revision: 5099
          http://svn.sv.gnu.org/viewvc/?view=rev&root=lmi&revision=5099
Author:   chicares
Date:     2010-09-16 00:39:58 +0000 (Thu, 16 Sep 2010)
Log Message:
-----------
Accommodate deficient admin-system extracts

Modified Paths:
--------------
    lmi/trunk/ChangeLog
    lmi/trunk/input_xml_io.cpp

Modified: lmi/trunk/ChangeLog
===================================================================
--- lmi/trunk/ChangeLog 2010-09-15 16:20:17 UTC (rev 5098)
+++ lmi/trunk/ChangeLog 2010-09-16 00:39:58 UTC (rev 5099)
@@ -26756,3 +26756,8 @@
   skin_variable_annuity.xrc
 Add new state fields.
 
+20100916T0039Z <address@hidden> [656]
+
+  input_xml_io.cpp
+Accommodate deficient admin-system extracts.
+

Modified: lmi/trunk/input_xml_io.cpp
===================================================================
--- lmi/trunk/input_xml_io.cpp  2010-09-15 16:20:17 UTC (rev 5098)
+++ lmi/trunk/input_xml_io.cpp  2010-09-16 00:39:58 UTC (rev 5099)
@@ -386,6 +386,12 @@
             );
         }
 
+    // Defectively, some admin-system extracts lack various elements.
+    // All deficient extracts happen to lack <AgentPhone>: they don't
+    // even have an empty <AgentPhone/>; but that field is present in
+    // every input file ever saved by any version of lmi.
+    bool const deficient_extract = contains(residuary_names, "AgentPhone");
+
     // One state governs everything except premium tax, which may be
     // paid to a different state, e.g. on cases with more than five
     // hundred lives with a common (employer) issue state; see:
@@ -404,13 +410,15 @@
     // 'FilingApprovalState' and 'PremiumTaxState' were unknown before
     // version 6, and would not ordinarily occur in older versions.
     // However, certain admin-system extracts that are always marked
-    // as version 5 have been modified to add these two fields.
+    // as version 5 were to have been modified to add these two fields
+    // (yet were not so modified).
     if(file_version < 6)
         {
         bool const b0 = contains(detritus_map, "FilingApprovalState");
         bool const b1 = !contains(residuary_names, "PremiumTaxState");
         if(b0 || b1)
             {
+            fatal_error() << "Unexpected 'state' fields." << LMI_FLUSH; // 
deficient_extract
             LMI_ASSERT(b0 && b1 && 5 == file_version);
             StateOfJurisdiction = map_lookup(detritus_map, 
"FilingApprovalState");
             }
@@ -464,7 +472,8 @@
             }
         }
 
-    if(file_version < 6)
+    // For "deficient" extracts, these required elements are missing.
+    if(file_version < 6 && !deficient_extract)
         {
         LMI_ASSERT(contains(residuary_names, "SolveFromWhich"));
         LMI_ASSERT(contains(residuary_names, "SolveTgtAtWhich"));




reply via email to

[Prev in Thread] Current Thread [Next in Thread]