CurveSurfaceQuoteContainer.java

  1. package org.drip.param.market;

  2. /*
  3.  * -*- mode: java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
  4.  */

  5. /*!
  6.  * Copyright (C) 2020 Lakshmi Krishnamurthy
  7.  * Copyright (C) 2019 Lakshmi Krishnamurthy
  8.  * Copyright (C) 2018 Lakshmi Krishnamurthy
  9.  * Copyright (C) 2017 Lakshmi Krishnamurthy
  10.  * Copyright (C) 2016 Lakshmi Krishnamurthy
  11.  * Copyright (C) 2015 Lakshmi Krishnamurthy
  12.  * Copyright (C) 2014 Lakshmi Krishnamurthy
  13.  * Copyright (C) 2013 Lakshmi Krishnamurthy
  14.  * Copyright (C) 2012 Lakshmi Krishnamurthy
  15.  * Copyright (C) 2011 Lakshmi Krishnamurthy
  16.  *
  17.  *  This file is part of DROP, an open-source library targeting analytics/risk, transaction cost analytics,
  18.  *      asset liability management analytics, capital, exposure, and margin analytics, valuation adjustment
  19.  *      analytics, and portfolio construction analytics within and across fixed income, credit, commodity,
  20.  *      equity, FX, and structured products. It also includes auxiliary libraries for algorithm support,
  21.  *      numerical analysis, numerical optimization, spline builder, model validation, statistical learning,
  22.  *      and computational support.
  23.  *  
  24.  *      https://lakshmidrip.github.io/DROP/
  25.  *  
  26.  *  DROP is composed of three modules:
  27.  *  
  28.  *  - DROP Product Core - https://lakshmidrip.github.io/DROP-Product-Core/
  29.  *  - DROP Portfolio Core - https://lakshmidrip.github.io/DROP-Portfolio-Core/
  30.  *  - DROP Computational Core - https://lakshmidrip.github.io/DROP-Computational-Core/
  31.  *
  32.  *  DROP Product Core implements libraries for the following:
  33.  *  - Fixed Income Analytics
  34.  *  - Loan Analytics
  35.  *  - Transaction Cost Analytics
  36.  *
  37.  *  DROP Portfolio Core implements libraries for the following:
  38.  *  - Asset Allocation Analytics
  39.  *  - Asset Liability Management Analytics
  40.  *  - Capital Estimation Analytics
  41.  *  - Exposure Analytics
  42.  *  - Margin Analytics
  43.  *  - XVA Analytics
  44.  *
  45.  *  DROP Computational Core implements libraries for the following:
  46.  *  - Algorithm Support
  47.  *  - Computation Support
  48.  *  - Function Analysis
  49.  *  - Model Validation
  50.  *  - Numerical Analysis
  51.  *  - Numerical Optimizer
  52.  *  - Spline Builder
  53.  *  - Statistical Learning
  54.  *
  55.  *  Documentation for DROP is Spread Over:
  56.  *
  57.  *  - Main                     => https://lakshmidrip.github.io/DROP/
  58.  *  - Wiki                     => https://github.com/lakshmiDRIP/DROP/wiki
  59.  *  - GitHub                   => https://github.com/lakshmiDRIP/DROP
  60.  *  - Repo Layout Taxonomy     => https://github.com/lakshmiDRIP/DROP/blob/master/Taxonomy.md
  61.  *  - Javadoc                  => https://lakshmidrip.github.io/DROP/Javadoc/index.html
  62.  *  - Technical Specifications => https://github.com/lakshmiDRIP/DROP/tree/master/Docs/Internal
  63.  *  - Release Versions         => https://lakshmidrip.github.io/DROP/version.html
  64.  *  - Community Credits        => https://lakshmidrip.github.io/DROP/credits.html
  65.  *  - Issues Catalog           => https://github.com/lakshmiDRIP/DROP/issues
  66.  *  - JUnit                    => https://lakshmidrip.github.io/DROP/junit/index.html
  67.  *  - Jacoco                   => https://lakshmidrip.github.io/DROP/jacoco/index.html
  68.  *
  69.  *  Licensed under the Apache License, Version 2.0 (the "License");
  70.  *      you may not use this file except in compliance with the License.
  71.  *  
  72.  *  You may obtain a copy of the License at
  73.  *      http://www.apache.org/licenses/LICENSE-2.0
  74.  *  
  75.  *  Unless required by applicable law or agreed to in writing, software
  76.  *      distributed under the License is distributed on an "AS IS" BASIS,
  77.  *      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  78.  *  
  79.  *  See the License for the specific language governing permissions and
  80.  *      limitations under the License.
  81.  */

  82. /**
  83.  * <i>CurveSurfaceQuoteContainer</i> provides implementation of the set of the market curve parameters. It
  84.  * serves as a place holder for the market parameters needed to value the product – discount curve, forward
  85.  * curve, treasury curve, credit curve, product quote, treasury quote map, and fixings map.
  86.  *
  87.  *  <br><br>
  88.  *  <ul>
  89.  *      <li><b>Module </b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/ProductCore.md">Product Core Module</a></li>
  90.  *      <li><b>Library</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/FixedIncomeAnalyticsLibrary.md">Fixed Income Analytics</a></li>
  91.  *      <li><b>Project</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/src/main/java/org/drip/param/README.md">Product Cash Flow, Valuation, Market, Pricing, and Quoting Parameters</a></li>
  92.  *      <li><b>Package</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/src/main/java/org/drip/param/market/README.md">Curves Surfaces Quotes Fixings Container</a></li>
  93.  *  </ul>
  94.  *
  95.  * @author Lakshmi Krishnamurthy
  96.  */

  97. public class CurveSurfaceQuoteContainer {
  98.     private
  99.         org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>>
  100.             _mapPayCurrencyForeignCollateralDC = new
  101.                 org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>>();

  102.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.credit.CreditCurve>
  103.         _mapCreditState = new
  104.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.credit.CreditCurve>();

  105.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  106.         _mapEquityState = new
  107.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  108.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.forward.ForwardCurve>
  109.         _mapForwardState = new
  110.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.forward.ForwardCurve>();

  111.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>
  112.         _mapFundingState = new
  113.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>();

  114.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.fx.FXCurve>
  115.         _mapFXState = new
  116.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.fx.FXCurve>();

  117.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.govvie.GovvieCurve>
  118.         _mapGovvieState = new
  119.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.govvie.GovvieCurve>();

  120.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>
  121.         _mapOvernightState = new
  122.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>();

  123.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  124.         _mapPaydownState = new
  125.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  126.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>
  127.         _mapRatingState = new
  128.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>();

  129.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.credit.CreditCurve>
  130.         _mapRecoveryState = new
  131.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.credit.CreditCurve>();

  132.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.repo.RepoCurve> _mapRepoState =
  133.         new org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.repo.RepoCurve>();

  134.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  135.         _mapCollateralVolatility = new
  136.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  137.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  138.         _mapCreditVolatility = new
  139.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  140.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  141.         _mapCustomVolatility = new
  142.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  143.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  144.         _mapEquityVolatility = new
  145.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  146.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  147.         _mapForwardVolatility = new
  148.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  149.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  150.         _mapFundingVolatility = new
  151.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  152.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  153.         _mapFXVolatility = new
  154.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  155.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  156.         _mapGovvieVolatility = new
  157.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  158.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  159.         _mapOvernightVolatility = new
  160.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  161.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  162.         _mapPaydownVolatility = new
  163.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  164.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  165.         _mapRatingVolatility = new
  166.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  167.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  168.         _mapRecoveryVolatility = new
  169.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  170.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>
  171.         _mapRepoVolatility = new
  172.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.volatility.VolatilityCurve>();

  173.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  174.         _mapCollateralCollateralCorrelation = new
  175.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  176.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  177.         _mapCollateralCreditCorrelation = new
  178.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  179.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  180.         _mapCollateralCustomCorrelation = new
  181.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  182.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  183.         _mapCollateralEquityCorrelation = new
  184.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  185.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  186.         _mapCollateralForwardCorrelation = new
  187.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  188.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  189.         _mapCollateralFundingCorrelation = new
  190.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  191.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  192.         _mapCollateralFXCorrelation = new
  193.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  194.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  195.         _mapCollateralGovvieCorrelation = new
  196.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  197.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  198.         _mapCollateralOvernightCorrelation = new
  199.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  200.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  201.         _mapCollateralPaydownCorrelation = new
  202.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  203.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  204.         _mapCollateralRatingCorrelation = new
  205.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  206.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  207.         _mapCollateralRecoveryCorrelation = new
  208.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  209.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  210.         _mapCollateralRepoCorrelation = new
  211.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  212.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  213.         _mapCreditCreditCorrelation = new
  214.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  215.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  216.         _mapCreditCustomCorrelation = new
  217.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  218.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  219.         _mapCreditEquityCorrelation = new
  220.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  221.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  222.         _mapCreditForwardCorrelation = new
  223.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  224.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  225.         _mapCreditFundingCorrelation = new
  226.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  227.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  228.         _mapCreditFXCorrelation = new
  229.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  230.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  231.         _mapCreditGovvieCorrelation = new
  232.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  233.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  234.         _mapCreditOvernightCorrelation = new
  235.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  236.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  237.         _mapCreditPaydownCorrelation = new
  238.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  239.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  240.         _mapCreditRatingCorrelation = new
  241.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  242.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  243.         _mapCreditRecoveryCorrelation = new
  244.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  245.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  246.         _mapCreditRepoCorrelation = new
  247.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  248.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  249.         _mapCustomCustomCorrelation = new
  250.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  251.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  252.         _mapCustomEquityCorrelation = new
  253.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  254.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  255.         _mapCustomForwardCorrelation = new
  256.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  257.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  258.         _mapCustomFundingCorrelation = new
  259.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  260.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  261.         _mapCustomFXCorrelation = new
  262.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  263.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  264.         _mapCustomGovvieCorrelation = new
  265.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  266.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  267.         _mapCustomOvernightCorrelation = new
  268.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  269.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  270.         _mapCustomPaydownCorrelation = new
  271.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  272.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  273.         _mapCustomRatingCorrelation = new
  274.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  275.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  276.         _mapCustomRecoveryCorrelation = new
  277.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  278.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  279.         _mapCustomRepoCorrelation = new
  280.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  281.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  282.         _mapEquityEquityCorrelation = new
  283.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  284.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  285.         _mapEquityForwardCorrelation = new
  286.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  287.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  288.         _mapEquityFundingCorrelation = new
  289.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  290.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  291.         _mapEquityFXCorrelation = new
  292.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  293.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  294.         _mapEquityGovvieCorrelation = new
  295.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  296.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  297.         _mapEquityOvernightCorrelation = new
  298.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  299.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  300.         _mapEquityPaydownCorrelation = new
  301.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  302.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  303.         _mapEquityRatingCorrelation = new
  304.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  305.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  306.         _mapEquityRecoveryCorrelation = new
  307.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  308.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  309.         _mapEquityRepoCorrelation = new
  310.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  311.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  312.         _mapForwardForwardCorrelation = new
  313.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  314.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  315.         _mapForwardFundingCorrelation = new
  316.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  317.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  318.         _mapForwardFXCorrelation = new
  319.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  320.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  321.         _mapForwardGovvieCorrelation = new
  322.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  323.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  324.         _mapForwardOvernightCorrelation = new
  325.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  326.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  327.         _mapForwardPaydownCorrelation = new
  328.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  329.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  330.         _mapForwardRatingCorrelation = new
  331.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  332.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  333.         _mapForwardRecoveryCorrelation = new
  334.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  335.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  336.         _mapForwardRepoCorrelation = new
  337.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  338.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  339.         _mapFundingFundingCorrelation = new
  340.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  341.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  342.         _mapFundingFXCorrelation = new
  343.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  344.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  345.         _mapFundingGovvieCorrelation = new
  346.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  347.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  348.         _mapFundingOvernightCorrelation = new
  349.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  350.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  351.         _mapFundingPaydownCorrelation = new
  352.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  353.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  354.         _mapFundingRatingCorrelation = new
  355.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  356.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  357.         _mapFundingRecoveryCorrelation = new
  358.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  359.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  360.         _mapFundingRepoCorrelation = new
  361.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  362.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  363.         _mapFXFXCorrelation = new
  364.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  365.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  366.         _mapFXGovvieCorrelation = new
  367.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  368.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  369.         _mapFXOvernightCorrelation = new
  370.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  371.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  372.         _mapFXPaydownCorrelation = new
  373.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  374.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  375.         _mapFXRatingCorrelation = new
  376.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  377.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  378.         _mapFXRecoveryCorrelation = new
  379.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  380.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  381.         _mapFXRepoCorrelation = new
  382.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  383.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  384.         _mapGovvieGovvieCorrelation = new
  385.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  386.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  387.         _mapGovvieOvernightCorrelation = new
  388.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  389.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  390.         _mapGovviePaydownCorrelation = new
  391.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  392.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  393.         _mapGovvieRatingCorrelation = new
  394.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  395.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  396.         _mapGovvieRecoveryCorrelation = new
  397.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  398.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  399.         _mapGovvieRepoCorrelation = new
  400.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  401.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  402.         _mapOvernightOvernightCorrelation = new
  403.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  404.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  405.         _mapOvernightPaydownCorrelation = new
  406.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  407.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  408.         _mapOvernightRatingCorrelation = new
  409.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  410.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  411.         _mapOvernightRecoveryCorrelation = new
  412.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  413.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  414.         _mapOvernightRepoCorrelation = new
  415.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  416.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  417.         _mapPaydownPaydownCorrelation = new
  418.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  419.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  420.         _mapPaydownRatingCorrelation = new
  421.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  422.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  423.         _mapPaydownRecoveryCorrelation = new
  424.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  425.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  426.         _mapPaydownRepoCorrelation = new
  427.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  428.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  429.         _mapRatingRatingCorrelation = new
  430.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  431.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  432.         _mapRatingRecoveryCorrelation = new
  433.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  434.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  435.         _mapRatingRepoCorrelation = new
  436.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  437.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  438.         _mapRecoveryRecoveryCorrelation = new
  439.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  440.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  441.         _mapRecoveryRepoCorrelation = new
  442.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  443.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>
  444.         _mapRepoRepoCorrelation = new
  445.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.function.definition.R1ToR1>();

  446.     private org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.param.definition.ProductQuote>
  447.         _mapProductQuote = new
  448.             org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.param.definition.ProductQuote>();

  449.     private org.drip.param.market.LatentStateFixingsContainer _lsfc = new
  450.         org.drip.param.market.LatentStateFixingsContainer();

  451.     /**
  452.      * Empty CurveSurfaceQuoteSet Constructor
  453.      */

  454.     public CurveSurfaceQuoteContainer()
  455.     {
  456.     }

  457.     /**
  458.      * Retrieve the Discount Curve associated with the Pay Cash-flow Collateralized using a different
  459.      *  Collateral Currency Numeraire
  460.      *
  461.      * @param strPayCurrency The Pay Currency
  462.      * @param strCollateralCurrency The Collateral Currency
  463.      *
  464.      * @return The Discount Curve associated with the Pay Cash-flow Collateralized using a different
  465.      *  Collateral Currency Numeraire
  466.      */

  467.     public org.drip.state.discount.MergedDiscountForwardCurve payCurrencyCollateralCurrencyCurve (
  468.         final java.lang.String strPayCurrency,
  469.         final java.lang.String strCollateralCurrency)
  470.     {
  471.         if (null == strPayCurrency || !_mapPayCurrencyForeignCollateralDC.containsKey (strPayCurrency) ||
  472.             null == strCollateralCurrency)
  473.             return null;

  474.         return _mapPayCurrencyForeignCollateralDC.get (strPayCurrency).get (strCollateralCurrency);
  475.     }

  476.     /**
  477.      * Set the Discount Curve associated with the Pay Cash-flow Collateralized using a different
  478.      *  Collateral Currency Numeraire
  479.      *
  480.      * @param strPayCurrency The Pay Currency
  481.      * @param strCollateralCurrency The Collateral Currency
  482.      * @param dcPayCurrencyCollateralCurrency The Discount Curve associated with the Pay Cash-flow
  483.      *  Collateralized using a different Collateral Currency Numeraire
  484.      *
  485.      * @return TRUE - Successfully set
  486.      */

  487.     public boolean setPayCurrencyCollateralCurrencyCurve (
  488.         final java.lang.String strPayCurrency,
  489.         final java.lang.String strCollateralCurrency,
  490.         final org.drip.state.discount.MergedDiscountForwardCurve dcPayCurrencyCollateralCurrency)
  491.     {
  492.         if (null == strPayCurrency || strPayCurrency.isEmpty() || null == strCollateralCurrency ||
  493.             strCollateralCurrency.isEmpty() || null == dcPayCurrencyCollateralCurrency)
  494.             return false;

  495.         org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>
  496.             mapCollateralCurrencyDC = new
  497.                 org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>();

  498.         mapCollateralCurrencyDC.put (strCollateralCurrency, dcPayCurrencyCollateralCurrency);

  499.         _mapPayCurrencyForeignCollateralDC.put (strPayCurrency, mapCollateralCurrencyDC);

  500.         return true;
  501.     }

  502.     /**
  503.      * Retrieve the Collateral Choice Discount Curve for the specified Pay Currency
  504.      *
  505.      * @param strPayCurrency The Pay Currency
  506.      *
  507.      * @return Collateral Choice Discount Curve
  508.      */

  509.     public org.drip.state.discount.MergedDiscountForwardCurve collateralChoiceDiscountCurve (
  510.         final java.lang.String strPayCurrency)
  511.     {
  512.         if (null == strPayCurrency || !_mapPayCurrencyForeignCollateralDC.containsKey (strPayCurrency))
  513.             return null;

  514.         org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.state.discount.MergedDiscountForwardCurve>
  515.             mapCollateralCurrencyDC = _mapPayCurrencyForeignCollateralDC.get (strPayCurrency);

  516.         int iNumCollateralizer = mapCollateralCurrencyDC.size();

  517.         org.drip.state.curve.ForeignCollateralizedDiscountCurve[] aFCDC = new
  518.             org.drip.state.curve.ForeignCollateralizedDiscountCurve[iNumCollateralizer];

  519.         int i = 0;

  520.         for (java.util.Map.Entry<java.lang.String, org.drip.state.discount.MergedDiscountForwardCurve> me :
  521.             mapCollateralCurrencyDC.entrySet()) {
  522.             org.drip.state.discount.MergedDiscountForwardCurve fcdc = me.getValue();

  523.             if (!(fcdc instanceof org.drip.state.curve.ForeignCollateralizedDiscountCurve)) return null;

  524.             aFCDC[i++] = (org.drip.state.curve.ForeignCollateralizedDiscountCurve) fcdc;
  525.         }

  526.         try {
  527.             return new org.drip.state.curve.DeterministicCollateralChoiceDiscountCurve
  528.                 (mapCollateralCurrencyDC.get (strPayCurrency), aFCDC, 30);
  529.         } catch (java.lang.Exception e) {
  530.             e.printStackTrace();
  531.         }

  532.         return null;
  533.     }

  534.     /**
  535.      * Retrieve the Credit Latent State from the Label
  536.      *
  537.      * @param creditLabel The Credit Latent State Label
  538.      *
  539.      * @return The Credit Latent State from the Label
  540.      */

  541.     public org.drip.state.credit.CreditCurve creditState (
  542.         final org.drip.state.identifier.EntityCDSLabel creditLabel)
  543.     {
  544.         if (null == creditLabel) return null;

  545.         java.lang.String strCreditLabel = creditLabel.fullyQualifiedName();

  546.         return !_mapCreditState.containsKey (strCreditLabel) ? null : _mapCreditState.get (strCreditLabel);
  547.     }

  548.     /**
  549.      * (Re)-set the Credit State
  550.      *
  551.      * @param cc The Credit State
  552.      *
  553.      * @return TRUE - Successfully set
  554.      */

  555.     public boolean setCreditState (
  556.         final org.drip.state.credit.CreditCurve cc)
  557.     {
  558.         if (null == cc) return false;

  559.         _mapCreditState.put (cc.label().fullyQualifiedName(), cc);

  560.         return true;
  561.     }

  562.     /**
  563.      * Retrieve the Equity State for the specified Equity Latent State Label
  564.      *
  565.      * @param equityLabel The Equity Latent State Label
  566.      *
  567.      * @return Equity Curve
  568.      */

  569.     public org.drip.function.definition.R1ToR1 equityState (
  570.         final org.drip.state.identifier.EntityEquityLabel equityLabel)
  571.     {
  572.         if (null == equityLabel) return null;

  573.         java.lang.String strCode = equityLabel.fullyQualifiedName();

  574.         return _mapEquityState.containsKey (strCode) ? _mapEquityState.get (strCode) : null;
  575.     }

  576.     /**
  577.      * (Re)-set the Equity State for the specified Equity Latent State Label
  578.      *
  579.      * @param equityLabel The Equity Latent State Label
  580.      * @param auEquity The Equity State
  581.      *
  582.      * @return TRUE - Successfully set
  583.      */

  584.     public boolean setEquityState (
  585.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  586.         final org.drip.function.definition.R1ToR1 auEquity)
  587.     {
  588.         if (null == equityLabel || null == auEquity) return false;

  589.         _mapEquityState.put (equityLabel.fullyQualifiedName(), auEquity);

  590.         return true;
  591.     }

  592.     /**
  593.      * Retrieve the Forward State corresponding to the Label
  594.      *
  595.      * @param forwardLabel Forward Latent State Label
  596.      *
  597.      * @return Forward Curve
  598.      */

  599.     public org.drip.state.forward.ForwardCurve forwardState (
  600.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  601.     {
  602.         if (null == forwardLabel) return null;

  603.         java.lang.String strForwardLabel = forwardLabel.fullyQualifiedName();

  604.         return _mapForwardState.containsKey (strForwardLabel) ? _mapForwardState.get (strForwardLabel) :
  605.             null;
  606.     }

  607.     /**
  608.      * (Re)-set the Forward State
  609.      *
  610.      * @param fc Forward State
  611.      *
  612.      * @return TRUE - Successfully set
  613.      */

  614.     public boolean setForwardState (
  615.         final org.drip.state.forward.ForwardCurve fc)
  616.     {
  617.         if (null == fc) return false;

  618.         _mapForwardState.put (fc.label().fullyQualifiedName(), fc);

  619.         return true;
  620.     }

  621.     /**
  622.      * Retrieve the Funding Latent State Corresponding to the Label
  623.      *
  624.      * @param fundingLabel Funding Latent State Label
  625.      *
  626.      * @return The Funding Latent State
  627.      */

  628.     public org.drip.state.discount.MergedDiscountForwardCurve fundingState (
  629.         final org.drip.state.identifier.FundingLabel fundingLabel)
  630.     {
  631.         if (null == fundingLabel) return null;

  632.         java.lang.String strFundingLabel = fundingLabel.fullyQualifiedName();

  633.         return _mapFundingState.containsKey (strFundingLabel) ? _mapFundingState.get (strFundingLabel) :
  634.             null;
  635.     }

  636.     /**
  637.      * (Re)-set the Funding State
  638.      *
  639.      * @param dc Funding State
  640.      *
  641.      * @return TRUE - Successfully set
  642.      */

  643.     public boolean setFundingState (
  644.         final org.drip.state.discount.MergedDiscountForwardCurve dc)
  645.     {
  646.         if (null == dc) return false;

  647.         _mapFundingState.put (dc.label().fullyQualifiedName(), dc);

  648.         return true;
  649.     }

  650.     /**
  651.      * Retrieve the FX State for the specified FX Latent State Label
  652.      *
  653.      * @param fxLabel The FX Latent State Label
  654.      *
  655.      * @return FX Curve
  656.      */

  657.     public org.drip.state.fx.FXCurve fxState (
  658.         final org.drip.state.identifier.FXLabel fxLabel)
  659.     {
  660.         if (null == fxLabel) return null;

  661.         java.lang.String strCode = fxLabel.fullyQualifiedName();

  662.         return _mapFXState.containsKey (strCode) ? _mapFXState.get (strCode) : null;
  663.     }

  664.     /**
  665.      * (Re)-set the FX State for the specified FX Latent State Label
  666.      *
  667.      * @param fxfc The FX State
  668.      *
  669.      * @return TRUE - Successfully set
  670.      */

  671.     public boolean setFXState (
  672.         final org.drip.state.fx.FXCurve fxfc)
  673.     {
  674.         if (null == fxfc) return false;

  675.         org.drip.state.identifier.FXLabel fxLabel = (org.drip.state.identifier.FXLabel) fxfc.label();

  676.         _mapFXState.put (fxLabel.fullyQualifiedName(), fxfc);

  677.         return true;
  678.     }

  679.     /**
  680.      * Retrieve the Government State for the specified Label
  681.      *
  682.      * @param govvieLabel Govvie Latent State Label
  683.      *
  684.      * @return Government Curve for the specified Label
  685.      */

  686.     public org.drip.state.govvie.GovvieCurve govvieState (
  687.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  688.     {
  689.         if (null == govvieLabel) return null;

  690.         java.lang.String strGovvieLabel = govvieLabel.fullyQualifiedName();

  691.         return !_mapGovvieState.containsKey (strGovvieLabel) ? null : _mapGovvieState.get (strGovvieLabel);
  692.     }

  693.     /**
  694.      * (Re)-set the Govvie State Curve
  695.      *
  696.      * @param gc Govvie State Curve
  697.      *
  698.      * @return TRUE - Successfully set
  699.      */

  700.     public boolean setGovvieState (
  701.         final org.drip.state.govvie.GovvieCurve gc)
  702.     {
  703.         if (null == gc) return false;

  704.         _mapGovvieState.put (gc.label().fullyQualifiedName(), gc);

  705.         return true;
  706.     }

  707.     /**
  708.      * Retrieve the Overnight Latent State Corresponding to the Label
  709.      *
  710.      * @param overnightLabel Overnight Latent State Label
  711.      *
  712.      * @return The Overnight Latent State
  713.      */

  714.     public org.drip.state.discount.MergedDiscountForwardCurve overnightState (
  715.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  716.     {
  717.         if (null == overnightLabel) return null;

  718.         java.lang.String strOvernightLabel = overnightLabel.fullyQualifiedName();

  719.         return _mapOvernightState.containsKey (strOvernightLabel) ? _mapOvernightState.get
  720.             (strOvernightLabel) : null;
  721.     }

  722.     /**
  723.      * (Re)-set the Overnight State
  724.      *
  725.      * @param dcOvernight Overnight State Curve
  726.      *
  727.      * @return TRUE - Successfully set
  728.      */

  729.     public boolean setOvernightState (
  730.         final org.drip.state.discount.MergedDiscountForwardCurve dcOvernight)
  731.     {
  732.         if (null == dcOvernight) return false;

  733.         _mapOvernightState.put (dcOvernight.label().fullyQualifiedName(), dcOvernight);

  734.         return true;
  735.     }

  736.     /**
  737.      * Retrieve the Pay-down State for the specified Pay-down Latent State Label
  738.      *
  739.      * @param paydownLabel The Pay-down Latent State Label
  740.      *
  741.      * @return Pay-down State
  742.      */

  743.     public org.drip.function.definition.R1ToR1 paydownState (
  744.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  745.     {
  746.         if (null == paydownLabel) return null;

  747.         java.lang.String strCode = paydownLabel.fullyQualifiedName();

  748.         return _mapPaydownState.containsKey (strCode) ? _mapPaydownState.get (strCode) : null;
  749.     }

  750.     /**
  751.      * (Re)-set the Pay-down State for the specified Pay-down Latent State Label
  752.      *
  753.      * @param paydownLabel The Pay-down Latent State Label
  754.      * @param auPaydown The Pay-down State
  755.      *
  756.      * @return TRUE - Successfully set
  757.      */

  758.     public boolean setPaydownCurve (
  759.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  760.         final org.drip.function.definition.R1ToR1 auPaydown)
  761.     {
  762.         if (null == paydownLabel || null == auPaydown) return false;

  763.         _mapPaydownState.put (paydownLabel.fullyQualifiedName(), auPaydown);

  764.         return true;
  765.     }

  766.     /**
  767.      * Retrieve the Rating State for the specified Rating Latent State Label
  768.      *
  769.      * @param ratingLabel The Rating Latent State Label
  770.      *
  771.      * @return Rating State
  772.      */

  773.     public org.drip.state.discount.MergedDiscountForwardCurve ratingState (
  774.         final org.drip.state.identifier.RatingLabel ratingLabel)
  775.     {
  776.         if (null == ratingLabel) return null;

  777.         java.lang.String strCode = ratingLabel.fullyQualifiedName();

  778.         return _mapRatingState.containsKey (strCode) ? _mapRatingState.get (strCode) : null;
  779.     }

  780.     /**
  781.      * (Re)-set the Rating State for the specified Rating Latent State Label
  782.      *
  783.      * @param ratingLabel The Rating Latent State Label
  784.      * @param dcRating The Rating State
  785.      *
  786.      * @return TRUE - Successfully set
  787.      */

  788.     public boolean setRatingCurve (
  789.         final org.drip.state.identifier.RatingLabel ratingLabel,
  790.         final org.drip.state.discount.MergedDiscountForwardCurve dcRating)
  791.     {
  792.         if (null == ratingLabel || null == dcRating) return false;

  793.         _mapRatingState.put (ratingLabel.fullyQualifiedName(), dcRating);

  794.         return true;
  795.     }

  796.     /**
  797.      * Retrieve the Recovery Latent State from the Label
  798.      *
  799.      * @param recoveryLabel The Recovery Latent State Label
  800.      *
  801.      * @return The Recovery Latent State from the Label
  802.      */

  803.     public org.drip.state.credit.CreditCurve recoveryState (
  804.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  805.     {
  806.         if (null == recoveryLabel) return null;

  807.         java.lang.String strRecoveryLabel = recoveryLabel.fullyQualifiedName();

  808.         return !_mapRecoveryState.containsKey (strRecoveryLabel) ? null : _mapRecoveryState.get
  809.             (strRecoveryLabel);
  810.     }

  811.     /**
  812.      * (Re)-set the Recovery State for the specified Recovery Latent State Label
  813.      *
  814.      * @param rc The Recovery State
  815.      *
  816.      * @return TRUE - Successfully set
  817.      */

  818.     public boolean setRecoveryState (
  819.         final org.drip.state.credit.CreditCurve rc)
  820.     {
  821.         if (null == rc) return false;

  822.         _mapRecoveryState.put (rc.label().fullyQualifiedName(), rc);

  823.         return true;
  824.     }

  825.     /**
  826.      * Retrieve the Repo Latent State Corresponding to the Label
  827.      *
  828.      * @param repoLabel Repo Latent State Label
  829.      *
  830.      * @return The Repo Latent State
  831.      */

  832.     public org.drip.state.repo.RepoCurve repoState (
  833.         final org.drip.state.identifier.RepoLabel repoLabel)
  834.     {
  835.         if (null == repoLabel) return null;

  836.         java.lang.String strRepoLabel = repoLabel.fullyQualifiedName();

  837.         return _mapRepoState.containsKey (strRepoLabel) ? _mapRepoState.get (strRepoLabel) : null;
  838.     }

  839.     /**
  840.      * (Re)-set the Repo State
  841.      *
  842.      * @param repoState Repo State
  843.      *
  844.      * @return TRUE - Successfully set
  845.      */

  846.     public boolean setRepoState (
  847.         final org.drip.state.repo.RepoCurve repoState)
  848.     {
  849.         if (null == repoState) return false;

  850.         _mapRepoState.put (repoState.label().fullyQualifiedName(), repoState);

  851.         return true;
  852.     }

  853.     /**
  854.      * Retrieve the Volatility Curve for the specified Collateral Label
  855.      *
  856.      * @param collateralLabel The Collateral Currency
  857.      *
  858.      * @return The Volatility Curve for the Collateral Label
  859.      */

  860.     public org.drip.state.volatility.VolatilityCurve collateralVolatility (
  861.         final org.drip.state.identifier.CollateralLabel collateralLabel)
  862.     {
  863.         if (null == collateralLabel) return null;

  864.         java.lang.String strCollateralLabel = collateralLabel.fullyQualifiedName();

  865.         return !_mapCollateralVolatility.containsKey (strCollateralLabel) ? null :
  866.             _mapCollateralVolatility.get (strCollateralLabel);
  867.     }

  868.     /**
  869.      * (Re)-set the Volatility Curve for the specified Collateral Label
  870.      *
  871.      * @param vcCollateral The Collateral Volatility Curve
  872.      *
  873.      * @return TRUE - Successfully set
  874.      */

  875.     public boolean setCollateralVolatility (
  876.         final org.drip.state.volatility.VolatilityCurve vcCollateral)
  877.     {
  878.         if (null == vcCollateral) return false;

  879.         _mapCollateralVolatility.put (vcCollateral.label().fullyQualifiedName(), vcCollateral);

  880.         return true;
  881.     }

  882.     /**
  883.      * Retrieve the Volatility Curve for the Credit Latent State
  884.      *
  885.      * @param creditLabel The Credit Curve Latent State Label
  886.      *
  887.      * @return The Volatility Curve for the Credit Latent State
  888.      */

  889.     public org.drip.state.volatility.VolatilityCurve creditVolatility (
  890.         final org.drip.state.identifier.EntityCDSLabel creditLabel)
  891.     {
  892.         if (null == creditLabel) return null;

  893.         java.lang.String strCreditLabel = creditLabel.fullyQualifiedName();

  894.         return  !_mapCreditVolatility.containsKey (strCreditLabel) ? null : _mapCreditVolatility.get
  895.             (strCreditLabel);
  896.     }

  897.     /**
  898.      * (Re)-set the Volatility Curve for the Credit Latent State
  899.      *
  900.      * @param vcCredit The Credit Volatility Curve
  901.      *
  902.      * @return TRUE - Successfully set
  903.      */

  904.     public boolean setCreditVolatility (
  905.         final org.drip.state.volatility.VolatilityCurve vcCredit)
  906.     {
  907.         if (null == vcCredit) return false;

  908.         _mapCreditVolatility.put (vcCredit.label().fullyQualifiedName(), vcCredit);

  909.         return true;
  910.     }

  911.     /**
  912.      * Retrieve the Volatility Curve for the Custom Metric Latent State
  913.      *
  914.      * @param customLabel The Custom Metric Latent State Label
  915.      *
  916.      * @return The Volatility Curve for the Custom Metric Latent State
  917.      */

  918.     public org.drip.state.volatility.VolatilityCurve customVolatility (
  919.         final org.drip.state.identifier.CustomLabel customLabel)
  920.     {
  921.         if (null == customLabel) return null;

  922.         java.lang.String strCustomLabel = customLabel.fullyQualifiedName();

  923.         return _mapCustomVolatility.containsKey (strCustomLabel) ? _mapCustomVolatility.get (strCustomLabel)
  924.             : null;
  925.     }

  926.     /**
  927.      * (Re)-set the Custom Metric Volatility Curve
  928.      *
  929.      * @param vcCustom The Custom Metric Volatility Curve
  930.      *
  931.      * @return TRUE - Successfully set
  932.      */

  933.     public boolean setCustomVolatility (
  934.         final org.drip.state.volatility.VolatilityCurve vcCustom)
  935.     {
  936.         if (null == vcCustom) return false;

  937.         _mapCustomVolatility.put (vcCustom.label().fullyQualifiedName(), vcCustom);

  938.         return true;
  939.     }

  940.     /**
  941.      * Retrieve the Volatility Curve for the Equity Latent State
  942.      *
  943.      * @param equityLabel The Equity Latent State Label
  944.      *
  945.      * @return The Volatility Curve for the Equity Latent State
  946.      */

  947.     public org.drip.state.volatility.VolatilityCurve equityVolatility (
  948.         final org.drip.state.identifier.EntityEquityLabel equityLabel)
  949.     {
  950.         if (null == equityLabel) return null;

  951.         java.lang.String strEquityLabel = equityLabel.fullyQualifiedName();

  952.         return  !_mapEquityVolatility.containsKey (strEquityLabel) ? null : _mapEquityVolatility.get
  953.             (strEquityLabel);
  954.     }

  955.     /**
  956.      * (Re)-set the Volatility Curve for the Equity Latent State
  957.      *
  958.      * @param vcEquity The Equity Volatility Curve
  959.      *
  960.      * @return TRUE - Successfully set
  961.      */

  962.     public boolean setEquityVolatility (
  963.         final org.drip.state.volatility.VolatilityCurve vcEquity)
  964.     {
  965.         if (null == vcEquity) return false;

  966.         _mapEquityVolatility.put (vcEquity.label().fullyQualifiedName(), vcEquity);

  967.         return true;
  968.     }

  969.     /**
  970.      * Retrieve the Volatility Curve for the specified Forward Latent State Label
  971.      *
  972.      * @param forwardLabel The Forward Latent State Label
  973.      *
  974.      * @return The Volatility Curve for the Forward Label
  975.      */

  976.     public org.drip.state.volatility.VolatilityCurve forwardVolatility (
  977.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  978.     {
  979.         if (null == forwardLabel) return null;

  980.         java.lang.String strForwardLabel = forwardLabel.fullyQualifiedName();

  981.         return _mapForwardVolatility.containsKey (strForwardLabel) ? _mapForwardVolatility.get
  982.             (strForwardLabel) : null;
  983.     }

  984.     /**
  985.      * (Re)-set the Volatility Curve for the specified Forward Latent State Label
  986.      *
  987.      * @param vcForward The Forward Volatility Curve
  988.      *
  989.      * @return TRUE - Successfully set
  990.      */

  991.     public boolean setForwardVolatility (
  992.         final org.drip.state.volatility.VolatilityCurve vcForward)
  993.     {
  994.         if (null == vcForward) return false;

  995.         _mapForwardVolatility.put (vcForward.label().fullyQualifiedName(), vcForward);

  996.         return true;
  997.     }

  998.     /**
  999.      * Retrieve the Volatility Curve for the Funding Latent State Label
  1000.      *
  1001.      * @param fundingLabel The Funding Latent State Label
  1002.      *
  1003.      * @return The Volatility Curve for the Funding Label
  1004.      */

  1005.     public org.drip.state.volatility.VolatilityCurve fundingVolatility (
  1006.         final org.drip.state.identifier.FundingLabel fundingLabel)
  1007.     {
  1008.         if (null == fundingLabel) return null;

  1009.         java.lang.String strFundingLabel = fundingLabel.fullyQualifiedName();

  1010.         return _mapFundingVolatility.containsKey (strFundingLabel) ? _mapFundingVolatility.get
  1011.             (strFundingLabel) : null;
  1012.     }

  1013.     /**
  1014.      * (Re)-set the Volatility Curve for the Funding Latent State Label
  1015.      *
  1016.      * @param vcFunding The Funding Volatility Curve
  1017.      *
  1018.      * @return TRUE - Successfully set
  1019.      */

  1020.     public boolean setFundingVolatility (
  1021.         final org.drip.state.volatility.VolatilityCurve vcFunding)
  1022.     {
  1023.         if (null == vcFunding) return false;

  1024.         _mapFundingVolatility.put (vcFunding.label().fullyQualifiedName(), vcFunding);

  1025.         return true;
  1026.     }

  1027.     /**
  1028.      * Retrieve the Volatility Curve for the specified FX Latent State Label
  1029.      *
  1030.      * @param fxLabel The FX Latent State Label
  1031.      *
  1032.      * @return The Volatility Curve for the FX Latent State Label
  1033.      */

  1034.     public org.drip.state.volatility.VolatilityCurve fxVolatility (
  1035.         final org.drip.state.identifier.FXLabel fxLabel)
  1036.     {
  1037.         if (null == fxLabel) return null;

  1038.         java.lang.String strFXLabel = fxLabel.fullyQualifiedName();

  1039.         return !_mapFXVolatility.containsKey (strFXLabel) ? null : _mapFXVolatility.get (strFXLabel);
  1040.     }

  1041.     /**
  1042.      * (Re)-set the Volatility Curve for the specified FX Latent State
  1043.      *
  1044.      * @param vcFX The FX Volatility Surface
  1045.      *
  1046.      * @return TRUE - Successfully set
  1047.      */

  1048.     public boolean setFXVolatility (
  1049.         final org.drip.state.volatility.VolatilityCurve vcFX)
  1050.     {
  1051.         if (null == vcFX) return false;

  1052.         _mapFXVolatility.put (vcFX.label().fullyQualifiedName(), vcFX);

  1053.         return true;
  1054.     }

  1055.     /**
  1056.      * Retrieve the Volatility Curve for the specified Govvie Latent State
  1057.      *
  1058.      * @param govvieLabel The Govvie Latent State Label
  1059.      *
  1060.      * @return The Volatility Curve for the Govvie Latent State
  1061.      */

  1062.     public org.drip.state.volatility.VolatilityCurve govvieVolatility (
  1063.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  1064.     {
  1065.         if (null == govvieLabel) return null;

  1066.         java.lang.String strGovvieLabel = govvieLabel.fullyQualifiedName();

  1067.         return !_mapGovvieVolatility.containsKey (strGovvieLabel) ? null : _mapGovvieVolatility.get
  1068.             (strGovvieLabel);
  1069.     }

  1070.     /**
  1071.      * (Re)-set the Volatility Curve for the Govvie Latent State
  1072.      *
  1073.      * @param vcGovvie The Govvie Volatility Curve
  1074.      *
  1075.      * @return TRUE - Successfully set
  1076.      */

  1077.     public boolean setGovvieVolatility (
  1078.         final org.drip.state.volatility.VolatilityCurve vcGovvie)
  1079.     {
  1080.         if (null == vcGovvie) return false;

  1081.         _mapGovvieVolatility.put (vcGovvie.label().fullyQualifiedName(), vcGovvie);

  1082.         return true;
  1083.     }

  1084.     /**
  1085.      * Retrieve the Volatility Curve for the Overnight Latent State Label
  1086.      *
  1087.      * @param overnightLabel The Overnight Latent State Label
  1088.      *
  1089.      * @return The Volatility Curve for the Overnight Label
  1090.      */

  1091.     public org.drip.state.volatility.VolatilityCurve overnightVolatility (
  1092.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  1093.     {
  1094.         if (null == overnightLabel) return null;

  1095.         java.lang.String strOvernightLabel = overnightLabel.fullyQualifiedName();

  1096.         return _mapOvernightVolatility.containsKey (strOvernightLabel) ? _mapOvernightVolatility.get
  1097.             (strOvernightLabel) : null;
  1098.     }

  1099.     /**
  1100.      * (Re)-set the Volatility Curve for the Overnight Latent State Label
  1101.      *
  1102.      * @param vcOvernight The Overnight Volatility Surface
  1103.      *
  1104.      * @return TRUE - Successfully set
  1105.      */

  1106.     public boolean setOvernightVolatility (
  1107.         final org.drip.state.volatility.VolatilityCurve vcOvernight)
  1108.     {
  1109.         if (null == vcOvernight) return false;

  1110.         _mapOvernightVolatility.put (vcOvernight.label().fullyQualifiedName(), vcOvernight);

  1111.         return true;
  1112.     }

  1113.     /**
  1114.      * Retrieve the Volatility Curve for the specified Pay-down Latent State
  1115.      *
  1116.      * @param paydownLabel The Pay Down Latent State Label
  1117.      *
  1118.      * @return The Volatility Curve for the Pay-down Latent State
  1119.      */

  1120.     public org.drip.state.volatility.VolatilityCurve paydownVolaitlity (
  1121.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  1122.     {
  1123.         if (null == paydownLabel) return null;

  1124.         java.lang.String strPaydownLabel = paydownLabel.fullyQualifiedName();

  1125.         return !_mapPaydownVolatility.containsKey (strPaydownLabel) ? null : _mapPaydownVolatility.get
  1126.             (strPaydownLabel);
  1127.     }

  1128.     /**
  1129.      * (Re)-set the Volatility Curve for the Pay-down Latent State
  1130.      *
  1131.      * @param vcPaydown The Pay down Volatility Curve
  1132.      *
  1133.      * @return TRUE - Successfully set
  1134.      */

  1135.     public boolean setPaydownVolatility (
  1136.         final org.drip.state.volatility.VolatilityCurve vcPaydown)
  1137.     {
  1138.         if (null == vcPaydown) return false;

  1139.         _mapPaydownVolatility.put (vcPaydown.label().fullyQualifiedName(), vcPaydown);

  1140.         return true;
  1141.     }

  1142.     /**
  1143.      * Retrieve the Volatility Curve for the specified Rating Latent State
  1144.      *
  1145.      * @param ratingLabel The Rating Latent State Label
  1146.      *
  1147.      * @return The Volatility Curve for the Rating Latent State
  1148.      */

  1149.     public org.drip.state.volatility.VolatilityCurve ratingVolaitlity (
  1150.         final org.drip.state.identifier.RatingLabel ratingLabel)
  1151.     {
  1152.         if (null == ratingLabel) return null;

  1153.         java.lang.String strRatingLabel = ratingLabel.fullyQualifiedName();

  1154.         return !_mapRatingVolatility.containsKey (strRatingLabel) ? null : _mapRatingVolatility.get
  1155.             (strRatingLabel);
  1156.     }

  1157.     /**
  1158.      * (Re)-set the Volatility Curve for the Rating Latent State
  1159.      *
  1160.      * @param vcRating The Rating Volatility Curve
  1161.      *
  1162.      * @return TRUE - Successfully set
  1163.      */

  1164.     public boolean setRatingVolatility (
  1165.         final org.drip.state.volatility.VolatilityCurve vcRating)
  1166.     {
  1167.         if (null == vcRating) return false;

  1168.         _mapRatingVolatility.put (vcRating.label().fullyQualifiedName(), vcRating);

  1169.         return true;
  1170.     }

  1171.     /**
  1172.      * Retrieve the Volatility Curve for the specified Recovery Latent State
  1173.      *
  1174.      * @param recoveryLabel The Recovery Latent State Label
  1175.      *
  1176.      * @return The Volatility Curve for the Recovery Latent State
  1177.      */

  1178.     public org.drip.state.volatility.VolatilityCurve recoveryVolatility (
  1179.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  1180.     {
  1181.         if (null == recoveryLabel) return null;

  1182.         java.lang.String strRecoveryLabel = recoveryLabel.fullyQualifiedName();

  1183.         return !_mapRecoveryVolatility.containsKey (strRecoveryLabel) ? null : _mapRecoveryVolatility.get
  1184.             (strRecoveryLabel);
  1185.     }

  1186.     /**
  1187.      * (Re)-set the Volatility Curve for the Recovery Latent State
  1188.      *
  1189.      * @param vcRecovery The Recovery Volatility Surface
  1190.      *
  1191.      * @return TRUE - Successfully set
  1192.      */

  1193.     public boolean setRecoveryVolatility (
  1194.         final org.drip.state.volatility.VolatilityCurve vcRecovery)
  1195.     {
  1196.         if (null == vcRecovery) return false;

  1197.         _mapRecoveryVolatility.put (vcRecovery.label().fullyQualifiedName(), vcRecovery);

  1198.         return true;
  1199.     }

  1200.     /**
  1201.      * Retrieve the Volatility Curve for the Repo Latent State Label
  1202.      *
  1203.      * @param repoLabel The Repo Latent State Label
  1204.      *
  1205.      * @return The Volatility Curve for the Repo Label
  1206.      */

  1207.     public org.drip.state.volatility.VolatilityCurve repoVolatility (
  1208.         final org.drip.state.identifier.RepoLabel repoLabel)
  1209.     {
  1210.         if (null == repoLabel) return null;

  1211.         java.lang.String strRepoLabel = repoLabel.fullyQualifiedName();

  1212.         return _mapRepoVolatility.containsKey (strRepoLabel) ? _mapRepoVolatility.get (strRepoLabel) : null;
  1213.     }

  1214.     /**
  1215.      * (Re)-set the Volatility Curve for the Repo Latent State Label
  1216.      *
  1217.      * @param vcRepo The Repo Volatility Curve
  1218.      *
  1219.      * @return TRUE - Successfully set
  1220.      */

  1221.     public boolean setRepoVolatility (
  1222.         final org.drip.state.volatility.VolatilityCurve vcRepo)
  1223.     {
  1224.         if (null == vcRepo) return false;

  1225.         _mapRepoVolatility.put (vcRepo.label().fullyQualifiedName(), vcRepo);

  1226.         return true;
  1227.     }

  1228.     /**
  1229.      * Retrieve the Correlation Surface for the specified Collateral Currency Pair
  1230.      *
  1231.      * @param strCurrency1 Collateral Currency #1
  1232.      * @param strCurrency2 Collateral Currency #2
  1233.      *
  1234.      * @return The Correlation Surface for the specified Collateral Currency Pair
  1235.      */

  1236.     public org.drip.function.definition.R1ToR1 collateralCollateralCorrelation (
  1237.         final java.lang.String strCurrency1,
  1238.         final java.lang.String strCurrency2)
  1239.     {
  1240.         if (null == strCurrency1 || strCurrency1.isEmpty() || null == strCurrency2 || strCurrency2.isEmpty())
  1241.             return null;

  1242.         java.lang.String strCode = strCurrency1 + "@#" + strCurrency2;

  1243.         if (!_mapCollateralCollateralCorrelation.containsKey (strCode)) return null;

  1244.         return _mapCollateralCollateralCorrelation.get (strCode);
  1245.     }

  1246.     /**
  1247.      * (Re)-set the Correlation Surface for the specified Collateral Currency Pair
  1248.      *
  1249.      * @param strCurrency1 Collateral Currency #1
  1250.      * @param strCurrency2 Collateral Currency #2
  1251.      * @param auCorrelation The Correlation Surface
  1252.      *
  1253.      * @return TRUE - Successfully set
  1254.      */

  1255.     public boolean setCollateralCollateralCorrelation (
  1256.         final java.lang.String strCurrency1,
  1257.         final java.lang.String strCurrency2,
  1258.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1259.     {
  1260.         if (null == strCurrency1 || strCurrency1.isEmpty() || null == strCurrency2 || strCurrency2.isEmpty()
  1261.             || null == auCorrelation)
  1262.             return false;

  1263.         _mapCollateralCollateralCorrelation.put (strCurrency1 + "@#" + strCurrency2, auCorrelation);

  1264.         _mapCollateralCollateralCorrelation.put (strCurrency2 + "@#" + strCurrency1, auCorrelation);

  1265.         return true;
  1266.     }

  1267.     /**
  1268.      * Retrieve the Correlation Surface between the Pair of Credit Latent States
  1269.      *
  1270.      * @param creditLabel1 The Credit Curve Latent State Label #1
  1271.      * @param creditLabel2 The Credit Curve Latent State Label #2
  1272.      *
  1273.      * @return The Correlation Surface between the Pair of Credit Latent States
  1274.      */

  1275.     public org.drip.function.definition.R1ToR1 creditCreditCorrelation (
  1276.         final org.drip.state.identifier.EntityCDSLabel creditLabel1,
  1277.         final org.drip.state.identifier.EntityCDSLabel creditLabel2)
  1278.     {
  1279.         if (null == creditLabel1 || null == creditLabel2) return null;

  1280.         java.lang.String strCode12 = creditLabel1.fullyQualifiedName() + "@#" +
  1281.             creditLabel2.fullyQualifiedName();

  1282.         if (_mapCreditCreditCorrelation.containsKey (strCode12))
  1283.             return _mapCreditCreditCorrelation.get (strCode12);

  1284.         java.lang.String strCode21 = creditLabel2.fullyQualifiedName() + "@#" +
  1285.             creditLabel1.fullyQualifiedName();

  1286.         return !_mapCreditCreditCorrelation.containsKey (strCode21) ? null :
  1287.             _mapCreditCreditCorrelation.get (strCode21);
  1288.     }

  1289.     /**
  1290.      * (Re)-set the Correlation Surface between the Pair of Credit Latent States
  1291.      *
  1292.      * @param creditLabel1 The Credit Curve Latent State Label #1
  1293.      * @param creditLabel2 The Credit Curve Latent State Label #2
  1294.      * @param auCorrelation The Correlation Surface
  1295.      *
  1296.      * @return TRUE - Successfully set
  1297.      */

  1298.     public boolean setCreditCreditCorrelation (
  1299.         final org.drip.state.identifier.EntityCDSLabel creditLabel1,
  1300.         final org.drip.state.identifier.EntityCDSLabel creditLabel2,
  1301.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1302.     {
  1303.         if (null == creditLabel1 || null == creditLabel2 || null == auCorrelation) return false;

  1304.         java.lang.String strCreditLabel1 = creditLabel1.fullyQualifiedName();

  1305.         java.lang.String strCreditLabel2 = creditLabel2.fullyQualifiedName();

  1306.         _mapCreditCreditCorrelation.put (strCreditLabel1 + "@#" + strCreditLabel2, auCorrelation);

  1307.         _mapCreditCreditCorrelation.put (strCreditLabel2 + "@#" + strCreditLabel1, auCorrelation);

  1308.         return true;
  1309.     }

  1310.     /**
  1311.      * Retrieve the Correlation Surface between the Custom Metric Latent State Pair
  1312.      *
  1313.      * @param customLabel1 The Custom Metric Latent State Label #1
  1314.      * @param customLabel2 The Custom Metric Latent State Label #2
  1315.      *
  1316.      * @return The Correlation Surface between the Custom Metric Latent State Pair
  1317.      */

  1318.     public org.drip.function.definition.R1ToR1 customCustomCorrelation (
  1319.         final org.drip.state.identifier.CustomLabel customLabel1,
  1320.         final org.drip.state.identifier.CustomLabel customLabel2)
  1321.     {
  1322.         if (null == customLabel1 || null == customLabel2) return null;

  1323.         java.lang.String strCode12 = customLabel1.fullyQualifiedName() + "@#" +
  1324.             customLabel2.fullyQualifiedName();

  1325.         if (_mapCustomCustomCorrelation.containsKey (strCode12))
  1326.             return _mapCustomCustomCorrelation.get (strCode12);

  1327.         java.lang.String strCode21 = customLabel2.fullyQualifiedName() + "@#" +
  1328.             customLabel1.fullyQualifiedName();

  1329.         return _mapCustomCustomCorrelation.containsKey (strCode21) ?
  1330.             _mapCustomCustomCorrelation.get (strCode21) : null;
  1331.     }

  1332.     /**
  1333.      * (Re)-set the Correlation Surface between the Custom Metric Latent State Pair
  1334.      *
  1335.      * @param customLabel1 The Custom Metric Latent State Label #1
  1336.      * @param customLabel2 The Custom Metric Latent State Label #2
  1337.      * @param auCorrelation The Correlation Surface
  1338.      *
  1339.      * @return TRUE - Successfully set
  1340.      */

  1341.     public boolean setCustomCustomCorrelation (
  1342.         final org.drip.state.identifier.CustomLabel customLabel1,
  1343.         final org.drip.state.identifier.CustomLabel customLabel2,
  1344.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1345.     {
  1346.         if (null == customLabel1 || null == customLabel2 || customLabel1.match (customLabel2) || null ==
  1347.             auCorrelation)
  1348.             return false;

  1349.         _mapCustomCustomCorrelation.put (customLabel1.fullyQualifiedName() + "@#" +
  1350.             customLabel2.fullyQualifiedName(), auCorrelation);

  1351.         _mapCustomCustomCorrelation.put (customLabel2.fullyQualifiedName() + "@#" +
  1352.             customLabel1.fullyQualifiedName(), auCorrelation);

  1353.         return true;
  1354.     }

  1355.     /**
  1356.      * Retrieve the Correlation Surface between the Pair of Equity Latent States
  1357.      *
  1358.      * @param equityLabel1 Equity Curve Latent State Label #1
  1359.      * @param equityLabel2 EquityCurve Latent State Label #2
  1360.      *
  1361.      * @return The Correlation Surface between the Pair of Equity Latent States
  1362.      */

  1363.     public org.drip.function.definition.R1ToR1 equityEquityCorrelation (
  1364.         final org.drip.state.identifier.EntityEquityLabel equityLabel1,
  1365.         final org.drip.state.identifier.EntityEquityLabel equityLabel2)
  1366.     {
  1367.         if (null == equityLabel1 || null == equityLabel2) return null;

  1368.         java.lang.String strCode = equityLabel1.fullyQualifiedName() + "@#" +
  1369.             equityLabel2.fullyQualifiedName();

  1370.         return _mapEquityEquityCorrelation.containsKey (strCode) ?
  1371.             _mapEquityEquityCorrelation.get (strCode) : null;
  1372.     }

  1373.     /**
  1374.      * (Re)-set the Correlation Surface between the Pair of Equity Latent States
  1375.      *
  1376.      * @param equityLabel1 EquityCurve Latent State Label #1
  1377.      * @param equityLabel2 EquityCurve Latent State Label #2
  1378.      * @param auCorrelation The Correlation Surface
  1379.      *
  1380.      * @return TRUE - Successfully set
  1381.      */

  1382.     public boolean setEquityEquityCorrelation (
  1383.         final org.drip.state.identifier.EntityEquityLabel equityLabel1,
  1384.         final org.drip.state.identifier.EntityEquityLabel equityLabel2,
  1385.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1386.     {
  1387.         if (null == equityLabel1 || null == equityLabel2 || equityLabel1.match (equityLabel2) || null ==
  1388.             auCorrelation)
  1389.             return false;

  1390.         java.lang.String strEquityLabel1 = equityLabel1.fullyQualifiedName();

  1391.         java.lang.String strEquityLabel2 = equityLabel2.fullyQualifiedName();

  1392.         _mapEquityEquityCorrelation.put (strEquityLabel1 + "@#" + strEquityLabel2, auCorrelation);

  1393.         _mapEquityEquityCorrelation.put (strEquityLabel2 + "@#" + strEquityLabel1, auCorrelation);

  1394.         return true;
  1395.     }

  1396.     /**
  1397.      * Retrieve the Correlation Surface between the Pair of Forward Latent States
  1398.      *
  1399.      * @param forwardLabel1 Forward Curve Latent State Label #1
  1400.      * @param forwardLabel2 Forward Curve Latent State Label #2
  1401.      *
  1402.      * @return The Correlation Surface between the Pair of Forward Latent States
  1403.      */

  1404.     public org.drip.function.definition.R1ToR1 forwardForwardCorrelation (
  1405.         final org.drip.state.identifier.ForwardLabel forwardLabel1,
  1406.         final org.drip.state.identifier.ForwardLabel forwardLabel2)
  1407.     {
  1408.         if (null == forwardLabel1 || null == forwardLabel2) return null;

  1409.         java.lang.String strCode = forwardLabel1.fullyQualifiedName() + "@#" +
  1410.             forwardLabel2.fullyQualifiedName();

  1411.         return _mapForwardForwardCorrelation.containsKey (strCode) ?
  1412.             _mapForwardForwardCorrelation.get (strCode) : null;
  1413.     }

  1414.     /**
  1415.      * (Re)-set the Correlation Surface between the Pair of Forward Latent States
  1416.      *
  1417.      * @param forwardLabel1 Forward Curve Latent State Label #1
  1418.      * @param forwardLabel2 Forward Curve Latent State Label #2
  1419.      * @param auCorrelation The Correlation Surface
  1420.      *
  1421.      * @return TRUE - Successfully set
  1422.      */

  1423.     public boolean setForwardForwardCorrelation (
  1424.         final org.drip.state.identifier.ForwardLabel forwardLabel1,
  1425.         final org.drip.state.identifier.ForwardLabel forwardLabel2,
  1426.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1427.     {
  1428.         if (null == forwardLabel1 || null == forwardLabel2 || forwardLabel1.match (forwardLabel2) || null ==
  1429.             auCorrelation)
  1430.             return false;

  1431.         java.lang.String strForwardLabel1 = forwardLabel1.fullyQualifiedName();

  1432.         java.lang.String strForwardLabel2 = forwardLabel2.fullyQualifiedName();

  1433.         _mapForwardForwardCorrelation.put (strForwardLabel1 + "@#" + strForwardLabel2, auCorrelation);

  1434.         _mapForwardForwardCorrelation.put (strForwardLabel2 + "@#" + strForwardLabel1, auCorrelation);

  1435.         return true;
  1436.     }

  1437.     /**
  1438.      * Retrieve the Correlation Surface between the Pair of Funding Latent States
  1439.      *
  1440.      * @param fundingLabel1 Funding Latent State Label #1
  1441.      * @param fundingLabel2 Funding Latent State Label #2
  1442.      *
  1443.      * @return The Correlation Surface between the Pair of Funding Latent States
  1444.      */

  1445.     public org.drip.function.definition.R1ToR1 fundingFundingCorrelation (
  1446.         final org.drip.state.identifier.FundingLabel fundingLabel1,
  1447.         final org.drip.state.identifier.FundingLabel fundingLabel2)
  1448.     {
  1449.         if (null == fundingLabel1 || null == fundingLabel2 || fundingLabel1.match (fundingLabel2))
  1450.             return null;

  1451.         java.lang.String strCode = fundingLabel1.fullyQualifiedName() + "@#" +
  1452.             fundingLabel2.fullyQualifiedName();

  1453.         return _mapFundingFundingCorrelation.containsKey (strCode) ?
  1454.             _mapFundingFundingCorrelation.get (strCode) : null;
  1455.     }

  1456.     /**
  1457.      * (Re)-set the Correlation Surface between the Pair of Funding Latent States
  1458.      *
  1459.      * @param fundingLabel1 Funding Latent State Label #1
  1460.      * @param fundingLabel2 Funding Latent State Label #2
  1461.      * @param auCorrelation The Correlation Surface
  1462.      *
  1463.      * @return TRUE - Successfully set
  1464.      */

  1465.     public boolean setFundingFundingCorrelation (
  1466.         final org.drip.state.identifier.FundingLabel fundingLabel1,
  1467.         final org.drip.state.identifier.FundingLabel fundingLabel2,
  1468.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1469.     {
  1470.         if (null == fundingLabel1 || null == fundingLabel2 || fundingLabel1.match (fundingLabel2) || null ==
  1471.             auCorrelation)
  1472.             return false;

  1473.         java.lang.String strFundingLabel1 = fundingLabel1.fullyQualifiedName();

  1474.         java.lang.String strFundingLabel2 = fundingLabel2.fullyQualifiedName();

  1475.         _mapFundingFundingCorrelation.put (strFundingLabel1 + "@#" + strFundingLabel2, auCorrelation);

  1476.         _mapFundingFundingCorrelation.put (strFundingLabel2 + "@#" + strFundingLabel1, auCorrelation);

  1477.         return true;
  1478.     }

  1479.     /**
  1480.      * Retrieve the Correlation Surface for the specified FX Latent State Label Set
  1481.      *
  1482.      * @param fxLabel1 The FX Latent State Label #1
  1483.      * @param fxLabel2 The FX Latent State Label #2
  1484.      *
  1485.      * @return The Correlation Surface for the specified FX Latent State Label Set
  1486.      */

  1487.     public org.drip.function.definition.R1ToR1 fxFXCorrelation (
  1488.         final org.drip.state.identifier.FXLabel fxLabel1,
  1489.         final org.drip.state.identifier.FXLabel fxLabel2)
  1490.     {
  1491.         if (null == fxLabel1 || null == fxLabel2 || fxLabel1.match (fxLabel2)) return null;

  1492.         java.lang.String strCode = fxLabel1.fullyQualifiedName() + "@#" + fxLabel2.fullyQualifiedName();

  1493.         return !_mapFXFXCorrelation.containsKey (strCode) ? null : _mapFXFXCorrelation.get
  1494.             (strCode);
  1495.     }

  1496.     /**
  1497.      * (Re)-set the Correlation Surface for the specified FX Latent State Label Set
  1498.      *
  1499.      * @param fxLabel1 The FX Latent State Label #1
  1500.      * @param fxLabel2 The FX Latent State Label #2
  1501.      * @param auCorrelation The Correlation Surface
  1502.      *
  1503.      * @return TRUE - Successfully set
  1504.      */

  1505.     public boolean setFXFXCorrelation (
  1506.         final org.drip.state.identifier.FXLabel fxLabel1,
  1507.         final org.drip.state.identifier.FXLabel fxLabel2,
  1508.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1509.     {
  1510.         if (null == fxLabel1 || null == fxLabel2 || fxLabel1.match (fxLabel2) || null == auCorrelation)
  1511.             return false;

  1512.         java.lang.String strCode1 = fxLabel1.fullyQualifiedName();

  1513.         java.lang.String strCode2 = fxLabel2.fullyQualifiedName();

  1514.         _mapFXFXCorrelation.put (strCode1 + "@#" + strCode2, auCorrelation);

  1515.         _mapFXFXCorrelation.put (strCode2 + "@#" + strCode1, auCorrelation);

  1516.         return true;
  1517.     }

  1518.     /**
  1519.      * Retrieve the Correlation Surface for the specified Govvie Latent State Pair
  1520.      *
  1521.      * @param govvieLabel1 The Govvie Curve Latent State Label #1
  1522.      * @param govvieLabel2 The Govvie Curve Latent State Label #2
  1523.      *
  1524.      * @return The Correlation Surface for the specified Govvie Latent State Pair
  1525.      */

  1526.     public org.drip.function.definition.R1ToR1 govvieGovvieCorrelation (
  1527.         final org.drip.state.identifier.GovvieLabel govvieLabel1,
  1528.         final org.drip.state.identifier.GovvieLabel govvieLabel2)
  1529.     {
  1530.         if (null == govvieLabel1 || null == govvieLabel2 || govvieLabel1.match (govvieLabel2)) return null;

  1531.         java.lang.String strCode12 = govvieLabel1.fullyQualifiedName() + "@#" +
  1532.             govvieLabel2.fullyQualifiedName();

  1533.         if (_mapGovvieGovvieCorrelation.containsKey (strCode12))
  1534.             return _mapGovvieGovvieCorrelation.get (strCode12);

  1535.         java.lang.String strCode21 = govvieLabel2.fullyQualifiedName() + "@#" +
  1536.             govvieLabel1.fullyQualifiedName();

  1537.         return _mapGovvieGovvieCorrelation.containsKey (strCode21) ?
  1538.             _mapGovvieGovvieCorrelation.get (strCode21) : null;
  1539.     }

  1540.     /**
  1541.      * (Re)-set the Correlation Surface for the Govvie Latent State Pair
  1542.      *
  1543.      * @param govvieLabel1 The Govvie Curve Latent State Label #1
  1544.      * @param govvieLabel2 The Govvie Curve Latent State Label #2
  1545.      * @param auCorrelation The Correlation Surface
  1546.      *
  1547.      * @return TRUE - Successfully set
  1548.      */

  1549.     public boolean setGovvieGovvieCorrelation (
  1550.         final org.drip.state.identifier.GovvieLabel govvieLabel1,
  1551.         final org.drip.state.identifier.GovvieLabel govvieLabel2,
  1552.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1553.     {
  1554.         if (null == govvieLabel1 || null == govvieLabel2 || govvieLabel1.match (govvieLabel2) || null ==
  1555.             auCorrelation)
  1556.             return false;

  1557.         java.lang.String strGovvieLabel1 = govvieLabel1.fullyQualifiedName();

  1558.         java.lang.String strGovvieLabel2 = govvieLabel2.fullyQualifiedName();

  1559.         _mapGovvieGovvieCorrelation.put (strGovvieLabel1 + "@#" + strGovvieLabel2, auCorrelation);

  1560.         _mapGovvieGovvieCorrelation.put (strGovvieLabel2 + "@#" + strGovvieLabel1, auCorrelation);

  1561.         return true;
  1562.     }

  1563.     /**
  1564.      * Retrieve the Correlation Surface between the Pair of Overnight Latent States
  1565.      *
  1566.      * @param overnightLabel1 Overnight Latent State Label #1
  1567.      * @param overnightLabel2 Overnight Latent State Label #2
  1568.      *
  1569.      * @return The Correlation Surface between the Pair of Overnight Latent States
  1570.      */

  1571.     public org.drip.function.definition.R1ToR1 overnightOvernightCorrelation (
  1572.         final org.drip.state.identifier.OvernightLabel overnightLabel1,
  1573.         final org.drip.state.identifier.OvernightLabel overnightLabel2)
  1574.     {
  1575.         if (null == overnightLabel1 || null == overnightLabel2 || overnightLabel1.match (overnightLabel2))
  1576.             return null;

  1577.         java.lang.String strCode = overnightLabel1.fullyQualifiedName() + "@#" +
  1578.             overnightLabel2.fullyQualifiedName();

  1579.         return _mapOvernightOvernightCorrelation.containsKey (strCode) ?
  1580.             _mapOvernightOvernightCorrelation.get (strCode) : null;
  1581.     }

  1582.     /**
  1583.      * (Re)-set the Correlation Surface between the Pair of Overnight Latent States
  1584.      *
  1585.      * @param overnightLabel1 Overnight Latent State Label #1
  1586.      * @param overnightLabel2 Overnight Latent State Label #2
  1587.      * @param auCorrelation The Correlation Surface
  1588.      *
  1589.      * @return TRUE - Successfully set
  1590.      */

  1591.     public boolean setOvernightOvernightCorrelation (
  1592.         final org.drip.state.identifier.OvernightLabel overnightLabel1,
  1593.         final org.drip.state.identifier.OvernightLabel overnightLabel2,
  1594.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1595.     {
  1596.         if (null == overnightLabel1 || null == overnightLabel2 || overnightLabel1.match (overnightLabel2) ||
  1597.             null == auCorrelation)
  1598.             return false;

  1599.         java.lang.String strOvernightLabel1 = overnightLabel1.fullyQualifiedName();

  1600.         java.lang.String strOvernightLabel2 = overnightLabel2.fullyQualifiedName();

  1601.         _mapOvernightOvernightCorrelation.put (strOvernightLabel1 + "@#" + strOvernightLabel2,
  1602.             auCorrelation);

  1603.         _mapOvernightOvernightCorrelation.put (strOvernightLabel2 + "@#" + strOvernightLabel1,
  1604.             auCorrelation);

  1605.         return true;
  1606.     }

  1607.     /**
  1608.      * Retrieve the Correlation Surface for the specified Pay-down Latent State Pair
  1609.      *
  1610.      * @param paydownLabel1 The Pay-down Curve Latent State Label #1
  1611.      * @param paydownLabel2 The Pay-down Curve Latent State Label #2
  1612.      *
  1613.      * @return The Correlation Surface for the specified Pay-down Latent State Pair
  1614.      */

  1615.     public org.drip.function.definition.R1ToR1 paydownPaydownCorrelation (
  1616.         final org.drip.state.identifier.PaydownLabel paydownLabel1,
  1617.         final org.drip.state.identifier.PaydownLabel paydownLabel2)
  1618.     {
  1619.         if (null == paydownLabel1 || null == paydownLabel2 || paydownLabel1.match (paydownLabel2))
  1620.             return null;

  1621.         java.lang.String strCode12 = paydownLabel1.fullyQualifiedName() + "@#" +
  1622.             paydownLabel2.fullyQualifiedName();

  1623.         if (_mapPaydownPaydownCorrelation.containsKey (strCode12))
  1624.             return _mapPaydownPaydownCorrelation.get (strCode12);

  1625.         java.lang.String strCode21 = paydownLabel2.fullyQualifiedName() + "@#" +
  1626.             paydownLabel1.fullyQualifiedName();

  1627.         return _mapPaydownPaydownCorrelation.containsKey (strCode21) ?
  1628.             _mapPaydownPaydownCorrelation.get (strCode21) : null;
  1629.     }

  1630.     /**
  1631.      * (Re)-set the Correlation Surface for the Pay-down Latent State Pair
  1632.      *
  1633.      * @param paydownLabel1 The Pay-down Curve Latent State Label #1
  1634.      * @param paydownLabel2 The Pay-down Curve Latent State Label #2
  1635.      * @param auCorrelation The Correlation Surface
  1636.      *
  1637.      * @return TRUE - Successfully set
  1638.      */

  1639.     public boolean setPaydownPaydownCorrelation (
  1640.         final org.drip.state.identifier.PaydownLabel paydownLabel1,
  1641.         final org.drip.state.identifier.PaydownLabel paydownLabel2,
  1642.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1643.     {
  1644.         if (null == paydownLabel1 || null == paydownLabel2 || paydownLabel1.match (paydownLabel2) || null ==
  1645.             auCorrelation)
  1646.             return false;

  1647.         java.lang.String strPaydownLabel1 = paydownLabel1.fullyQualifiedName();

  1648.         java.lang.String strPaydownLabel2 = paydownLabel2.fullyQualifiedName();

  1649.         _mapPaydownPaydownCorrelation.put (strPaydownLabel1 + "@#" + strPaydownLabel2, auCorrelation);

  1650.         _mapPaydownPaydownCorrelation.put (strPaydownLabel2 + "@#" + strPaydownLabel1, auCorrelation);

  1651.         return true;
  1652.     }

  1653.     /**
  1654.      * Retrieve the Correlation Surface for the specified Recovery Latent State Pair
  1655.      *
  1656.      * @param recoveryLabel1 The Recovery Curve Latent State Label #1
  1657.      * @param recoveryLabel2 The Recovery Curve Latent State Label #2
  1658.      *
  1659.      * @return The Correlation Surface for the specified Recovery Latent State Pair
  1660.      */

  1661.     public org.drip.function.definition.R1ToR1 recoveryRecoveryCorrelation (
  1662.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel1,
  1663.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel2)
  1664.     {
  1665.         if (null == recoveryLabel1 || null == recoveryLabel2 || recoveryLabel1.match (recoveryLabel2))
  1666.             return null;

  1667.         java.lang.String strCode12 = recoveryLabel1.fullyQualifiedName() + "@#" +
  1668.             recoveryLabel2.fullyQualifiedName();

  1669.         if (_mapRecoveryRecoveryCorrelation.containsKey (strCode12))
  1670.             return _mapRecoveryRecoveryCorrelation.get (strCode12);

  1671.         java.lang.String strCode21 = recoveryLabel2.fullyQualifiedName() + "@#" +
  1672.             recoveryLabel1.fullyQualifiedName();

  1673.         return _mapRecoveryRecoveryCorrelation.containsKey (strCode21) ?
  1674.             _mapRecoveryRecoveryCorrelation.get (strCode21) : null;
  1675.     }

  1676.     /**
  1677.      * (Re)-set the Correlation Surface for the Recovery Latent State Pair
  1678.      *
  1679.      * @param recoveryLabel1 The Recovery Curve Latent State Label #1
  1680.      * @param recoveryLabel2 The Recovery Curve Latent State Label #2
  1681.      * @param auCorrelation The Correlation Surface
  1682.      *
  1683.      * @return TRUE - Successfully set
  1684.      */

  1685.     public boolean setRecoveryRecoveryCorrelation (
  1686.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel1,
  1687.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel2,
  1688.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1689.     {
  1690.         if (null == recoveryLabel1 || null == recoveryLabel2 || recoveryLabel1.match (recoveryLabel2) || null
  1691.             == auCorrelation)
  1692.             return false;

  1693.         java.lang.String strRecoveryLabel1 = recoveryLabel1.fullyQualifiedName();

  1694.         java.lang.String strRecoveryLabel2 = recoveryLabel2.fullyQualifiedName();

  1695.         _mapRecoveryRecoveryCorrelation.put (strRecoveryLabel1 + "@#" + strRecoveryLabel2,
  1696.             auCorrelation);

  1697.         _mapRecoveryRecoveryCorrelation.put (strRecoveryLabel2 + "@#" + strRecoveryLabel1,
  1698.             auCorrelation);

  1699.         return true;
  1700.     }

  1701.     /**
  1702.      * Retrieve the Correlation Surface between the Pair of Repo Latent States
  1703.      *
  1704.      * @param repoLabel1 Repo Latent State Label #1
  1705.      * @param repoLabel2 Repo Latent State Label #2
  1706.      *
  1707.      * @return The Correlation Surface between the Pair of Repo Latent States
  1708.      */

  1709.     public org.drip.function.definition.R1ToR1 repoRepoCorrelation (
  1710.         final org.drip.state.identifier.RepoLabel repoLabel1,
  1711.         final org.drip.state.identifier.RepoLabel repoLabel2)
  1712.     {
  1713.         if (null == repoLabel1 || null == repoLabel2 || repoLabel1.match (repoLabel2)) return null;

  1714.         java.lang.String strCode = repoLabel1.fullyQualifiedName() + "@#" + repoLabel2.fullyQualifiedName();

  1715.         return _mapRepoRepoCorrelation.containsKey (strCode) ? _mapRepoRepoCorrelation.get
  1716.             (strCode) : null;
  1717.     }

  1718.     /**
  1719.      * (Re)-set the Correlation Surface between the Pair of Repo Latent States
  1720.      *
  1721.      * @param repoLabel1 Repo Latent State Label #1
  1722.      * @param repoLabel2 Repo Latent State Label #2
  1723.      * @param auCorrelation The Correlation Surface
  1724.      *
  1725.      * @return TRUE - Successfully set
  1726.      */

  1727.     public boolean setRepoRepoCorrelation (
  1728.         final org.drip.state.identifier.RepoLabel repoLabel1,
  1729.         final org.drip.state.identifier.RepoLabel repoLabel2,
  1730.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1731.     {
  1732.         if (null == repoLabel1 || null == repoLabel2 || repoLabel1.match (repoLabel2) || null ==
  1733.             auCorrelation)
  1734.             return false;

  1735.         java.lang.String strRepoLabel1 = repoLabel1.fullyQualifiedName();

  1736.         java.lang.String strRepoLabel2 = repoLabel2.fullyQualifiedName();

  1737.         _mapRepoRepoCorrelation.put (strRepoLabel1 + "@#" + strRepoLabel2, auCorrelation);

  1738.         _mapRepoRepoCorrelation.put (strRepoLabel2 + "@#" + strRepoLabel1, auCorrelation);

  1739.         return true;
  1740.     }

  1741.     /**
  1742.      * Retrieve the Correlation Surface between the Collateral and the Credit Latent States
  1743.      *
  1744.      * @param strCollateralCurrency The Collateral Currency
  1745.      * @param creditLabel The Credit Curve Latent State Label
  1746.      *
  1747.      * @return The Correlation Surface between the Collateral and the Credit Latent States
  1748.      */

  1749.     public org.drip.function.definition.R1ToR1 collateralCreditCorrelation (
  1750.         final java.lang.String strCollateralCurrency,
  1751.         final org.drip.state.identifier.EntityCDSLabel creditLabel)
  1752.     {
  1753.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == creditLabel)
  1754.             return null;

  1755.         java.lang.String strCode = strCollateralCurrency + "@#" + creditLabel.fullyQualifiedName();

  1756.         return _mapCollateralCreditCorrelation.containsKey (strCode) ? null :
  1757.             _mapCollateralCreditCorrelation.get (strCode);
  1758.     }

  1759.     /**
  1760.      * (Re)-set the Correlation Surface between the Collateral and the Credit Latent States
  1761.      *
  1762.      * @param strCollateralCurrency The Collateral Currency
  1763.      * @param creditLabel The Credit Curve Latent State Label
  1764.      * @param auCorrelation The Correlation Surface
  1765.      *
  1766.      * @return TRUE - Successfully set
  1767.      */

  1768.     public boolean setCollateralCreditCorrelation (
  1769.         final java.lang.String strCollateralCurrency,
  1770.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  1771.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1772.     {
  1773.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == creditLabel)
  1774.             return false;

  1775.         _mapCollateralCreditCorrelation.put (strCollateralCurrency + "@#" +
  1776.             creditLabel.fullyQualifiedName(), auCorrelation);

  1777.         return true;
  1778.     }

  1779.     /**
  1780.      * Retrieve the Correlation Surface between the Collateral and the Custom Metric Latent States
  1781.      *
  1782.      * @param strCollateralCurrency The Collateral Currency
  1783.      * @param customLabel The Custom Metric Latent State Label
  1784.      *
  1785.      * @return The Correlation Surface between the Collateral and the Custom Metric Latent States
  1786.      */

  1787.     public org.drip.function.definition.R1ToR1 collateralCustomCorrelation (
  1788.         final java.lang.String strCollateralCurrency,
  1789.         final org.drip.state.identifier.CustomLabel customLabel)
  1790.     {
  1791.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == customLabel)
  1792.             return null;

  1793.         java.lang.String strCode = strCollateralCurrency + "@#" + customLabel.fullyQualifiedName();

  1794.         return _mapCollateralCustomCorrelation.containsKey (strCode) ?
  1795.             _mapCollateralCustomCorrelation.get (strCode) : null;
  1796.     }

  1797.     /**
  1798.      * (Re)-set the Correlation Surface between the Collateral and the Custom Metric Latent States
  1799.      *
  1800.      * @param strCollateralCurrency The Collateral Currency
  1801.      * @param customLabel The Custom Metric Latent State Label
  1802.      * @param auCorrelation The Correlation Surface
  1803.      *
  1804.      * @return TRUE - Successfully set
  1805.      */

  1806.     public boolean setCollateralCustomCorrelation (
  1807.         final java.lang.String strCollateralCurrency,
  1808.         final org.drip.state.identifier.CustomLabel customLabel,
  1809.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1810.     {
  1811.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == customLabel)
  1812.             return false;

  1813.         _mapCollateralCustomCorrelation.put (strCollateralCurrency + "@#" +
  1814.             customLabel.fullyQualifiedName(), auCorrelation);

  1815.         return true;
  1816.     }

  1817.     /**
  1818.      * Retrieve the Correlation Surface between the Collateral and the Forward Latent States
  1819.      *
  1820.      * @param strCollateralCurrency The Collateral Currency
  1821.      * @param forwardLabel The Forward Latent State Label
  1822.      *
  1823.      * @return The Correlation Surface between the Collateral and the Forward Latent States
  1824.      */

  1825.     public org.drip.function.definition.R1ToR1 collateralForwardCorrelation (
  1826.         final java.lang.String strCollateralCurrency,
  1827.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  1828.     {
  1829.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == forwardLabel)
  1830.             return null;

  1831.         java.lang.String strCode = strCollateralCurrency + "@#" + forwardLabel.fullyQualifiedName();

  1832.         return _mapCollateralForwardCorrelation.containsKey (strCode) ?
  1833.             _mapCollateralForwardCorrelation.get (strCode) : null;
  1834.     }

  1835.     /**
  1836.      * (Re)-set the Correlation Surface between the Collateral and the Equity Latent States
  1837.      *
  1838.      * @param strCollateralCurrency The Collateral Currency
  1839.      * @param equityLabel The Equity Latent State Label
  1840.      * @param auCorrelation The Correlation Surface
  1841.      *
  1842.      * @return TRUE - Successfully set
  1843.      */

  1844.     public boolean setCollateralEquityCorrelation (
  1845.         final java.lang.String strCollateralCurrency,
  1846.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  1847.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1848.     {
  1849.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == equityLabel || null
  1850.             == auCorrelation)
  1851.             return false;

  1852.         _mapCollateralEquityCorrelation.put (strCollateralCurrency + "@#" +
  1853.             equityLabel.fullyQualifiedName(), auCorrelation);

  1854.         return true;
  1855.     }

  1856.     /**
  1857.      * Retrieve the Correlation Surface between the Collateral and the Equity Latent States
  1858.      *
  1859.      * @param strCollateralCurrency The Collateral Currency
  1860.      * @param equityLabel The Equity Latent State Label
  1861.      *
  1862.      * @return The Correlation Surface between the Collateral and the Equity Latent States
  1863.      */

  1864.     public org.drip.function.definition.R1ToR1 collateralEquityCorrelation (
  1865.         final java.lang.String strCollateralCurrency,
  1866.         final org.drip.state.identifier.EntityEquityLabel equityLabel)
  1867.     {
  1868.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == equityLabel)
  1869.             return null;

  1870.         java.lang.String strCode = strCollateralCurrency + "@#" + equityLabel.fullyQualifiedName();

  1871.         return _mapCollateralEquityCorrelation.containsKey (strCode) ?
  1872.             _mapCollateralEquityCorrelation.get (strCode) : null;
  1873.     }

  1874.     /**
  1875.      * (Re)-set the Correlation Surface between the Collateral and the Forward Latent States
  1876.      *
  1877.      * @param strCollateralCurrency The Collateral Currency
  1878.      * @param forwardLabel The Forward Latent State Label
  1879.      * @param auCorrelation The Correlation Surface
  1880.      *
  1881.      * @return TRUE - Successfully set
  1882.      */

  1883.     public boolean setCollateralForwardCorrelation (
  1884.         final java.lang.String strCollateralCurrency,
  1885.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  1886.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1887.     {
  1888.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == forwardLabel || null
  1889.             == auCorrelation)
  1890.             return false;

  1891.         _mapCollateralForwardCorrelation.put (strCollateralCurrency + "@#" +
  1892.             forwardLabel.fullyQualifiedName(), auCorrelation);

  1893.         return true;
  1894.     }

  1895.     /**
  1896.      * Retrieve the Correlation Surface between the Collateral and the Funding Latent States
  1897.      *
  1898.      * @param strCollateralCurrency The Collateral Currency
  1899.      * @param fundingLabel The Funding Latent State Label
  1900.      *
  1901.      * @return The Correlation Surface between the Collateral and the Funding Latent States
  1902.      */

  1903.     public org.drip.function.definition.R1ToR1 collateralFundingCorrelation (
  1904.         final java.lang.String strCollateralCurrency,
  1905.         final org.drip.state.identifier.FundingLabel fundingLabel)
  1906.     {
  1907.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == fundingLabel)
  1908.             return null;

  1909.         java.lang.String strCode = strCollateralCurrency + "@#" + fundingLabel.fullyQualifiedName();

  1910.         return _mapCollateralFundingCorrelation.containsKey (strCode) ?
  1911.             _mapCollateralFundingCorrelation.get (strCode) : null;
  1912.     }

  1913.     /**
  1914.      * (Re)-set the Correlation Surface between the Collateral and the Funding Latent States
  1915.      *
  1916.      * @param strCollateralCurrency The Collateral Currency
  1917.      * @param fundingLabel The Funding Latent State Label
  1918.      * @param auCorrelation The Correlation Surface
  1919.      *
  1920.      * @return TRUE - Successfully set
  1921.      */

  1922.     public boolean setCollateralFundingCorrelation (
  1923.         final java.lang.String strCollateralCurrency,
  1924.         final org.drip.state.identifier.FundingLabel fundingLabel,
  1925.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1926.     {
  1927.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == fundingLabel || null
  1928.             == auCorrelation)
  1929.             return false;

  1930.         _mapCollateralFundingCorrelation.put (strCollateralCurrency + "@#" +
  1931.             fundingLabel.fullyQualifiedName(), auCorrelation);

  1932.         return true;
  1933.     }

  1934.     /**
  1935.      * Retrieve the Correlation Surface for the specified Collateral and the FX Latent State Label
  1936.      *
  1937.      * @param strCollateralCurrency The Collateral Currency
  1938.      * @param fxLabel The FX Latent State Label
  1939.      *
  1940.      * @return The Correlation Surface for the specified Collateral and the FX Latent State Label
  1941.      */

  1942.     public org.drip.function.definition.R1ToR1 collateralFXCorrelation (
  1943.         final java.lang.String strCollateralCurrency,
  1944.         final org.drip.state.identifier.FXLabel fxLabel)
  1945.     {
  1946.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == fxLabel) return null;

  1947.         java.lang.String strCode = strCollateralCurrency + "@#" + fxLabel.fullyQualifiedName();

  1948.         return _mapCollateralFXCorrelation.containsKey (strCode) ?
  1949.             _mapCollateralFXCorrelation.get (strCode) : null;
  1950.     }

  1951.     /**
  1952.      * (Re)-set the Correlation Surface for the specified Collateral and FX Latent States
  1953.      *
  1954.      * @param strCollateralCurrency The Collateral Currency
  1955.      * @param fxLabel The FX Latent State Label
  1956.      * @param auCorrelation The Correlation Surface
  1957.      *
  1958.      * @return TRUE - Successfully set
  1959.      */

  1960.     public boolean setCollateralFXCorrelation (
  1961.         final java.lang.String strCollateralCurrency,
  1962.         final org.drip.state.identifier.FXLabel fxLabel,
  1963.         final org.drip.function.definition.R1ToR1 auCorrelation)
  1964.     {
  1965.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == fxLabel || null ==
  1966.             auCorrelation)
  1967.             return false;

  1968.         _mapCollateralFXCorrelation.put (strCollateralCurrency + "@#" + fxLabel.fullyQualifiedName(),
  1969.             auCorrelation);

  1970.         return true;
  1971.     }

  1972.     /**
  1973.      * Retrieve the Correlation Surface for the specified Collateral and Govvie Latent State Labels
  1974.      *
  1975.      * @param strCollateralCurrency The Collateral Currency
  1976.      * @param govvieLabel The Govvie Latent State Label
  1977.      *
  1978.      * @return The Correlation Surface for the specified Collateral and Govvie Latent State Labels
  1979.      */

  1980.     public org.drip.function.definition.R1ToR1 collateralGovvieCorrelation (
  1981.         final java.lang.String strCollateralCurrency,
  1982.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  1983.     {
  1984.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == govvieLabel)
  1985.             return null;

  1986.         java.lang.String strCode = strCollateralCurrency + "@#" + govvieLabel.fullyQualifiedName();

  1987.         return _mapCollateralGovvieCorrelation.containsKey (strCode) ?
  1988.             _mapCollateralGovvieCorrelation.get (strCode) : null;
  1989.     }

  1990.     /**
  1991.      * (Re)-set the Correlation Surface for the specified Collateral and Govvie Latent State Labels
  1992.      *
  1993.      * @param strCollateralCurrency The Collateral Currency
  1994.      * @param govvieLabel The Govvie Latent State Label
  1995.      * @param auCorrelation The Correlation Surface
  1996.      *
  1997.      * @return TRUE - Successfully set
  1998.      */

  1999.     public boolean setCollateralGovvieCorrelation (
  2000.         final java.lang.String strCollateralCurrency,
  2001.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  2002.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2003.     {
  2004.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == govvieLabel || null
  2005.             == auCorrelation)
  2006.             return false;

  2007.         _mapCollateralGovvieCorrelation.put (strCollateralCurrency + "@#" +
  2008.             govvieLabel.fullyQualifiedName(), auCorrelation);

  2009.         return true;
  2010.     }

  2011.     /**
  2012.      * Retrieve the Correlation Surface between the Collateral and the Overnight Latent States
  2013.      *
  2014.      * @param strCollateralCurrency The Collateral Currency
  2015.      * @param overnightLabel The Overnight Latent State Label
  2016.      *
  2017.      * @return The Correlation Surface between the Collateral and the Overnight Latent States
  2018.      */

  2019.     public org.drip.function.definition.R1ToR1 collateralOvernightCorrelation (
  2020.         final java.lang.String strCollateralCurrency,
  2021.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  2022.     {
  2023.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == overnightLabel)
  2024.             return null;

  2025.         java.lang.String strCode = strCollateralCurrency + "@#" + overnightLabel.fullyQualifiedName();

  2026.         return _mapCollateralOvernightCorrelation.containsKey (strCode) ?
  2027.             _mapCollateralOvernightCorrelation.get (strCode) : null;
  2028.     }

  2029.     /**
  2030.      * (Re)-set the Correlation Surface between the Collateral and the Overnight Latent States
  2031.      *
  2032.      * @param strCollateralCurrency The Collateral Currency
  2033.      * @param overnightLabel The Overnight Latent State Label
  2034.      * @param auCorrelation The Correlation Surface
  2035.      *
  2036.      * @return TRUE - Successfully set
  2037.      */

  2038.     public boolean setCollateralOvernightCorrelation (
  2039.         final java.lang.String strCollateralCurrency,
  2040.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  2041.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2042.     {
  2043.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == overnightLabel ||
  2044.             null == auCorrelation)
  2045.             return false;

  2046.         _mapCollateralOvernightCorrelation.put (strCollateralCurrency + "@#" +
  2047.             overnightLabel.fullyQualifiedName(), auCorrelation);

  2048.         return true;
  2049.     }

  2050.     /**
  2051.      * Retrieve the Correlation Surface for the specified Collateral and Pay-down Latent State Labels
  2052.      *
  2053.      * @param strCollateralCurrency The Collateral Currency
  2054.      * @param paydownLabel The Pay-down Latent State Label
  2055.      *
  2056.      * @return The Correlation Surface for the specified Collateral and Pay-down Latent State Labels
  2057.      */

  2058.     public org.drip.function.definition.R1ToR1 collateralPaydownCorrelation (
  2059.         final java.lang.String strCollateralCurrency,
  2060.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  2061.     {
  2062.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == paydownLabel)
  2063.             return null;

  2064.         java.lang.String strCode = strCollateralCurrency + "@#" + paydownLabel.fullyQualifiedName();

  2065.         return _mapCollateralPaydownCorrelation.containsKey (strCode) ?
  2066.             _mapCollateralPaydownCorrelation.get (strCode) : null;
  2067.     }

  2068.     /**
  2069.      * (Re)-set the Correlation Surface for the specified Collateral and Pay-down Latent State Labels
  2070.      *
  2071.      * @param strCollateralCurrency The Collateral Currency
  2072.      * @param paydownLabel The Pay-down Latent State Label
  2073.      * @param auCorrelation The Correlation Surface
  2074.      *
  2075.      * @return TRUE - Successfully set
  2076.      */

  2077.     public boolean setCollateralPaydownCorrelation (
  2078.         final java.lang.String strCollateralCurrency,
  2079.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  2080.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2081.     {
  2082.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == paydownLabel || null
  2083.             == auCorrelation)
  2084.             return false;

  2085.         _mapCollateralPaydownCorrelation.put (strCollateralCurrency + "@#" +
  2086.             paydownLabel.fullyQualifiedName(), auCorrelation);

  2087.         return true;
  2088.     }

  2089.     /**
  2090.      * Retrieve the Correlation Surface for the specified Collateral and Rating Latent State Labels
  2091.      *
  2092.      * @param strCollateralCurrency The Collateral Currency
  2093.      * @param ratingLabel The Rating Latent State Label
  2094.      *
  2095.      * @return The Correlation Surface for the specified Collateral and Rating Latent State Labels
  2096.      */

  2097.     public org.drip.function.definition.R1ToR1 collateralRatingCorrelation (
  2098.         final java.lang.String strCollateralCurrency,
  2099.         final org.drip.state.identifier.RatingLabel ratingLabel)
  2100.     {
  2101.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == ratingLabel)
  2102.             return null;

  2103.         java.lang.String strCode = strCollateralCurrency + "@#" + ratingLabel.fullyQualifiedName();

  2104.         return _mapCollateralRatingCorrelation.containsKey (strCode) ?
  2105.             _mapCollateralRatingCorrelation.get (strCode) : null;
  2106.     }

  2107.     /**
  2108.      * (Re)-set the Correlation Surface for the specified Collateral and Rating Latent State Labels
  2109.      *
  2110.      * @param strCollateralCurrency The Collateral Currency
  2111.      * @param ratingLabel The Rating Latent State Label
  2112.      * @param auCorrelation The Correlation Surface
  2113.      *
  2114.      * @return TRUE - Successfully set
  2115.      */

  2116.     public boolean setCollateralRatingCorrelation (
  2117.         final java.lang.String strCollateralCurrency,
  2118.         final org.drip.state.identifier.RatingLabel ratingLabel,
  2119.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2120.     {
  2121.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == ratingLabel || null
  2122.             == auCorrelation)
  2123.             return false;

  2124.         _mapCollateralRatingCorrelation.put (strCollateralCurrency + "@#" +
  2125.             ratingLabel.fullyQualifiedName(), auCorrelation);

  2126.         return true;
  2127.     }

  2128.     /**
  2129.      * Retrieve the Correlation Surface for the specified Collateral and Recovery Latent State Labels
  2130.      *
  2131.      * @param strCollateralCurrency The Collateral Currency
  2132.      * @param recoveryLabel The Recovery Latent State Label
  2133.      *
  2134.      * @return The Correlation Surface for the specified Collateral and Recovery Latent State Labels
  2135.      */

  2136.     public org.drip.function.definition.R1ToR1 collateralRecoveryCorrelation (
  2137.         final java.lang.String strCollateralCurrency,
  2138.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  2139.     {
  2140.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == recoveryLabel)
  2141.             return null;

  2142.         java.lang.String strCode = strCollateralCurrency + "@#" + recoveryLabel.fullyQualifiedName();

  2143.         return _mapCollateralRecoveryCorrelation.containsKey (strCode) ?
  2144.             _mapCollateralRecoveryCorrelation.get (strCode) : null;
  2145.     }

  2146.     /**
  2147.      * (Re)-set the Correlation Surface for the specified Collateral and Recovery Latent State Labels
  2148.      *
  2149.      * @param strCollateralCurrency The Collateral Currency
  2150.      * @param recoveryLabel The Recovery Latent State Label
  2151.      * @param auCorrelation The Correlation Surface
  2152.      *
  2153.      * @return TRUE - Successfully set
  2154.      */

  2155.     public boolean setCollateralRecoveryCorrelation (
  2156.         final java.lang.String strCollateralCurrency,
  2157.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  2158.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2159.     {
  2160.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == recoveryLabel || null
  2161.             == auCorrelation)
  2162.             return false;

  2163.         _mapCollateralRecoveryCorrelation.put (strCollateralCurrency + "@#" +
  2164.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  2165.         return true;
  2166.     }

  2167.     /**
  2168.      * Retrieve the Correlation Surface for the specified Collateral and Repo Latent State Labels
  2169.      *
  2170.      * @param strCollateralCurrency The Collateral Currency
  2171.      * @param repoLabel The Repo Latent State Label
  2172.      *
  2173.      * @return The Correlation Surface for the specified Collateral and Repo Latent State Labels
  2174.      */

  2175.     public org.drip.function.definition.R1ToR1 collateralRepoCorrelation (
  2176.         final java.lang.String strCollateralCurrency,
  2177.         final org.drip.state.identifier.RepoLabel repoLabel)
  2178.     {
  2179.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == repoLabel)
  2180.             return null;

  2181.         java.lang.String strCode = strCollateralCurrency + "@#" + repoLabel.fullyQualifiedName();

  2182.         return _mapCollateralRepoCorrelation.containsKey (strCode) ?
  2183.             _mapCollateralRepoCorrelation.get (strCode) : null;
  2184.     }

  2185.     /**
  2186.      * (Re)-set the Correlation Surface for the specified Collateral and Repo Latent State Labels
  2187.      *
  2188.      * @param strCollateralCurrency The Collateral Currency
  2189.      * @param repoLabel The Repo Latent State Label
  2190.      * @param auCorrelation The Correlation Surface
  2191.      *
  2192.      * @return TRUE - Successfully set
  2193.      */

  2194.     public boolean setCollateralRepoCorrelation (
  2195.         final java.lang.String strCollateralCurrency,
  2196.         final org.drip.state.identifier.RepoLabel repoLabel,
  2197.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2198.     {
  2199.         if (null == strCollateralCurrency || strCollateralCurrency.isEmpty() || null == repoLabel || null ==
  2200.             auCorrelation)
  2201.             return false;

  2202.         _mapCollateralRepoCorrelation.put (strCollateralCurrency + "@#" +
  2203.             repoLabel.fullyQualifiedName(), auCorrelation);

  2204.         return true;
  2205.     }

  2206.     /**
  2207.      * Retrieve the Correlation Surface between the Credit and the Custom Metric Latent States
  2208.      *
  2209.      * @param creditLabel The Credit Latent State Label
  2210.      * @param customLabel The Custom Metric Latent State Label
  2211.      *
  2212.      * @return The Correlation Surface between the Credit and the Custom Metric Latent States
  2213.      */

  2214.     public org.drip.function.definition.R1ToR1 creditCustomMetricCorrelation (
  2215.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2216.         final org.drip.state.identifier.CustomLabel customLabel)
  2217.     {
  2218.         if (null == creditLabel || null == customLabel) return null;

  2219.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2220.             customLabel.fullyQualifiedName();

  2221.         return _mapCreditCustomCorrelation.containsKey (strCode) ?
  2222.             _mapCreditCustomCorrelation.get (strCode) : null;
  2223.     }

  2224.     /**
  2225.      * (Re)-set the Correlation Surface between the Credit and the Custom Metric Latent States
  2226.      *
  2227.      * @param creditLabel The Credit Latent State Label
  2228.      * @param customLabel The Custom Metric Latent State Label
  2229.      * @param auCorrelation The Correlation Surface
  2230.      *
  2231.      * @return TRUE - Successfully set
  2232.      */

  2233.     public boolean setCreditCustomCorrelation (
  2234.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2235.         final org.drip.state.identifier.CustomLabel customLabel,
  2236.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2237.     {
  2238.         if (null == creditLabel || null == customLabel || null == auCorrelation) return false;

  2239.         _mapCreditCustomCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2240.             customLabel.fullyQualifiedName(), auCorrelation);

  2241.         return true;
  2242.     }

  2243.     /**
  2244.      * Retrieve the Correlation Surface between the Credit and the Equity Latent States
  2245.      *
  2246.      * @param creditLabel The Credit Curve Label
  2247.      * @param equityLabel The Equity Latent State Label
  2248.      *
  2249.      * @return The Correlation Surface between the Credit and the Equity Latent States
  2250.      */

  2251.     public org.drip.function.definition.R1ToR1 creditEquityCorrelation (
  2252.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2253.         final org.drip.state.identifier.EntityEquityLabel equityLabel)
  2254.     {
  2255.         if (null == creditLabel || null == equityLabel) return null;

  2256.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2257.             equityLabel.fullyQualifiedName();

  2258.         return _mapCreditEquityCorrelation.containsKey (strCode) ?
  2259.             _mapCreditEquityCorrelation.get (strCode) : null;
  2260.     }

  2261.     /**
  2262.      * (Re)-set the Correlation Surface between the Credit and the Equity Latent States
  2263.      *
  2264.      * @param creditLabel The Credit Curve Label
  2265.      * @param equityLabel The Equity Latent State Label
  2266.      * @param auCorrelation The Correlation Surface
  2267.      *
  2268.      * @return TRUE - Successfully set
  2269.      */

  2270.     public boolean setCreditEquityCorrelation (
  2271.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2272.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  2273.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2274.     {
  2275.         if (null == creditLabel || null == equityLabel || null == auCorrelation) return false;

  2276.         _mapCreditEquityCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2277.             equityLabel.fullyQualifiedName(), auCorrelation);

  2278.         return true;
  2279.     }

  2280.     /**
  2281.      * Retrieve the Correlation Surface between the Credit and the Forward Latent States
  2282.      *
  2283.      * @param creditLabel The Credit Curve Label
  2284.      * @param forwardLabel The Forward Latent State Label
  2285.      *
  2286.      * @return The Correlation Surface between the Credit and the Forward Latent States
  2287.      */

  2288.     public org.drip.function.definition.R1ToR1 creditForwardCorrelation (
  2289.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2290.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  2291.     {
  2292.         if (null == creditLabel || null == forwardLabel) return null;

  2293.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2294.             forwardLabel.fullyQualifiedName();

  2295.         return _mapCreditForwardCorrelation.containsKey (strCode) ?
  2296.             _mapCreditForwardCorrelation.get (strCode) : null;
  2297.     }

  2298.     /**
  2299.      * (Re)-set the Correlation Surface between the Credit and the Forward Latent States
  2300.      *
  2301.      * @param creditLabel The Credit Curve Label
  2302.      * @param forwardLabel The Forward Latent State Label
  2303.      * @param auCorrelation The Correlation Surface
  2304.      *
  2305.      * @return TRUE - Successfully set
  2306.      */

  2307.     public boolean setCreditForwardCorrelation (
  2308.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2309.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  2310.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2311.     {
  2312.         if (null == creditLabel || null == forwardLabel || null == auCorrelation) return false;

  2313.         _mapCreditForwardCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2314.             forwardLabel.fullyQualifiedName(), auCorrelation);

  2315.         return true;
  2316.     }

  2317.     /**
  2318.      * Retrieve the Correlation Surface between the Credit and the Funding Latent States
  2319.      *
  2320.      * @param creditLabel The Credit Curve Latent State Label
  2321.      * @param fundingLabel The Funding Latent State Label
  2322.      *
  2323.      * @return The Correlation Surface between the Credit and the Funding Latent States
  2324.      */

  2325.     public org.drip.function.definition.R1ToR1 creditFundingCorrelation (
  2326.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2327.         final org.drip.state.identifier.FundingLabel fundingLabel)
  2328.     {
  2329.         if (null == creditLabel || null == fundingLabel) return null;

  2330.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2331.             fundingLabel.fullyQualifiedName();

  2332.         return _mapCreditFundingCorrelation.containsKey (strCode) ?
  2333.             _mapCreditFundingCorrelation.get (strCode) : null;
  2334.     }

  2335.     /**
  2336.      * (Re)-set the Correlation Surface between the Credit and the Funding Latent States
  2337.      *
  2338.      * @param creditLabel The Credit Curve Label
  2339.      * @param fundingLabel The Funding Latent State Label
  2340.      * @param auCorrelation The Correlation Surface
  2341.      *
  2342.      * @return TRUE - Successfully set
  2343.      */

  2344.     public boolean setCreditFundingCorrelation (
  2345.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2346.         final org.drip.state.identifier.FundingLabel fundingLabel,
  2347.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2348.     {
  2349.         if (null == creditLabel || null == fundingLabel || null == auCorrelation) return false;

  2350.         _mapCreditFundingCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2351.             fundingLabel.fullyQualifiedName(), auCorrelation);

  2352.         return true;
  2353.     }

  2354.     /**
  2355.      * Retrieve the Correlation Surface between the Credit and the FX Latent State Labels
  2356.      *
  2357.      * @param creditLabel The Credit Curve Label
  2358.      * @param fxLabel The FX Latent State Label
  2359.      *
  2360.      * @return The Correlation Surface between the Credit and the FX Latent State Labels
  2361.      */

  2362.     public org.drip.function.definition.R1ToR1 creditFXCorrelation (
  2363.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2364.         final org.drip.state.identifier.FXLabel fxLabel)
  2365.     {
  2366.         if (null == creditLabel || null == fxLabel) return null;

  2367.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" + fxLabel.fullyQualifiedName();

  2368.         return _mapCreditFXCorrelation.containsKey (strCode) ? _mapCreditFXCorrelation.get
  2369.             (strCode) : null;
  2370.     }

  2371.     /**
  2372.      * (Re)-set the Correlation Surface between the Credit and the FX Latent States
  2373.      *
  2374.      * @param creditLabel The Credit Curve Label
  2375.      * @param fxLabel The FX Latent State Label
  2376.      * @param auCorrelation The Correlation Surface
  2377.      *
  2378.      * @return TRUE - Successfully set
  2379.      */

  2380.     public boolean setCreditFXCorrelation (
  2381.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2382.         final org.drip.state.identifier.FXLabel fxLabel,
  2383.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2384.     {
  2385.         if (null == creditLabel || null == fxLabel || null == auCorrelation) return false;

  2386.         _mapCreditFXCorrelation.get (creditLabel.fullyQualifiedName() + "@#" +
  2387.             fxLabel.fullyQualifiedName());

  2388.         return true;
  2389.     }

  2390.     /**
  2391.      * Retrieve the Correlation Surface between the Credit and the Govvie Latent State Labels
  2392.      *
  2393.      * @param creditLabel The Credit Curve Label
  2394.      * @param govvieLabel The Govvie Latent State Label
  2395.      *
  2396.      * @return The Correlation Surface between the Credit and the Govvie Latent State Labels
  2397.      */

  2398.     public org.drip.function.definition.R1ToR1 creditGovvieCorrelation (
  2399.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2400.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  2401.     {
  2402.         if (null == creditLabel || null == govvieLabel) return null;

  2403.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2404.             govvieLabel.fullyQualifiedName();

  2405.         return _mapCreditGovvieCorrelation.containsKey (strCode) ?
  2406.             _mapCreditGovvieCorrelation.get (strCode) : null;
  2407.     }

  2408.     /**
  2409.      * (Re)-set the Correlation Surface between the Credit and the Govvie Latent States
  2410.      *
  2411.      * @param creditLabel The Credit Curve Latent State Label
  2412.      * @param govvieLabel The Govvie Latent State Label
  2413.      * @param auCorrelation The Correlation Surface
  2414.      *
  2415.      * @return TRUE - Successfully set
  2416.      */

  2417.     public boolean setCreditGovvieCorrelation (
  2418.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2419.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  2420.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2421.     {
  2422.         if (null == creditLabel || null == govvieLabel || null == auCorrelation) return false;

  2423.         _mapCreditGovvieCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2424.             govvieLabel.fullyQualifiedName(), auCorrelation);

  2425.         return true;
  2426.     }

  2427.     /**
  2428.      * Retrieve the Correlation Surface between the Credit and the Overnight Latent States
  2429.      *
  2430.      * @param creditLabel The Credit Curve Latent State Label
  2431.      * @param overnightLabel The Overnight Latent State Label
  2432.      *
  2433.      * @return The Correlation Surface between the Credit and the Overnight Latent States
  2434.      */

  2435.     public org.drip.function.definition.R1ToR1 creditOvernightCorrelation (
  2436.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2437.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  2438.     {
  2439.         if (null == creditLabel || null == overnightLabel) return null;

  2440.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2441.             overnightLabel.fullyQualifiedName();

  2442.         return _mapCreditOvernightCorrelation.containsKey (strCode) ?
  2443.             _mapCreditOvernightCorrelation.get (strCode) : null;
  2444.     }

  2445.     /**
  2446.      * (Re)-set the Correlation Surface between the Credit and the Overnight Latent States
  2447.      *
  2448.      * @param creditLabel The Credit Curve Label
  2449.      * @param overnightLabel The Overnight Latent State Label
  2450.      * @param auCorrelation The Correlation Surface
  2451.      *
  2452.      * @return TRUE - Successfully set
  2453.      */

  2454.     public boolean setCreditOvernightCorrelation (
  2455.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2456.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  2457.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2458.     {
  2459.         if (null == creditLabel || null == overnightLabel || null == auCorrelation) return false;

  2460.         _mapCreditOvernightCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2461.             overnightLabel.fullyQualifiedName(), auCorrelation);

  2462.         return true;
  2463.     }

  2464.     /**
  2465.      * Retrieve the Correlation Surface between the Credit and the Pay-down Latent State Labels
  2466.      *
  2467.      * @param creditLabel The Credit Curve Label
  2468.      * @param paydownLabel The Pay-down Latent State Label
  2469.      *
  2470.      * @return The Correlation Surface between the Credit and the Pay-down Latent State Labels
  2471.      */

  2472.     public org.drip.function.definition.R1ToR1 creditPaydownCorrelation (
  2473.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2474.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  2475.     {
  2476.         if (null == creditLabel || null == paydownLabel) return null;

  2477.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2478.             paydownLabel.fullyQualifiedName();

  2479.         return _mapCreditPaydownCorrelation.containsKey (strCode) ?
  2480.             _mapCreditPaydownCorrelation.get (strCode) : null;
  2481.     }

  2482.     /**
  2483.      * (Re)-set the Correlation Surface between the Credit and the Pay-down Latent States
  2484.      *
  2485.      * @param creditLabel The Credit Curve Latent State Label
  2486.      * @param paydownLabel The Pay-down Latent State Label
  2487.      * @param auCorrelation The Correlation Surface
  2488.      *
  2489.      * @return TRUE - Successfully set
  2490.      */

  2491.     public boolean setCreditPaydownCorrelation (
  2492.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2493.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  2494.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2495.     {
  2496.         if (null == creditLabel || null == paydownLabel || null == auCorrelation) return false;

  2497.         _mapCreditPaydownCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2498.             paydownLabel.fullyQualifiedName(), auCorrelation);

  2499.         return true;
  2500.     }

  2501.     /**
  2502.      * Retrieve the Correlation Surface between the Credit and the Rating Latent State Labels
  2503.      *
  2504.      * @param creditLabel The Credit Curve Label
  2505.      * @param ratingLabel The Rating Latent State Label
  2506.      *
  2507.      * @return The Correlation Surface between the Credit and the Rating Latent State Labels
  2508.      */

  2509.     public org.drip.function.definition.R1ToR1 creditRatingCorrelation (
  2510.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2511.         final org.drip.state.identifier.RatingLabel ratingLabel)
  2512.     {
  2513.         if (null == creditLabel || null == ratingLabel) return null;

  2514.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2515.             ratingLabel.fullyQualifiedName();

  2516.         return _mapCreditRatingCorrelation.containsKey (strCode) ?
  2517.             _mapCreditRatingCorrelation.get (strCode) : null;
  2518.     }

  2519.     /**
  2520.      * (Re)-set the Correlation Surface between the Credit and the Rating Latent States
  2521.      *
  2522.      * @param creditLabel The Credit Curve Latent State Label
  2523.      * @param ratingLabel The Rating Latent State Label
  2524.      * @param auCorrelation The Correlation Surface
  2525.      *
  2526.      * @return TRUE - Successfully set
  2527.      */

  2528.     public boolean setCreditRatingCorrelation (
  2529.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2530.         final org.drip.state.identifier.RatingLabel ratingLabel,
  2531.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2532.     {
  2533.         if (null == creditLabel || null == ratingLabel || null == auCorrelation) return false;

  2534.         _mapCreditRatingCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2535.             ratingLabel.fullyQualifiedName(), auCorrelation);

  2536.         return true;
  2537.     }

  2538.     /**
  2539.      * Retrieve the Correlation Surface between the Credit and the Repo Latent State Labels
  2540.      *
  2541.      * @param creditLabel The Credit Curve Label
  2542.      * @param repoLabel The Repo Latent State Label
  2543.      *
  2544.      * @return The Correlation Surface between the Credit and the Repo Latent State Labels
  2545.      */

  2546.     public org.drip.function.definition.R1ToR1 creditRepoCorrelation (
  2547.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2548.         final org.drip.state.identifier.RepoLabel repoLabel)
  2549.     {
  2550.         if (null == creditLabel || null == repoLabel) return null;

  2551.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  2552.         return _mapCreditRepoCorrelation.containsKey (strCode) ? _mapCreditRepoCorrelation.get
  2553.             (strCode) : null;
  2554.     }

  2555.     /**
  2556.      * (Re)-set the Correlation Surface between the Credit and the Repo Latent States
  2557.      *
  2558.      * @param creditLabel The Credit Curve Latent State Label
  2559.      * @param repoLabel The Repo Latent State Label
  2560.      * @param auCorrelation The Correlation Surface
  2561.      *
  2562.      * @return TRUE - Successfully set
  2563.      */

  2564.     public boolean setCreditRepoCorrelation (
  2565.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2566.         final org.drip.state.identifier.RepoLabel repoLabel,
  2567.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2568.     {
  2569.         if (null == creditLabel || null == repoLabel || null == auCorrelation) return false;

  2570.         _mapCreditRepoCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2571.             repoLabel.fullyQualifiedName(), auCorrelation);

  2572.         return true;
  2573.     }

  2574.     /**
  2575.      * Retrieve the Correlation Surface between the Credit and the Recovery Latent State Labels
  2576.      *
  2577.      * @param creditLabel The Credit Curve Label
  2578.      * @param recoveryLabel The Recovery Latent State Label
  2579.      *
  2580.      * @return The Correlation Surface between the Credit and the Recovery Latent State Labels
  2581.      */

  2582.     public org.drip.function.definition.R1ToR1 creditRecoveryCorrelation (
  2583.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2584.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  2585.     {
  2586.         if (null == creditLabel || null == recoveryLabel) return null;

  2587.         java.lang.String strCode = creditLabel.fullyQualifiedName() + "@#" +
  2588.             recoveryLabel.fullyQualifiedName();

  2589.         return _mapCreditRecoveryCorrelation.containsKey (strCode) ?
  2590.             _mapCreditRecoveryCorrelation.get (strCode) : null;
  2591.     }

  2592.     /**
  2593.      * (Re)-set the Correlation Surface between the Credit and the Recovery Latent States
  2594.      *
  2595.      * @param creditLabel The Credit Curve Latent State Label
  2596.      * @param recoveryLabel The Recovery Latent State Label
  2597.      * @param auCorrelation The Correlation Surface
  2598.      *
  2599.      * @return TRUE - Successfully set
  2600.      */

  2601.     public boolean setCreditRecoveryCorrelation (
  2602.         final org.drip.state.identifier.EntityCDSLabel creditLabel,
  2603.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  2604.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2605.     {
  2606.         if (null == creditLabel || null == recoveryLabel || null == auCorrelation) return false;

  2607.         _mapCreditRecoveryCorrelation.put (creditLabel.fullyQualifiedName() + "@#" +
  2608.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  2609.         return true;
  2610.     }

  2611.     /**
  2612.      * Retrieve the Correlation Surface between the Custom Metric and the Equity Latent States
  2613.      *
  2614.      * @param customLabel The Custom Metric Latent State Label
  2615.      * @param equityLabel The Equity Latent State Label
  2616.      *
  2617.      * @return The Correlation Surface between the Custom Metric and the Equity Latent States
  2618.      */

  2619.     public org.drip.function.definition.R1ToR1 customEquityCorrelation (
  2620.         final org.drip.state.identifier.CustomLabel customLabel,
  2621.         final org.drip.state.identifier.EntityEquityLabel equityLabel)
  2622.     {
  2623.         if (null == customLabel || null == equityLabel) return null;

  2624.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2625.             equityLabel.fullyQualifiedName();

  2626.         return _mapCustomEquityCorrelation.containsKey (strCode) ?
  2627.             _mapCustomEquityCorrelation.get (strCode) : null;
  2628.     }

  2629.     /**
  2630.      * (Re)-set the Correlation Surface between the Custom Metric and the Equity Latent States
  2631.      *
  2632.      * @param customLabel The Custom Metric Label
  2633.      * @param equityLabel The Equity Latent State Label
  2634.      * @param auCorrelation The Correlation Surface
  2635.      *
  2636.      * @return TRUE - Successfully set
  2637.      */

  2638.     public boolean setCustomEquityCorrelation (
  2639.         final org.drip.state.identifier.CustomLabel customLabel,
  2640.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  2641.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2642.     {
  2643.         if (null == customLabel || null == equityLabel || null == auCorrelation) return false;

  2644.         _mapCustomEquityCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2645.             equityLabel.fullyQualifiedName(), auCorrelation);

  2646.         return true;
  2647.     }

  2648.     /**
  2649.      * Retrieve the Correlation Surface between the Custom Metric and the Forward Latent States
  2650.      *
  2651.      * @param customLabel The Custom Metric Latent State Label
  2652.      * @param forwardLabel The Forward Latent State Label
  2653.      *
  2654.      * @return The Correlation Surface between the Custom Metric and the Forward Latent States
  2655.      */

  2656.     public org.drip.function.definition.R1ToR1 customForwardCorrelation (
  2657.         final org.drip.state.identifier.CustomLabel customLabel,
  2658.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  2659.     {
  2660.         if (null == customLabel || null == forwardLabel) return null;

  2661.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2662.             forwardLabel.fullyQualifiedName();

  2663.         return _mapCustomForwardCorrelation.containsKey (strCode) ?
  2664.             _mapCustomForwardCorrelation.get (strCode) : null;
  2665.     }

  2666.     /**
  2667.      * (Re)-set the Correlation Surface between the Custom Metric and the Forward Latent States
  2668.      *
  2669.      * @param customLabel The Custom Metric Label
  2670.      * @param forwardLabel The Forward Latent State Label
  2671.      * @param auCorrelation The Correlation Surface
  2672.      *
  2673.      * @return TRUE - Successfully set
  2674.      */

  2675.     public boolean setCustomForwardCorrelation (
  2676.         final org.drip.state.identifier.CustomLabel customLabel,
  2677.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  2678.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2679.     {
  2680.         if (null == customLabel || null == forwardLabel || null == auCorrelation) return false;

  2681.         _mapCustomForwardCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2682.             forwardLabel.fullyQualifiedName(), auCorrelation);

  2683.         return true;
  2684.     }

  2685.     /**
  2686.      * Retrieve the Correlation Surface between Custom Metric and the Funding Latent States
  2687.      *
  2688.      * @param customLabel The Custom Metric Latent State Label
  2689.      * @param fundingLabel The Funding Latent State Label
  2690.      *
  2691.      * @return The Correlation Surface between the Custom Metric and the Funding Latent States
  2692.      */

  2693.     public org.drip.function.definition.R1ToR1 customMetricFundingCorrelation (
  2694.         final org.drip.state.identifier.CustomLabel customLabel,
  2695.         final org.drip.state.identifier.FundingLabel fundingLabel)
  2696.     {
  2697.         if (null == customLabel || null == fundingLabel) return null;

  2698.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2699.             fundingLabel.fullyQualifiedName();

  2700.         return _mapCustomFundingCorrelation.containsKey (strCode) ?
  2701.             _mapCustomFundingCorrelation.get (strCode) : null;
  2702.     }

  2703.     /**
  2704.      * (Re)-set the Correlation Surface between the Custom Metric and the Funding Latent States
  2705.      *
  2706.      * @param customLabel The Custom Metric Latent State Label
  2707.      * @param fundingLabel The Funding Latent State Label
  2708.      * @param auCorrelation The Correlation Surface
  2709.      *
  2710.      * @return TRUE - Successfully set
  2711.      */

  2712.     public boolean setCustomFundingCorrelation (
  2713.         final org.drip.state.identifier.CustomLabel customLabel,
  2714.         final org.drip.state.identifier.FundingLabel fundingLabel,
  2715.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2716.     {
  2717.         if (null == customLabel || null == fundingLabel) return false;

  2718.         _mapCustomFundingCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2719.             fundingLabel.fullyQualifiedName(), auCorrelation);

  2720.         return true;
  2721.     }

  2722.     /**
  2723.      * Retrieve the Correlation Surface between the Custom Metric and the FX Latent States
  2724.      *
  2725.      * @param customLabel The Custom Metric Latent State Label
  2726.      * @param fxLabel The FX Latent State Label
  2727.      *
  2728.      * @return The Correlation Surface between the Custom Metric and the FX Latent States
  2729.      */

  2730.     public org.drip.function.definition.R1ToR1 customFXCorrelation (
  2731.         final org.drip.state.identifier.CustomLabel customLabel,
  2732.         final org.drip.state.identifier.FXLabel fxLabel)
  2733.     {
  2734.         if (null == customLabel || null == fxLabel) return null;

  2735.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" + fxLabel.fullyQualifiedName();

  2736.         return _mapCustomFXCorrelation.containsKey (strCode) ? _mapCustomFXCorrelation.get
  2737.             (strCode) : null;
  2738.     }

  2739.     /**
  2740.      * (Re)-set the Correlation Surface between the Custom Metric and the FX Latent States
  2741.      *
  2742.      * @param customLabel The Custom Metric Latent State Label
  2743.      * @param fxLabel The FX Latent State Label
  2744.      * @param auCorrelation The Correlation Surface
  2745.      *
  2746.      * @return TRUE - Successfully set
  2747.      */

  2748.     public boolean setCustomFXCorrelation (
  2749.         final org.drip.state.identifier.CustomLabel customLabel,
  2750.         final org.drip.state.identifier.FXLabel fxLabel,
  2751.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2752.     {
  2753.         if (null == customLabel || null == fxLabel || null == auCorrelation) return false;

  2754.         _mapCustomFXCorrelation.get (customLabel.fullyQualifiedName() + "@#" +
  2755.             fxLabel.fullyQualifiedName());

  2756.         return true;
  2757.     }

  2758.     /**
  2759.      * Retrieve the Correlation Surface between the Custom Metric and the Govvie Latent States
  2760.      *
  2761.      * @param customLabel The Custom Metric Latent State Label
  2762.      * @param govvieLabel The Govvie Latent State Label
  2763.      *
  2764.      * @return The Correlation Surface between the Custom Metric and the Govvie Latent States
  2765.      */

  2766.     public org.drip.function.definition.R1ToR1 customGovvieCorrelation (
  2767.         final org.drip.state.identifier.CustomLabel customLabel,
  2768.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  2769.     {
  2770.         if (null == customLabel || null == govvieLabel) return null;

  2771.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2772.             govvieLabel.fullyQualifiedName();

  2773.         return _mapCustomGovvieCorrelation.containsKey (strCode) ?
  2774.             _mapCustomGovvieCorrelation.get (strCode) : null;
  2775.     }

  2776.     /**
  2777.      * (Re)-set the Correlation Surface between the Custom Metric and the Govvie Latent States
  2778.      *
  2779.      * @param customLabel The Custom Metric Latent State Label
  2780.      * @param govvieLabel The Govvie Latent State Label
  2781.      * @param auCorrelation The Correlation Surface
  2782.      *
  2783.      * @return TRUE - Successfully set
  2784.      */

  2785.     public boolean setCustomGovvieCorrelation (
  2786.         final org.drip.state.identifier.CustomLabel customLabel,
  2787.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  2788.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2789.     {
  2790.         if (null == customLabel || null == govvieLabel) return false;

  2791.         _mapCustomGovvieCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2792.             govvieLabel.fullyQualifiedName(), auCorrelation);

  2793.         return true;
  2794.     }

  2795.     /**
  2796.      * Retrieve the Correlation Surface between the Custom Metric and the Overnight Latent States
  2797.      *
  2798.      * @param customLabel The Custom Metric Latent State Label
  2799.      * @param overnightLabel The Overnight Latent State Label
  2800.      *
  2801.      * @return The Correlation Surface between the Custom Metric and the Overnight Latent States
  2802.      */

  2803.     public org.drip.function.definition.R1ToR1 customOvernightCorrelation (
  2804.         final org.drip.state.identifier.CustomLabel customLabel,
  2805.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  2806.     {
  2807.         if (null == customLabel || null == overnightLabel) return null;

  2808.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2809.             overnightLabel.fullyQualifiedName();

  2810.         return _mapCustomOvernightCorrelation.containsKey (strCode) ?
  2811.             _mapCustomOvernightCorrelation.get (strCode) : null;
  2812.     }

  2813.     /**
  2814.      * (Re)-set the Correlation Surface between the Custom Metric and the Overnight Latent States
  2815.      *
  2816.      * @param customLabel The Custom Metric Latent State Label
  2817.      * @param overnightLabel The Overnight Latent State Label
  2818.      * @param auCorrelation The Correlation Surface
  2819.      *
  2820.      * @return TRUE - Successfully set
  2821.      */

  2822.     public boolean setCustomOvernightCorrelation (
  2823.         final org.drip.state.identifier.CustomLabel customLabel,
  2824.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  2825.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2826.     {
  2827.         if (null == customLabel || null == overnightLabel) return false;

  2828.         _mapCustomOvernightCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2829.             overnightLabel.fullyQualifiedName(), auCorrelation);

  2830.         return true;
  2831.     }

  2832.     /**
  2833.      * Retrieve the Correlation Surface between the Custom Metric and the Pay-down Latent States
  2834.      *
  2835.      * @param customLabel The Custom Metric Latent State Label
  2836.      * @param paydownLabel The Pay-down Latent State Label
  2837.      *
  2838.      * @return The Correlation Surface between the Custom Metric and the Pay-down Latent States
  2839.      */

  2840.     public org.drip.function.definition.R1ToR1 customPaydownCorrelation (
  2841.         final org.drip.state.identifier.CustomLabel customLabel,
  2842.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  2843.     {
  2844.         if (null == customLabel || null == paydownLabel) return null;

  2845.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2846.             paydownLabel.fullyQualifiedName();

  2847.         return _mapCustomPaydownCorrelation.containsKey (strCode) ?
  2848.             _mapCustomPaydownCorrelation.get (strCode) : null;
  2849.     }

  2850.     /**
  2851.      * (Re)-set the Correlation Surface between the Custom Metric and the Pay-down Latent States
  2852.      *
  2853.      * @param customLabel The Custom Metric Latent State Label
  2854.      * @param paydownLabel The Pay-down Latent State Label
  2855.      * @param auCorrelation The Correlation Surface
  2856.      *
  2857.      * @return TRUE - Successfully set
  2858.      */

  2859.     public boolean setCustomPaydownCorrelation (
  2860.         final org.drip.state.identifier.CustomLabel customLabel,
  2861.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  2862.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2863.     {
  2864.         if (null == customLabel || null == paydownLabel) return false;

  2865.         _mapCustomPaydownCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2866.             paydownLabel.fullyQualifiedName(), auCorrelation);

  2867.         return true;
  2868.     }

  2869.     /**
  2870.      * Retrieve the Correlation Surface between the Custom Metric and the Rating Latent States
  2871.      *
  2872.      * @param customLabel The Custom Metric Latent State Label
  2873.      * @param ratingLabel The Rating Latent State Label
  2874.      *
  2875.      * @return The Correlation Surface between the Custom Metric and the Rating Latent States
  2876.      */

  2877.     public org.drip.function.definition.R1ToR1 customRatingCorrelation (
  2878.         final org.drip.state.identifier.CustomLabel customLabel,
  2879.         final org.drip.state.identifier.RatingLabel ratingLabel)
  2880.     {
  2881.         if (null == customLabel || null == ratingLabel) return null;

  2882.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2883.             ratingLabel.fullyQualifiedName();

  2884.         return _mapCustomRatingCorrelation.containsKey (strCode) ?
  2885.             _mapCustomRatingCorrelation.get (strCode) : null;
  2886.     }

  2887.     /**
  2888.      * (Re)-set the Correlation Surface between the Custom Metric and the Rating Latent States
  2889.      *
  2890.      * @param customLabel The Custom Metric Latent State Label
  2891.      * @param ratingLabel The Rating Latent State Label
  2892.      * @param auCorrelation The Correlation Surface
  2893.      *
  2894.      * @return TRUE - Successfully set
  2895.      */

  2896.     public boolean setCustomRatingCorrelation (
  2897.         final org.drip.state.identifier.CustomLabel customLabel,
  2898.         final org.drip.state.identifier.RatingLabel ratingLabel,
  2899.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2900.     {
  2901.         if (null == customLabel || null == ratingLabel) return false;

  2902.         _mapCustomRatingCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2903.             ratingLabel.fullyQualifiedName(), auCorrelation);

  2904.         return true;
  2905.     }

  2906.     /**
  2907.      * Retrieve the Correlation Surface between the Custom Metric and the Recovery Latent States
  2908.      *
  2909.      * @param customLabel The Custom Metric Latent State Label
  2910.      * @param recoveryLabel The Recovery Latent State Label
  2911.      *
  2912.      * @return The Correlation Surface between the Custom Metric and the Recovery Latent States
  2913.      */

  2914.     public org.drip.function.definition.R1ToR1 customRecoveryCorrelation (
  2915.         final org.drip.state.identifier.CustomLabel customLabel,
  2916.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  2917.     {
  2918.         if (null == customLabel || null == recoveryLabel) return null;

  2919.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" +
  2920.             recoveryLabel.fullyQualifiedName();

  2921.         return _mapCustomRecoveryCorrelation.containsKey (strCode) ?
  2922.             _mapCustomRecoveryCorrelation.get (strCode) : null;
  2923.     }

  2924.     /**
  2925.      * (Re)-set the Correlation Surface between the Custom Metric and the Recovery Latent States
  2926.      *
  2927.      * @param customLabel The Custom Metric Latent State Label
  2928.      * @param recoveryLabel The Recovery Latent State Label
  2929.      * @param auCorrelation The Correlation Surface
  2930.      *
  2931.      * @return TRUE - Successfully set
  2932.      */

  2933.     public boolean setCustomRecoveryCorrelation (
  2934.         final org.drip.state.identifier.CustomLabel customLabel,
  2935.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  2936.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2937.     {
  2938.         if (null == customLabel || null == recoveryLabel) return false;

  2939.         _mapCustomRecoveryCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2940.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  2941.         return true;
  2942.     }

  2943.     /**
  2944.      * Retrieve the Correlation Surface between the Custom Metric and the Repo Latent States
  2945.      *
  2946.      * @param customLabel The Custom Metric Latent State Label
  2947.      * @param repoLabel The Repo Latent State Label
  2948.      *
  2949.      * @return The Correlation Surface between the Custom Metric and the Repo Latent States
  2950.      */

  2951.     public org.drip.function.definition.R1ToR1 customRepoCorrelation (
  2952.         final org.drip.state.identifier.CustomLabel customLabel,
  2953.         final org.drip.state.identifier.RepoLabel repoLabel)
  2954.     {
  2955.         if (null == customLabel || null == repoLabel) return null;

  2956.         java.lang.String strCode = customLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  2957.         return _mapCustomRepoCorrelation.containsKey (strCode) ? _mapCustomRepoCorrelation.get
  2958.             (strCode) : null;
  2959.     }

  2960.     /**
  2961.      * (Re)-set the Correlation Surface between the Custom Metric and the Repo Latent States
  2962.      *
  2963.      * @param customLabel The Custom Metric Latent State Label
  2964.      * @param repoLabel The Repo Latent State Label
  2965.      * @param auCorrelation The Correlation Surface
  2966.      *
  2967.      * @return TRUE - Successfully set
  2968.      */

  2969.     public boolean setCustomRepoCorrelation (
  2970.         final org.drip.state.identifier.CustomLabel customLabel,
  2971.         final org.drip.state.identifier.RepoLabel repoLabel,
  2972.         final org.drip.function.definition.R1ToR1 auCorrelation)
  2973.     {
  2974.         if (null == customLabel || null == repoLabel) return false;

  2975.         _mapCustomRepoCorrelation.put (customLabel.fullyQualifiedName() + "@#" +
  2976.             repoLabel.fullyQualifiedName(), auCorrelation);

  2977.         return true;
  2978.     }

  2979.     /**
  2980.      * Retrieve the Correlation Surface between the Equity and the Forward Latent States
  2981.      *
  2982.      * @param equityLabel The Equity Latent State Label
  2983.      * @param forwardLabel The Forward Latent State Label
  2984.      *
  2985.      * @return The Correlation Surface between the Equity and the Forward Latent States
  2986.      */

  2987.     public org.drip.function.definition.R1ToR1 equityForwardCorrelation (
  2988.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  2989.         final org.drip.state.identifier.ForwardLabel forwardLabel)
  2990.     {
  2991.         if (null == equityLabel || null == forwardLabel) return null;

  2992.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  2993.             forwardLabel.fullyQualifiedName();

  2994.         return _mapEquityForwardCorrelation.containsKey (strCode) ?
  2995.             _mapEquityForwardCorrelation.get (strCode) : null;
  2996.     }

  2997.     /**
  2998.      * (Re)-set the Correlation Surface between the Equity and the Forward Latent States
  2999.      *
  3000.      * @param equityLabel The Equity Label
  3001.      * @param forwardLabel The Forward Latent State Label
  3002.      * @param auCorrelation The Correlation Surface
  3003.      *
  3004.      * @return TRUE - Successfully set
  3005.      */

  3006.     public boolean setEquityForwardCorrelation (
  3007.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3008.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3009.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3010.     {
  3011.         if (null == equityLabel || null == forwardLabel || null == auCorrelation) return false;

  3012.         _mapEquityForwardCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3013.             forwardLabel.fullyQualifiedName(), auCorrelation);

  3014.         return true;
  3015.     }

  3016.     /**
  3017.      * Retrieve the Correlation Surface between Equity and the Funding Latent States
  3018.      *
  3019.      * @param equityLabel The Equity Latent State Label
  3020.      * @param fundingLabel The Funding Latent State Label
  3021.      *
  3022.      * @return The Correlation Surface between the Equity and the Funding Latent States
  3023.      */

  3024.     public org.drip.function.definition.R1ToR1 equityFundingCorrelation (
  3025.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3026.         final org.drip.state.identifier.FundingLabel fundingLabel)
  3027.     {
  3028.         if (null == equityLabel || null == fundingLabel) return null;

  3029.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3030.             fundingLabel.fullyQualifiedName();

  3031.         return _mapEquityFundingCorrelation.containsKey (strCode) ?
  3032.             _mapEquityFundingCorrelation.get (strCode) : null;
  3033.     }

  3034.     /**
  3035.      * (Re)-set the Correlation Surface between the Equity and the Funding Latent States
  3036.      *
  3037.      * @param equityLabel The Equity Latent State Label
  3038.      * @param fundingLabel The Funding Latent State Label
  3039.      * @param auCorrelation The Correlation Surface
  3040.      *
  3041.      * @return TRUE - Successfully set
  3042.      */

  3043.     public boolean setEquityFundingCorrelation (
  3044.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3045.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3046.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3047.     {
  3048.         if (null == equityLabel || null == fundingLabel) return false;

  3049.         _mapEquityFundingCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3050.             fundingLabel.fullyQualifiedName(), auCorrelation);

  3051.         return true;
  3052.     }

  3053.     /**
  3054.      * Retrieve the Correlation Surface between the Equity and the FX Latent States
  3055.      *
  3056.      * @param equityLabel The Equity Latent State Label
  3057.      * @param fxLabel The FX Latent State Label
  3058.      *
  3059.      * @return The Correlation Surface between the Equity and the FX Latent States
  3060.      */

  3061.     public org.drip.function.definition.R1ToR1 equityFXCorrelation (
  3062.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3063.         final org.drip.state.identifier.FXLabel fxLabel)
  3064.     {
  3065.         if (null == equityLabel || null == fxLabel) return null;

  3066.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" + fxLabel.fullyQualifiedName();

  3067.         return _mapEquityFXCorrelation.containsKey (strCode) ? _mapEquityFXCorrelation.get
  3068.             (strCode) : null;
  3069.     }

  3070.     /**
  3071.      * (Re)-set the Correlation Surface between the Equity and the FX Latent States
  3072.      *
  3073.      * @param equityLabel The Equity Latent State Label
  3074.      * @param fxLabel The FX Latent State Label
  3075.      * @param auCorrelation The Correlation Surface
  3076.      *
  3077.      * @return TRUE - Successfully set
  3078.      */

  3079.     public boolean setEquityFXCorrelation (
  3080.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3081.         final org.drip.state.identifier.FXLabel fxLabel,
  3082.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3083.     {
  3084.         if (null == equityLabel || null == fxLabel || null == auCorrelation) return false;

  3085.         _mapEquityFXCorrelation.get (equityLabel.fullyQualifiedName() + "@#" +
  3086.             fxLabel.fullyQualifiedName());

  3087.         return true;
  3088.     }

  3089.     /**
  3090.      * Retrieve the Correlation Surface between the Equity and the Govvie Latent States
  3091.      *
  3092.      * @param equityLabel The Equity Latent State Label
  3093.      * @param govvieLabel The Govvie Latent State Label
  3094.      *
  3095.      * @return The Correlation Surface between the Equity and the Govvie Latent States
  3096.      */

  3097.     public org.drip.function.definition.R1ToR1 equityGovvieCorrelation (
  3098.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3099.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  3100.     {
  3101.         if (null == equityLabel || null == govvieLabel) return null;

  3102.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3103.             govvieLabel.fullyQualifiedName();

  3104.         return _mapEquityGovvieCorrelation.containsKey (strCode) ?
  3105.             _mapEquityGovvieCorrelation.get (strCode) : null;
  3106.     }

  3107.     /**
  3108.      * (Re)-set the Correlation Surface between the Equity and the Govvie Latent States
  3109.      *
  3110.      * @param equityLabel The Equity Latent State Label
  3111.      * @param govvieLabel The Govvie Latent State Label
  3112.      * @param auCorrelation The Correlation Surface
  3113.      *
  3114.      * @return TRUE - Successfully set
  3115.      */

  3116.     public boolean setEquityGovvieCorrelation (
  3117.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3118.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  3119.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3120.     {
  3121.         if (null == equityLabel || null == govvieLabel) return false;

  3122.         _mapEquityGovvieCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3123.             govvieLabel.fullyQualifiedName(), auCorrelation);

  3124.         return true;
  3125.     }

  3126.     /**
  3127.      * Retrieve the Correlation Surface between Equity and the Overnight Latent States
  3128.      *
  3129.      * @param equityLabel The Equity Latent State Label
  3130.      * @param overnightLabel The Overnight Latent State Label
  3131.      *
  3132.      * @return The Correlation Surface between the Equity and the Overnight Latent States
  3133.      */

  3134.     public org.drip.function.definition.R1ToR1 equityOvernightCorrelation (
  3135.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3136.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  3137.     {
  3138.         if (null == equityLabel || null == overnightLabel) return null;

  3139.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3140.             overnightLabel.fullyQualifiedName();

  3141.         return _mapEquityOvernightCorrelation.containsKey (strCode) ?
  3142.             _mapEquityOvernightCorrelation.get (strCode) : null;
  3143.     }

  3144.     /**
  3145.      * (Re)-set the Correlation Surface between the Equity and the Overnight Latent States
  3146.      *
  3147.      * @param equityLabel The Equity Latent State Label
  3148.      * @param overnightLabel The Overnight Latent State Label
  3149.      * @param auCorrelation The Correlation Surface
  3150.      *
  3151.      * @return TRUE - Successfully set
  3152.      */

  3153.     public boolean setEquityOvernightCorrelation (
  3154.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3155.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  3156.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3157.     {
  3158.         if (null == equityLabel || null == overnightLabel) return false;

  3159.         _mapEquityOvernightCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3160.             overnightLabel.fullyQualifiedName(), auCorrelation);

  3161.         return true;
  3162.     }

  3163.     /**
  3164.      * Retrieve the Correlation Surface between the Equity and the Pay-down Latent States
  3165.      *
  3166.      * @param equityLabel The Equity Latent State Label
  3167.      * @param paydownLabel The Pay-down Latent State Label
  3168.      *
  3169.      * @return The Correlation Surface between the Equity and the Pay-down Latent States
  3170.      */

  3171.     public org.drip.function.definition.R1ToR1 equityPaydownCorrelation (
  3172.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3173.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  3174.     {
  3175.         if (null == equityLabel || null == paydownLabel) return null;

  3176.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3177.             paydownLabel.fullyQualifiedName();

  3178.         return _mapEquityPaydownCorrelation.containsKey (strCode) ?
  3179.             _mapEquityPaydownCorrelation.get (strCode) : null;
  3180.     }

  3181.     /**
  3182.      * (Re)-set the Correlation Surface between the Equity and the Pay-down Latent States
  3183.      *
  3184.      * @param equityLabel The Equity Latent State Label
  3185.      * @param paydownLabel The Pay-down Latent State Label
  3186.      * @param auCorrelation The Correlation Surface
  3187.      *
  3188.      * @return TRUE - Successfully set
  3189.      */

  3190.     public boolean setEquityPaydownCorrelation (
  3191.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3192.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  3193.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3194.     {
  3195.         if (null == equityLabel || null == paydownLabel) return false;

  3196.         _mapEquityPaydownCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3197.             paydownLabel.fullyQualifiedName(), auCorrelation);

  3198.         return true;
  3199.     }

  3200.     /**
  3201.      * Retrieve the Correlation Surface between the Equity and the Recovery Latent States
  3202.      *
  3203.      * @param equityLabel The Equity Latent State Label
  3204.      * @param recoveryLabel The Recovery Latent State Label
  3205.      *
  3206.      * @return The Correlation Surface between the Equity and the Recovery Latent States
  3207.      */

  3208.     public org.drip.function.definition.R1ToR1 equityRecoveryCorrelation (
  3209.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3210.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  3211.     {
  3212.         if (null == equityLabel || null == recoveryLabel) return null;

  3213.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3214.             recoveryLabel.fullyQualifiedName();

  3215.         return _mapEquityRecoveryCorrelation.containsKey (strCode) ?
  3216.             _mapEquityRecoveryCorrelation.get (strCode) : null;
  3217.     }

  3218.     /**
  3219.      * (Re)-set the Correlation Surface between the Equity and the Recovery Latent States
  3220.      *
  3221.      * @param equityLabel The Equity Latent State Label
  3222.      * @param recoveryLabel The Recovery Latent State Label
  3223.      * @param auCorrelation The Correlation Surface
  3224.      *
  3225.      * @return TRUE - Successfully set
  3226.      */

  3227.     public boolean setEquityRecoveryCorrelation (
  3228.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3229.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  3230.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3231.     {
  3232.         if (null == equityLabel || null == recoveryLabel) return false;

  3233.         _mapEquityRecoveryCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3234.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  3235.         return true;
  3236.     }

  3237.     /**
  3238.      * Retrieve the Correlation Surface between the Equity and the Rating Latent States
  3239.      *
  3240.      * @param equityLabel The Equity Latent State Label
  3241.      * @param ratingLabel The Rating Latent State Label
  3242.      *
  3243.      * @return The Correlation Surface between the Equity and the Rating Latent States
  3244.      */

  3245.     public org.drip.function.definition.R1ToR1 equityRatingCorrelation (
  3246.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3247.         final org.drip.state.identifier.RatingLabel ratingLabel)
  3248.     {
  3249.         if (null == equityLabel || null == ratingLabel) return null;

  3250.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" +
  3251.             ratingLabel.fullyQualifiedName();

  3252.         return _mapEquityRatingCorrelation.containsKey (strCode) ?
  3253.             _mapEquityRatingCorrelation.get (strCode) : null;
  3254.     }

  3255.     /**
  3256.      * (Re)-set the Correlation Surface between the Equity and the Rating Latent States
  3257.      *
  3258.      * @param equityLabel The Equity Latent State Label
  3259.      * @param ratingLabel The Rating Latent State Label
  3260.      * @param auCorrelation The Correlation Surface
  3261.      *
  3262.      * @return TRUE - Successfully set
  3263.      */

  3264.     public boolean setEquityRatingCorrelation (
  3265.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3266.         final org.drip.state.identifier.RatingLabel ratingLabel,
  3267.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3268.     {
  3269.         if (null == equityLabel || null == ratingLabel) return false;

  3270.         _mapEquityRatingCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3271.             ratingLabel.fullyQualifiedName(), auCorrelation);

  3272.         return true;
  3273.     }

  3274.     /**
  3275.      * Retrieve the Correlation Surface between the Equity and the Repo Latent States
  3276.      *
  3277.      * @param equityLabel The Equity Latent State Label
  3278.      * @param repoLabel The Repo Latent State Label
  3279.      *
  3280.      * @return The Correlation Surface between the Equity and the Repo Latent States
  3281.      */

  3282.     public org.drip.function.definition.R1ToR1 equityRepoCorrelation (
  3283.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3284.         final org.drip.state.identifier.RepoLabel repoLabel)
  3285.     {
  3286.         if (null == equityLabel || null == repoLabel) return null;

  3287.         java.lang.String strCode = equityLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  3288.         return _mapEquityRepoCorrelation.containsKey (strCode) ? _mapEquityRepoCorrelation.get
  3289.             (strCode) : null;
  3290.     }

  3291.     /**
  3292.      * (Re)-set the Correlation Surface between the Equity and the Repo Latent States
  3293.      *
  3294.      * @param equityLabel The Equity Latent State Label
  3295.      * @param repoLabel The Repo Latent State Label
  3296.      * @param auCorrelation The Correlation Surface
  3297.      *
  3298.      * @return TRUE - Successfully set
  3299.      */

  3300.     public boolean setEquityRepoCorrelation (
  3301.         final org.drip.state.identifier.EntityEquityLabel equityLabel,
  3302.         final org.drip.state.identifier.RepoLabel repoLabel,
  3303.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3304.     {
  3305.         if (null == equityLabel || null == repoLabel) return false;

  3306.         _mapEquityRepoCorrelation.put (equityLabel.fullyQualifiedName() + "@#" +
  3307.             repoLabel.fullyQualifiedName(), auCorrelation);

  3308.         return true;
  3309.     }

  3310.     /**
  3311.      * Retrieve the Correlation Surface between the Forward and the Funding Latent States
  3312.      *
  3313.      * @param forwardLabel The Forward Latent State Label
  3314.      * @param fundingLabel The Funding Latent State Label
  3315.      *
  3316.      * @return The Correlation Surface between the Forward and the Funding Latent States
  3317.      */

  3318.     public org.drip.function.definition.R1ToR1 forwardFundingCorrelation (
  3319.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3320.         final org.drip.state.identifier.FundingLabel fundingLabel)
  3321.     {
  3322.         if (null == forwardLabel || null == fundingLabel) return null;

  3323.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3324.             fundingLabel.fullyQualifiedName();

  3325.         return _mapForwardFundingCorrelation.containsKey (strCode) ?
  3326.             _mapForwardFundingCorrelation.get (strCode) : null;
  3327.     }

  3328.     /**
  3329.      * (Re)-set the Correlation Surface between the Forward and the Funding Latent States
  3330.      *
  3331.      * @param forwardLabel The Forward Curve Latent State Label
  3332.      * @param fundingLabel The Funding Latent State Label
  3333.      * @param auCorrelation The Correlation Surface
  3334.      *
  3335.      * @return TRUE - Successfully set
  3336.      */

  3337.     public boolean setForwardFundingCorrelation (
  3338.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3339.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3340.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3341.     {
  3342.         if (null == forwardLabel || null == fundingLabel || null == auCorrelation) return false;

  3343.         _mapForwardFundingCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3344.             fundingLabel.fullyQualifiedName(), auCorrelation);

  3345.         return true;
  3346.     }

  3347.     /**
  3348.      * Retrieve the Correlation Surface between the Forward and the FX Latent State Labels
  3349.      *
  3350.      * @param forwardLabel The Forward Curve Latent State Label
  3351.      * @param fxLabel The FX Latent State Label
  3352.      *
  3353.      * @return The Correlation Surface between the Forward and the FX Latent State Labels
  3354.      */

  3355.     public org.drip.function.definition.R1ToR1 forwardFXCorrelation (
  3356.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3357.         final org.drip.state.identifier.FXLabel fxLabel)
  3358.     {
  3359.         if (null == forwardLabel || null == fxLabel) return null;

  3360.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" + fxLabel.fullyQualifiedName();

  3361.         return _mapForwardFXCorrelation.containsKey (strCode) ? _mapForwardFXCorrelation.get
  3362.             (strCode) : null;
  3363.     }

  3364.     /**
  3365.      * (Re)-set the Correlation Surface between the Forward and the FX Latent State Labels
  3366.      *
  3367.      * @param forwardLabel The Forward Curve Latent State Label
  3368.      * @param fxLabel The FX Latent State Label
  3369.      * @param auCorrelation The Correlation Surface
  3370.      *
  3371.      * @return TRUE - Successfully set
  3372.      */

  3373.     public boolean setForwardFXCorrelation (
  3374.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3375.         final org.drip.state.identifier.FXLabel fxLabel,
  3376.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3377.     {
  3378.         if (null == forwardLabel || null == fxLabel || null == auCorrelation) return false;

  3379.         _mapForwardFXCorrelation.get (forwardLabel.fullyQualifiedName() + "@#" +
  3380.             fxLabel.fullyQualifiedName());

  3381.         return true;
  3382.     }

  3383.     /**
  3384.      * Retrieve the Correlation Surface between the Forward and the Govvie Latent States
  3385.      *
  3386.      * @param forwardLabel The Forward Curve Latent State Label
  3387.      * @param govvieLabel The Govvie Latent State Label
  3388.      *
  3389.      * @return The Correlation Surface between the Forward and the Govvie Latent States
  3390.      */

  3391.     public org.drip.function.definition.R1ToR1 forwardGovvieCorrelation (
  3392.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3393.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  3394.     {
  3395.         if (null == forwardLabel || null == govvieLabel) return null;

  3396.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3397.             govvieLabel.fullyQualifiedName();

  3398.         return _mapForwardGovvieCorrelation.containsKey (strCode) ?
  3399.             _mapForwardGovvieCorrelation.get (strCode) : null;
  3400.     }

  3401.     /**
  3402.      * (Re)-set the Correlation Surface between the Forward and the Govvie Latent States
  3403.      *
  3404.      * @param forwardLabel The Forward Curve Latent State Label
  3405.      * @param govvieLabel The Govvie Latent State Label
  3406.      * @param auCorrelation The Correlation Surface
  3407.      *
  3408.      * @return TRUE - Successfully set
  3409.      */

  3410.     public boolean setForwardGovvieCorrelation (
  3411.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3412.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  3413.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3414.     {
  3415.         if (null == forwardLabel || null == govvieLabel || null == auCorrelation) return false;

  3416.         _mapForwardGovvieCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3417.             govvieLabel.fullyQualifiedName(), auCorrelation);

  3418.         return true;
  3419.     }

  3420.     /**
  3421.      * Retrieve the Correlation Surface between the Forward and the Overnight Latent States
  3422.      *
  3423.      * @param forwardLabel The Forward Latent State Label
  3424.      * @param overnightLabel The Overnight Latent State Label
  3425.      *
  3426.      * @return The Correlation Surface between the Forward and the Overnight Latent States
  3427.      */

  3428.     public org.drip.function.definition.R1ToR1 forwardOvernightCorrelation (
  3429.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3430.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  3431.     {
  3432.         if (null == forwardLabel || null == overnightLabel) return null;

  3433.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3434.             overnightLabel.fullyQualifiedName();

  3435.         return _mapForwardOvernightCorrelation.containsKey (strCode) ?
  3436.             _mapForwardOvernightCorrelation.get (strCode) : null;
  3437.     }

  3438.     /**
  3439.      * (Re)-set the Correlation Surface between the Forward and the Overnight Latent States
  3440.      *
  3441.      * @param forwardLabel The Forward Curve Latent State Label
  3442.      * @param overnightLabel The Overnight Latent State Label
  3443.      * @param auCorrelation The Correlation Surface
  3444.      *
  3445.      * @return TRUE - Successfully set
  3446.      */

  3447.     public boolean setForwardOvernightCorrelation (
  3448.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3449.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  3450.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3451.     {
  3452.         if (null == forwardLabel || null == overnightLabel || null == auCorrelation) return false;

  3453.         _mapForwardOvernightCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3454.             overnightLabel.fullyQualifiedName(), auCorrelation);

  3455.         return true;
  3456.     }

  3457.     /**
  3458.      * Retrieve the Correlation Surface between the Forward and the Pay-down Latent States
  3459.      *
  3460.      * @param forwardLabel The Forward Curve Latent State Label
  3461.      * @param paydownLabel The Pay-down Latent State Label
  3462.      *
  3463.      * @return The Correlation Surface between the Forward and the Pay-down Latent States
  3464.      */

  3465.     public org.drip.function.definition.R1ToR1 forwardPaydownCorrelation (
  3466.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3467.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  3468.     {
  3469.         if (null == forwardLabel || null == paydownLabel) return null;

  3470.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3471.             paydownLabel.fullyQualifiedName();

  3472.         return _mapForwardPaydownCorrelation.containsKey (strCode) ?
  3473.             _mapForwardPaydownCorrelation.get (strCode) : null;
  3474.     }

  3475.     /**
  3476.      * (Re)-set the Correlation Surface between the Forward and the Pay-down Latent States
  3477.      *
  3478.      * @param forwardLabel The Forward Curve Latent State Label
  3479.      * @param paydownLabel The Pay-down Latent State Label
  3480.      * @param auCorrelation The Correlation Surface
  3481.      *
  3482.      * @return TRUE - Successfully set
  3483.      */

  3484.     public boolean setForwardPaydownCorrelation (
  3485.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3486.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  3487.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3488.     {
  3489.         if (null == forwardLabel || null == paydownLabel || null == auCorrelation) return false;

  3490.         _mapForwardPaydownCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3491.             paydownLabel.fullyQualifiedName(), auCorrelation);

  3492.         return true;
  3493.     }

  3494.     /**
  3495.      * Retrieve the Correlation Surface between the Forward and the Rating Latent States
  3496.      *
  3497.      * @param forwardLabel The Forward Curve Latent State Label
  3498.      * @param ratingLabel The Rating Latent State Label
  3499.      *
  3500.      * @return The Correlation Surface between the Forward and the Rating Latent States
  3501.      */

  3502.     public org.drip.function.definition.R1ToR1 forwardRatingCorrelation (
  3503.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3504.         final org.drip.state.identifier.RatingLabel ratingLabel)
  3505.     {
  3506.         if (null == forwardLabel || null == ratingLabel) return null;

  3507.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3508.             ratingLabel.fullyQualifiedName();

  3509.         return _mapForwardRatingCorrelation.containsKey (strCode) ?
  3510.             _mapForwardRatingCorrelation.get (strCode) : null;
  3511.     }

  3512.     /**
  3513.      * (Re)-set the Correlation Surface between the Forward and the Rating Latent States
  3514.      *
  3515.      * @param forwardLabel The Forward Curve Latent State Label
  3516.      * @param ratingLabel The Rating Latent State Label
  3517.      * @param auCorrelation The Correlation Surface
  3518.      *
  3519.      * @return TRUE - Successfully set
  3520.      */

  3521.     public boolean setForwardRatingCorrelation (
  3522.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3523.         final org.drip.state.identifier.RatingLabel ratingLabel,
  3524.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3525.     {
  3526.         if (null == forwardLabel || null == ratingLabel || null == auCorrelation) return false;

  3527.         _mapForwardRatingCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3528.             ratingLabel.fullyQualifiedName(), auCorrelation);

  3529.         return true;
  3530.     }

  3531.     /**
  3532.      * Retrieve the Correlation Surface between the Forward and the Recovery Latent States
  3533.      *
  3534.      * @param forwardLabel The Forward Curve Latent State Label
  3535.      * @param recoveryLabel The Recovery Latent State Label
  3536.      *
  3537.      * @return The Correlation Surface between the Forward and the Recovery Latent States
  3538.      */

  3539.     public org.drip.function.definition.R1ToR1 forwardRecoveryCorrelation (
  3540.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3541.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  3542.     {
  3543.         if (null == forwardLabel || null == recoveryLabel) return null;

  3544.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" +
  3545.             recoveryLabel.fullyQualifiedName();

  3546.         return _mapForwardRecoveryCorrelation.containsKey (strCode) ?
  3547.             _mapForwardRecoveryCorrelation.get (strCode) : null;
  3548.     }

  3549.     /**
  3550.      * (Re)-set the Correlation Surface between the Forward and the Recovery Latent States
  3551.      *
  3552.      * @param forwardLabel The Forward Curve Latent State Label
  3553.      * @param recoveryLabel The Recovery Latent State Label
  3554.      * @param auCorrelation The Correlation Surface
  3555.      *
  3556.      * @return TRUE - Successfully set
  3557.      */

  3558.     public boolean setForwardRecoveryCorrelation (
  3559.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3560.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  3561.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3562.     {
  3563.         if (null == forwardLabel || null == recoveryLabel || null == auCorrelation) return false;

  3564.         _mapForwardRecoveryCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3565.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  3566.         return true;
  3567.     }

  3568.     /**
  3569.      * Retrieve the Correlation Surface between the Forward and the Repo Latent States
  3570.      *
  3571.      * @param forwardLabel The Forward Curve Latent State Label
  3572.      * @param repoLabel The Repo Latent State Label
  3573.      *
  3574.      * @return The Correlation Surface between the Forward and the Repo Latent States
  3575.      */

  3576.     public org.drip.function.definition.R1ToR1 forwardRepoCorrelation (
  3577.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3578.         final org.drip.state.identifier.RepoLabel repoLabel)
  3579.     {
  3580.         if (null == forwardLabel || null == repoLabel) return null;

  3581.         java.lang.String strCode = forwardLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  3582.         return _mapForwardRepoCorrelation.containsKey (strCode) ?
  3583.             _mapForwardRepoCorrelation.get (strCode) : null;
  3584.     }

  3585.     /**
  3586.      * (Re)-set the Correlation Surface between the Forward and the Repo Latent States
  3587.      *
  3588.      * @param forwardLabel The Forward Curve Latent State Label
  3589.      * @param repoLabel The Repo Latent State Label
  3590.      * @param auCorrelation The Correlation Surface
  3591.      *
  3592.      * @return TRUE - Successfully set
  3593.      */

  3594.     public boolean setForwardRepoCorrelation (
  3595.         final org.drip.state.identifier.ForwardLabel forwardLabel,
  3596.         final org.drip.state.identifier.RepoLabel repoLabel,
  3597.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3598.     {
  3599.         if (null == forwardLabel || null == repoLabel || null == auCorrelation) return false;

  3600.         _mapForwardRepoCorrelation.put (forwardLabel.fullyQualifiedName() + "@#" +
  3601.             repoLabel.fullyQualifiedName(), auCorrelation);

  3602.         return true;
  3603.     }

  3604.     /**
  3605.      * Retrieve the Correlation Surface between the Funding and the FX Latent States
  3606.      *
  3607.      * @param fundingLabel The Funding Latent State Label
  3608.      * @param fxLabel The FX Latent State Label
  3609.      *
  3610.      * @return The Correlation Surface between the Funding and the FX Latent States
  3611.      */

  3612.     public org.drip.function.definition.R1ToR1 fundingFXCorrelation (
  3613.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3614.         final org.drip.state.identifier.FXLabel fxLabel)
  3615.     {
  3616.         if (null == fundingLabel || null == fxLabel) return null;

  3617.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" + fxLabel.fullyQualifiedName();

  3618.         return _mapFundingFXCorrelation.containsKey (strCode) ? _mapFundingFXCorrelation.get
  3619.             (strCode) : null;
  3620.     }

  3621.     /**
  3622.      * (Re)-set the Correlation Surface between the Funding and the FX Latent States
  3623.      *
  3624.      * @param fundingLabel The Funding Latent State Label
  3625.      * @param fxLabel The FX Latent State Label
  3626.      * @param auCorrelation The Correlation Surface
  3627.      *
  3628.      * @return TRUE - Successfully set
  3629.      */

  3630.     public boolean setFundingFXCorrelation (
  3631.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3632.         final org.drip.state.identifier.FXLabel fxLabel,
  3633.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3634.     {
  3635.         if (null == fundingLabel || null == fxLabel || null == auCorrelation) return false;

  3636.         _mapFundingFXCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3637.             fxLabel.fullyQualifiedName(), auCorrelation);

  3638.         return true;
  3639.     }

  3640.     /**
  3641.      * Retrieve the Correlation Surface between the Funding and the Govvie Latent States
  3642.      *
  3643.      * @param fundingLabel The Funding Latent State Label
  3644.      * @param govvieLabel The Govvie Latent State Label
  3645.      *
  3646.      * @return The Correlation Surface between the Funding and the Govvie Latent States
  3647.      */

  3648.     public org.drip.function.definition.R1ToR1 fundingGovvieCorrelation (
  3649.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3650.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  3651.     {
  3652.         if (null == fundingLabel || null == govvieLabel) return null;

  3653.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" +
  3654.             govvieLabel.fullyQualifiedName();

  3655.         return _mapFundingGovvieCorrelation.containsKey (strCode) ?
  3656.             _mapFundingGovvieCorrelation.get (strCode) : null;
  3657.     }

  3658.     /**
  3659.      * (Re)-set the Correlation Surface between the Funding and the Govvie Latent States
  3660.      *
  3661.      * @param fundingLabel The Funding Latent State Label
  3662.      * @param govvieLabel The Govvie Latent State Label
  3663.      * @param auCorrelation The Correlation Surface
  3664.      *
  3665.      * @return TRUE - Successfully set
  3666.      */

  3667.     public boolean setFundingGovvieCorrelation (
  3668.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3669.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  3670.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3671.     {
  3672.         if (null == fundingLabel || null == govvieLabel || null == auCorrelation) return false;

  3673.         _mapFundingGovvieCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3674.             govvieLabel.fullyQualifiedName(), auCorrelation);

  3675.         return true;
  3676.     }

  3677.     /**
  3678.      * Retrieve the Correlation Surface between the Funding and the Overnight Latent States
  3679.      *
  3680.      * @param fundingLabel The Funding Latent State Label
  3681.      * @param overnightLabel The Overnight Latent State Label
  3682.      *
  3683.      * @return The Correlation Surface between the Funding and the Overnight Latent States
  3684.      */

  3685.     public org.drip.function.definition.R1ToR1 fundingOvernightCorrelation (
  3686.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3687.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  3688.     {
  3689.         if (null == fundingLabel || null == overnightLabel) return null;

  3690.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" +
  3691.             overnightLabel.fullyQualifiedName();

  3692.         return _mapFundingOvernightCorrelation.containsKey (strCode) ?
  3693.             _mapFundingOvernightCorrelation.get (strCode) : null;
  3694.     }

  3695.     /**
  3696.      * (Re)-set the Correlation Surface between the Funding and the Overnight Latent States
  3697.      *
  3698.      * @param fundingLabel The Funding Latent State Label
  3699.      * @param overnightLabel The Overnight Latent State Label
  3700.      * @param auCorrelation The Correlation Surface
  3701.      *
  3702.      * @return TRUE - Successfully set
  3703.      */

  3704.     public boolean setFundingOvernightCorrelation (
  3705.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3706.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  3707.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3708.     {
  3709.         if (null == fundingLabel || null == overnightLabel || null == auCorrelation) return false;

  3710.         _mapFundingOvernightCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3711.             overnightLabel.fullyQualifiedName(), auCorrelation);

  3712.         return true;
  3713.     }

  3714.     /**
  3715.      * Retrieve the Correlation Surface between the Funding and the Pay-down Latent States
  3716.      *
  3717.      * @param fundingLabel The Funding Latent State Label
  3718.      * @param paydownLabel The Pay-down Latent State Label
  3719.      *
  3720.      * @return The Correlation Surface between the Funding and the Pay-down Latent States
  3721.      */

  3722.     public org.drip.function.definition.R1ToR1 fundingPaydownCorrelation (
  3723.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3724.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  3725.     {
  3726.         if (null == fundingLabel || null == paydownLabel) return null;

  3727.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" +
  3728.             paydownLabel.fullyQualifiedName();

  3729.         return _mapFundingPaydownCorrelation.containsKey (strCode) ?
  3730.             _mapFundingPaydownCorrelation.get (strCode) : null;
  3731.     }

  3732.     /**
  3733.      * (Re)-set the Correlation Surface between the Funding and the Pay-down Latent States
  3734.      *
  3735.      * @param fundingLabel The Funding Latent State Label
  3736.      * @param paydownLabel The Pay-down Latent State Label
  3737.      * @param auCorrelation The Correlation Surface
  3738.      *
  3739.      * @return TRUE - Successfully set
  3740.      */

  3741.     public boolean setFundingPaydownCorrelation (
  3742.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3743.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  3744.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3745.     {
  3746.         if (null == fundingLabel || null == paydownLabel || null == auCorrelation) return false;

  3747.         _mapFundingPaydownCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3748.             paydownLabel.fullyQualifiedName(), auCorrelation);

  3749.         return true;
  3750.     }

  3751.     /**
  3752.      * Retrieve the Correlation Surface between the Funding and the Rating Latent States
  3753.      *
  3754.      * @param fundingLabel The Funding Latent State Label
  3755.      * @param ratingLabel The Rating Latent State Label
  3756.      *
  3757.      * @return The Correlation Surface between the Funding and the Rating Latent States
  3758.      */

  3759.     public org.drip.function.definition.R1ToR1 fundingRatingCorrelation (
  3760.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3761.         final org.drip.state.identifier.RatingLabel ratingLabel)
  3762.     {
  3763.         if (null == fundingLabel || null == ratingLabel) return null;

  3764.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" +
  3765.             ratingLabel.fullyQualifiedName();

  3766.         return _mapFundingRatingCorrelation.containsKey (strCode) ?
  3767.             _mapFundingRatingCorrelation.get (strCode) : null;
  3768.     }

  3769.     /**
  3770.      * (Re)-set the Correlation Surface between the Funding and the Rating Latent States
  3771.      *
  3772.      * @param fundingLabel The Funding Latent State Label
  3773.      * @param ratingLabel The Rating Latent State Label
  3774.      * @param auCorrelation The Correlation Surface
  3775.      *
  3776.      * @return TRUE - Successfully set
  3777.      */

  3778.     public boolean setFundingRecoveryCorrelation (
  3779.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3780.         final org.drip.state.identifier.RatingLabel ratingLabel,
  3781.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3782.     {
  3783.         if (null == fundingLabel || null == ratingLabel || null == auCorrelation) return false;

  3784.         _mapFundingRatingCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3785.             ratingLabel.fullyQualifiedName(), auCorrelation);

  3786.         return true;
  3787.     }

  3788.     /**
  3789.      * Retrieve the Correlation Surface between the Funding and the Recovery Latent States
  3790.      *
  3791.      * @param fundingLabel The Funding Latent State Label
  3792.      * @param recoveryLabel The Recovery Latent State Label
  3793.      *
  3794.      * @return The Correlation Surface between the Funding and the Recovery Latent States
  3795.      */

  3796.     public org.drip.function.definition.R1ToR1 fundingRecoveryCorrelation (
  3797.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3798.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  3799.     {
  3800.         if (null == fundingLabel || null == recoveryLabel) return null;

  3801.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" +
  3802.             recoveryLabel.fullyQualifiedName();

  3803.         return _mapFundingRecoveryCorrelation.containsKey (strCode) ?
  3804.             _mapFundingRecoveryCorrelation.get (strCode) : null;
  3805.     }

  3806.     /**
  3807.      * (Re)-set the Correlation Surface between the Funding and the Recovery Latent States
  3808.      *
  3809.      * @param fundingLabel The Funding Latent State Label
  3810.      * @param recoveryLabel The Recovery Latent State Label
  3811.      * @param auCorrelation The Correlation Surface
  3812.      *
  3813.      * @return TRUE - Successfully set
  3814.      */

  3815.     public boolean setFundingRecoveryCorrelation (
  3816.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3817.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  3818.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3819.     {
  3820.         if (null == fundingLabel || null == recoveryLabel || null == auCorrelation) return false;

  3821.         _mapFundingRecoveryCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3822.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  3823.         return true;
  3824.     }

  3825.     /**
  3826.      * Retrieve the Correlation Surface between the Funding and the Repo Latent States
  3827.      *
  3828.      * @param fundingLabel The Funding Latent State Label
  3829.      * @param repoLabel The Repo Latent State Label
  3830.      *
  3831.      * @return The Correlation Surface between the Funding and the Repo Latent States
  3832.      */

  3833.     public org.drip.function.definition.R1ToR1 fundingRepoCorrelation (
  3834.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3835.         final org.drip.state.identifier.RepoLabel repoLabel)
  3836.     {
  3837.         if (null == fundingLabel || null == repoLabel) return null;

  3838.         java.lang.String strCode = fundingLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  3839.         return _mapFundingRepoCorrelation.containsKey (strCode) ?
  3840.             _mapFundingRepoCorrelation.get (strCode) : null;
  3841.     }

  3842.     /**
  3843.      * (Re)-set the Correlation Surface between the Funding and the Repo Latent States
  3844.      *
  3845.      * @param fundingLabel The Funding Latent State Label
  3846.      * @param repoLabel The Repo Latent State Label
  3847.      * @param auCorrelation The Correlation Surface
  3848.      *
  3849.      * @return TRUE - Successfully set
  3850.      */

  3851.     public boolean setFundingRepoCorrelation (
  3852.         final org.drip.state.identifier.FundingLabel fundingLabel,
  3853.         final org.drip.state.identifier.RepoLabel repoLabel,
  3854.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3855.     {
  3856.         if (null == fundingLabel || null == repoLabel || null == auCorrelation) return false;

  3857.         _mapFundingRepoCorrelation.put (fundingLabel.fullyQualifiedName() + "@#" +
  3858.             repoLabel.fullyQualifiedName(), auCorrelation);

  3859.         return true;
  3860.     }

  3861.     /**
  3862.      * Retrieve the Correlation Surface for the specified FX and the Govvie Latent States
  3863.      *
  3864.      * @param fxLabel The FX Latent State Label
  3865.      * @param govvieLabel The Govvie Latent State Label
  3866.      *
  3867.      * @return The Correlation Surface for the specified FX and the Govvie Latent States
  3868.      */

  3869.     public org.drip.function.definition.R1ToR1 fxGovvieCorrelation (
  3870.         final org.drip.state.identifier.FXLabel fxLabel,
  3871.         final org.drip.state.identifier.GovvieLabel govvieLabel)
  3872.     {
  3873.         if (null == fxLabel || null == govvieLabel) return null;

  3874.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + govvieLabel.fullyQualifiedName();

  3875.         return _mapFXGovvieCorrelation.containsKey (strCode) ? _mapFXGovvieCorrelation.get
  3876.             (strCode) : null;
  3877.     }

  3878.     /**
  3879.      * (Re)-set the Correlation Surface for the specified FX and the Govvie Latent States
  3880.      *
  3881.      * @param fxLabel The FX Latent State Label
  3882.      * @param govvieLabel The Govvie Latent State Label
  3883.      * @param auCorrelation The Correlation Surface
  3884.      *
  3885.      * @return TRUE - Successfully set
  3886.      */

  3887.     public boolean setFXGovvieCorrelation (
  3888.         final org.drip.state.identifier.FXLabel fxLabel,
  3889.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  3890.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3891.     {
  3892.         if (null == fxLabel || null == govvieLabel || null == auCorrelation) return false;

  3893.         _mapFXGovvieCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  3894.             govvieLabel.fullyQualifiedName(), auCorrelation);

  3895.         return true;
  3896.     }

  3897.     /**
  3898.      * Retrieve the Correlation Surface for the specified FX and the Overnight Latent States
  3899.      *
  3900.      * @param fxLabel The FX Latent State Label
  3901.      * @param overnightLabel The Overnight Latent State Label
  3902.      *
  3903.      * @return The Correlation Surface for the specified FX and the Overnight Latent States
  3904.      */

  3905.     public org.drip.function.definition.R1ToR1 fxOvernightCorrelation (
  3906.         final org.drip.state.identifier.FXLabel fxLabel,
  3907.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  3908.     {
  3909.         if (null == fxLabel || null == overnightLabel) return null;

  3910.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + overnightLabel.fullyQualifiedName();

  3911.         return _mapFXOvernightCorrelation.containsKey (strCode) ?
  3912.             _mapFXOvernightCorrelation.get (strCode) : null;
  3913.     }

  3914.     /**
  3915.      * (Re)-set the Correlation Surface for the specified FX and the Overnight Latent States
  3916.      *
  3917.      * @param fxLabel The FX Latent State Label
  3918.      * @param overnightLabel The Overnight Latent State Label
  3919.      * @param auCorrelation The Correlation Surface
  3920.      *
  3921.      * @return TRUE - Successfully set
  3922.      */

  3923.     public boolean setFXOvernightCorrelation (
  3924.         final org.drip.state.identifier.FXLabel fxLabel,
  3925.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  3926.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3927.     {
  3928.         if (null == fxLabel || null == overnightLabel || null == auCorrelation) return false;

  3929.         _mapFXOvernightCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  3930.             overnightLabel.fullyQualifiedName(), auCorrelation);

  3931.         return true;
  3932.     }

  3933.     /**
  3934.      * Retrieve the Correlation Surface for the specified FX and the Pay-down Latent States
  3935.      *
  3936.      * @param fxLabel The FX Latent State Label
  3937.      * @param paydownLabel The Pay-down Latent State Label
  3938.      *
  3939.      * @return The Correlation Surface for the specified FX and the Pay-down Latent States
  3940.      */

  3941.     public org.drip.function.definition.R1ToR1 fxPaydownCorrelation (
  3942.         final org.drip.state.identifier.FXLabel fxLabel,
  3943.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  3944.     {
  3945.         if (null == fxLabel || null == paydownLabel) return null;

  3946.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + paydownLabel.fullyQualifiedName();

  3947.         return _mapFXPaydownCorrelation.containsKey (strCode) ? _mapFXPaydownCorrelation.get
  3948.             (strCode) : null;
  3949.     }

  3950.     /**
  3951.      * (Re)-set the Correlation Surface for the specified FX and the Pay-down Latent States
  3952.      *
  3953.      * @param fxLabel The FX Latent State Label
  3954.      * @param paydownLabel The Pay-down Latent State Label
  3955.      * @param auCorrelation The Correlation Surface
  3956.      *
  3957.      * @return TRUE - Successfully set
  3958.      */

  3959.     public boolean setFXPaydownCorrelation (
  3960.         final org.drip.state.identifier.FXLabel fxLabel,
  3961.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  3962.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3963.     {
  3964.         if (null == fxLabel || null == paydownLabel || null == auCorrelation) return false;

  3965.         _mapFXPaydownCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  3966.             paydownLabel.fullyQualifiedName(), auCorrelation);

  3967.         return true;
  3968.     }

  3969.     /**
  3970.      * Retrieve the Correlation Surface for the specified FX and the Rating Latent States
  3971.      *
  3972.      * @param fxLabel The FX Latent State Label
  3973.      * @param ratingLabel The Rating Latent State Label
  3974.      *
  3975.      * @return The Correlation Surface for the specified FX and the Rating Latent States
  3976.      */

  3977.     public org.drip.function.definition.R1ToR1 fxRatingCorrelation (
  3978.         final org.drip.state.identifier.FXLabel fxLabel,
  3979.         final org.drip.state.identifier.RatingLabel ratingLabel)
  3980.     {
  3981.         if (null == fxLabel || null == ratingLabel) return null;

  3982.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + ratingLabel.fullyQualifiedName();

  3983.         return _mapFXRatingCorrelation.containsKey (strCode) ? _mapFXRatingCorrelation.get
  3984.             (strCode) : null;
  3985.     }

  3986.     /**
  3987.      * (Re)-set the Correlation Surface for the specified FX and the Rating Latent States
  3988.      *
  3989.      * @param fxLabel The FX Latent State Label
  3990.      * @param ratingLabel The Rating Latent State Label
  3991.      * @param auCorrelation The Correlation Surface
  3992.      *
  3993.      * @return TRUE - Successfully set
  3994.      */

  3995.     public boolean setFXRatingCorrelation (
  3996.         final org.drip.state.identifier.FXLabel fxLabel,
  3997.         final org.drip.state.identifier.RatingLabel ratingLabel,
  3998.         final org.drip.function.definition.R1ToR1 auCorrelation)
  3999.     {
  4000.         if (null == fxLabel || null == ratingLabel || null == auCorrelation) return false;

  4001.         _mapFXRatingCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  4002.             ratingLabel.fullyQualifiedName(), auCorrelation);

  4003.         return true;
  4004.     }

  4005.     /**
  4006.      * Retrieve the Correlation Surface for the specified FX and the Recovery Latent States
  4007.      *
  4008.      * @param fxLabel The FX Latent State Label
  4009.      * @param recoveryLabel The Recovery Latent State Label
  4010.      *
  4011.      * @return The Correlation Surface for the specified FX and the Recovery Latent States
  4012.      */

  4013.     public org.drip.function.definition.R1ToR1 fxRecoveryCorrelation (
  4014.         final org.drip.state.identifier.FXLabel fxLabel,
  4015.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  4016.     {
  4017.         if (null == fxLabel || null == recoveryLabel) return null;

  4018.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + recoveryLabel.fullyQualifiedName();

  4019.         return _mapFXRecoveryCorrelation.containsKey (strCode) ? _mapFXRecoveryCorrelation.get
  4020.             (strCode) : null;
  4021.     }

  4022.     /**
  4023.      * (Re)-set the Correlation Surface for the specified FX and the Recovery Latent States
  4024.      *
  4025.      * @param fxLabel The FX Latent State Label
  4026.      * @param recoveryLabel The Recovery Latent State Label
  4027.      * @param auCorrelation The Correlation Surface
  4028.      *
  4029.      * @return TRUE - Successfully set
  4030.      */

  4031.     public boolean setFXRecoveryCorrelation (
  4032.         final org.drip.state.identifier.FXLabel fxLabel,
  4033.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4034.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4035.     {
  4036.         if (null == fxLabel || null == recoveryLabel || null == auCorrelation) return false;

  4037.         _mapFXRecoveryCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  4038.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  4039.         return true;
  4040.     }

  4041.     /**
  4042.      * Retrieve the Correlation Surface for the specified FX and the Repo Latent States
  4043.      *
  4044.      * @param fxLabel The FX Latent State Label
  4045.      * @param repoLabel The Repo Latent State Label
  4046.      *
  4047.      * @return The Correlation Surface for the specified FX and the Repo Latent States
  4048.      */

  4049.     public org.drip.function.definition.R1ToR1 fxRepoCorrelation (
  4050.         final org.drip.state.identifier.FXLabel fxLabel,
  4051.         final org.drip.state.identifier.RepoLabel repoLabel)
  4052.     {
  4053.         if (null == fxLabel || null == repoLabel) return null;

  4054.         java.lang.String strCode = fxLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  4055.         return _mapFXRepoCorrelation.containsKey (strCode) ? _mapFXRepoCorrelation.get
  4056.             (strCode) : null;
  4057.     }

  4058.     /**
  4059.      * (Re)-set the Correlation Surface for the specified FX and the Repo Latent States
  4060.      *
  4061.      * @param fxLabel The FX Latent State Label
  4062.      * @param repoLabel The Repo Latent State Label
  4063.      * @param auCorrelation The Correlation Surface
  4064.      *
  4065.      * @return TRUE - Successfully set
  4066.      */

  4067.     public boolean setFXRepoCorrelation (
  4068.         final org.drip.state.identifier.FXLabel fxLabel,
  4069.         final org.drip.state.identifier.RepoLabel repoLabel,
  4070.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4071.     {
  4072.         if (null == fxLabel || null == repoLabel || null == auCorrelation) return false;

  4073.         _mapFXRepoCorrelation.put (fxLabel.fullyQualifiedName() + "@#" +
  4074.             repoLabel.fullyQualifiedName(), auCorrelation);

  4075.         return true;
  4076.     }

  4077.     /**
  4078.      * (Re)-set the Correlation Surface for the specified Govvie and the Overnight Latent States
  4079.      *
  4080.      * @param govvieLabel The Govvie Latent State Label
  4081.      * @param overnightLabel The Overnight Latent State Label
  4082.      * @param auCorrelation The Correlation Surface
  4083.      *
  4084.      * @return TRUE - Successfully set
  4085.      */

  4086.     public boolean setGovvieOvernightCorrelation (
  4087.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4088.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4089.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4090.     {
  4091.         if (null == govvieLabel || null == overnightLabel || null == auCorrelation) return false;

  4092.         _mapGovvieOvernightCorrelation.put (govvieLabel.fullyQualifiedName() + "@#" +
  4093.             overnightLabel.fullyQualifiedName(), auCorrelation);

  4094.         return true;
  4095.     }

  4096.     /**
  4097.      * Retrieve the Correlation Surface for the specified Govvie and the Overnight Latent States
  4098.      *
  4099.      * @param govvieLabel The Govvie Latent State Label
  4100.      * @param overnightLabel The Overnight Latent State Label
  4101.      *
  4102.      * @return The Correlation Surface for the specified Govvie and the Overnight Latent States
  4103.      */

  4104.     public org.drip.function.definition.R1ToR1 govvieOvernightCorrelation (
  4105.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4106.         final org.drip.state.identifier.OvernightLabel overnightLabel)
  4107.     {
  4108.         if (null == govvieLabel || null == overnightLabel) return null;

  4109.         java.lang.String strCode = govvieLabel.fullyQualifiedName() + "@#" +
  4110.             overnightLabel.fullyQualifiedName();

  4111.         return _mapGovvieOvernightCorrelation.containsKey (strCode) ?
  4112.             _mapGovvieOvernightCorrelation.get (strCode) : null;
  4113.     }

  4114.     /**
  4115.      * Retrieve the Correlation Surface for the specified Govvie and the Pay-down Latent States
  4116.      *
  4117.      * @param govvieLabel The Govvie Latent State Label
  4118.      * @param paydownLabel The Pay-down Latent State Label
  4119.      *
  4120.      * @return The Correlation Surface for the specified Govvie and the Pay-down Latent States
  4121.      */

  4122.     public org.drip.function.definition.R1ToR1 govviePaydownCorrelation (
  4123.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4124.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  4125.     {
  4126.         if (null == govvieLabel || null == paydownLabel) return null;

  4127.         java.lang.String strCode = govvieLabel.fullyQualifiedName() + "@#" +
  4128.             paydownLabel.fullyQualifiedName();

  4129.         return _mapGovviePaydownCorrelation.containsKey (strCode) ?
  4130.             _mapGovviePaydownCorrelation.get (strCode) : null;
  4131.     }

  4132.     /**
  4133.      * (Re)-set the Correlation Surface for the specified Govvie and the Pay-down Latent States
  4134.      *
  4135.      * @param govvieLabel The Govvie Latent State Label
  4136.      * @param paydownLabel The Pay-down Latent State Label
  4137.      * @param auCorrelation The Correlation Surface
  4138.      *
  4139.      * @return TRUE - Successfully set
  4140.      */

  4141.     public boolean setGovviePaydownCorrelation (
  4142.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4143.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4144.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4145.     {
  4146.         if (null == govvieLabel || null == paydownLabel || null == auCorrelation) return false;

  4147.         _mapGovviePaydownCorrelation.put (govvieLabel.fullyQualifiedName() + "@#" +
  4148.             paydownLabel.fullyQualifiedName(), auCorrelation);

  4149.         return true;
  4150.     }

  4151.     /**
  4152.      * Retrieve the Correlation Surface for the specified Govvie and the Rating Latent States
  4153.      *
  4154.      * @param govvieLabel The Govvie Latent State Label
  4155.      * @param ratingLabel The Rating Latent State Label
  4156.      *
  4157.      * @return The Correlation Surface for the specified Govvie and the Rating Latent States
  4158.      */

  4159.     public org.drip.function.definition.R1ToR1 govvieRecoveryCorrelation (
  4160.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4161.         final org.drip.state.identifier.RatingLabel ratingLabel)
  4162.     {
  4163.         if (null == govvieLabel || null == ratingLabel) return null;

  4164.         java.lang.String strCode = govvieLabel.fullyQualifiedName() + "@#" +
  4165.             ratingLabel.fullyQualifiedName();

  4166.         return _mapGovvieRecoveryCorrelation.containsKey (strCode) ?
  4167.             _mapGovvieRecoveryCorrelation.get (strCode) : null;
  4168.     }

  4169.     /**
  4170.      * (Re)-set the Correlation Surface for the specified Govvie and the Rating Latent States
  4171.      *
  4172.      * @param govvieLabel The Govvie Latent State Label
  4173.      * @param ratingLabel The Rating Latent State Label
  4174.      * @param auCorrelation The Correlation Surface
  4175.      *
  4176.      * @return TRUE - Successfully set
  4177.      */

  4178.     public boolean setGovvieRatingCorrelation (
  4179.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4180.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4181.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4182.     {
  4183.         if (null == govvieLabel || null == ratingLabel || null == auCorrelation) return false;

  4184.         _mapGovvieRatingCorrelation.put (govvieLabel.fullyQualifiedName() + "@#" +
  4185.             ratingLabel.fullyQualifiedName(), auCorrelation);

  4186.         return true;
  4187.     }

  4188.     /**
  4189.      * Retrieve the Correlation Surface for the specified Govvie and the Recovery Latent States
  4190.      *
  4191.      * @param govvieLabel The Govvie Latent State Label
  4192.      * @param recoveryLabel The Recovery Latent State Label
  4193.      *
  4194.      * @return The Correlation Surface for the specified Govvie and the Recovery Latent States
  4195.      */

  4196.     public org.drip.function.definition.R1ToR1 govvieRecoveryCorrelation (
  4197.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4198.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  4199.     {
  4200.         if (null == govvieLabel || null == recoveryLabel) return null;

  4201.         java.lang.String strCode = govvieLabel.fullyQualifiedName() + "@#" +
  4202.             recoveryLabel.fullyQualifiedName();

  4203.         return _mapGovvieRecoveryCorrelation.containsKey (strCode) ?
  4204.             _mapGovvieRecoveryCorrelation.get (strCode) : null;
  4205.     }

  4206.     /**
  4207.      * (Re)-set the Correlation Surface for the specified Govvie and the Recovery Latent States
  4208.      *
  4209.      * @param govvieLabel The Govvie Latent State Label
  4210.      * @param recoveryLabel The Recovery Latent State Label
  4211.      * @param auCorrelation The Correlation Surface
  4212.      *
  4213.      * @return TRUE - Successfully set
  4214.      */

  4215.     public boolean setGovvieRecoveryCorrelation (
  4216.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4217.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4218.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4219.     {
  4220.         if (null == govvieLabel || null == recoveryLabel || null == auCorrelation) return false;

  4221.         _mapGovvieRecoveryCorrelation.put (govvieLabel.fullyQualifiedName() + "@#" +
  4222.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  4223.         return true;
  4224.     }

  4225.     /**
  4226.      * Retrieve the Correlation Surface for the specified Govvie and the Repo Latent States
  4227.      *
  4228.      * @param govvieLabel The Govvie Latent State Label
  4229.      * @param repoLabel The Repo Latent State Label
  4230.      *
  4231.      * @return The Correlation Surface for the specified Govvie and the Repo Latent States
  4232.      */

  4233.     public org.drip.function.definition.R1ToR1 govvieRepoCorrelation (
  4234.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4235.         final org.drip.state.identifier.RepoLabel repoLabel)
  4236.     {
  4237.         if (null == govvieLabel || null == repoLabel) return null;

  4238.         java.lang.String strCode = govvieLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  4239.         return _mapGovvieRepoCorrelation.containsKey (strCode) ? _mapGovvieRepoCorrelation.get
  4240.             (strCode) : null;
  4241.     }

  4242.     /**
  4243.      * (Re)-set the Correlation Surface for the specified Govvie and the Repo Latent States
  4244.      *
  4245.      * @param govvieLabel The Govvie Latent State Label
  4246.      * @param repoLabel The Repo Latent State Label
  4247.      * @param auCorrelation The Correlation Surface
  4248.      *
  4249.      * @return TRUE - Successfully set
  4250.      */

  4251.     public boolean setGovvieRepoCorrelation (
  4252.         final org.drip.state.identifier.GovvieLabel govvieLabel,
  4253.         final org.drip.state.identifier.RepoLabel repoLabel,
  4254.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4255.     {
  4256.         if (null == govvieLabel || null == repoLabel || null == auCorrelation) return false;

  4257.         _mapGovvieRepoCorrelation.put (govvieLabel.fullyQualifiedName() + "@#" +
  4258.             repoLabel.fullyQualifiedName(), auCorrelation);

  4259.         return true;
  4260.     }

  4261.     /**
  4262.      * Retrieve the Correlation Surface for the specified Overnight and the Pay-down Latent States
  4263.      *
  4264.      * @param overnightLabel The Overnight Latent State Label
  4265.      * @param paydownLabel The Pay-down Latent State Label
  4266.      *
  4267.      * @return The Correlation Surface for the specified Overnight and the Pay-down Latent States
  4268.      */

  4269.     public org.drip.function.definition.R1ToR1 overnightPaydownCorrelation (
  4270.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4271.         final org.drip.state.identifier.PaydownLabel paydownLabel)
  4272.     {
  4273.         if (null == overnightLabel || null == paydownLabel) return null;

  4274.         java.lang.String strCode = overnightLabel.fullyQualifiedName() + "@#" +
  4275.             paydownLabel.fullyQualifiedName();

  4276.         return _mapOvernightPaydownCorrelation.containsKey (strCode) ?
  4277.             _mapOvernightPaydownCorrelation.get (strCode) : null;
  4278.     }

  4279.     /**
  4280.      * (Re)-set the Correlation Surface for the specified Overnight and the Pay-down Latent States
  4281.      *
  4282.      * @param overnightLabel The Overnight Latent State Label
  4283.      * @param paydownLabel The Pay-down Latent State Label
  4284.      * @param auCorrelation The Correlation Surface
  4285.      *
  4286.      * @return TRUE - Successfully set
  4287.      */

  4288.     public boolean setOvernightPaydownCorrelation (
  4289.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4290.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4291.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4292.     {
  4293.         if (null == overnightLabel || null == paydownLabel || null == auCorrelation) return false;

  4294.         _mapOvernightPaydownCorrelation.put (overnightLabel.fullyQualifiedName() + "@#" +
  4295.             paydownLabel.fullyQualifiedName(), auCorrelation);

  4296.         return true;
  4297.     }

  4298.     /**
  4299.      * Retrieve the Correlation Surface for the specified Overnight and the Rating Latent States
  4300.      *
  4301.      * @param overnightLabel The Overnight Latent State Label
  4302.      * @param ratingLabel The Rating Latent State Label
  4303.      *
  4304.      * @return The Correlation Surface for the specified Overnight and the Rating Latent States
  4305.      */

  4306.     public org.drip.function.definition.R1ToR1 overnightRatingCorrelation (
  4307.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4308.         final org.drip.state.identifier.RatingLabel ratingLabel)
  4309.     {
  4310.         if (null == overnightLabel || null == ratingLabel) return null;

  4311.         java.lang.String strCode = overnightLabel.fullyQualifiedName() + "@#" +
  4312.             ratingLabel.fullyQualifiedName();

  4313.         return _mapOvernightRatingCorrelation.containsKey (strCode) ?
  4314.             _mapOvernightRatingCorrelation.get (strCode) : null;
  4315.     }

  4316.     /**
  4317.      * (Re)-set the Correlation Surface for the specified Overnight and the Rating Latent States
  4318.      *
  4319.      * @param overnightLabel The Overnight Latent State Label
  4320.      * @param ratingLabel The Rating Latent State Label
  4321.      * @param auCorrelation The Correlation Surface
  4322.      *
  4323.      * @return TRUE - Successfully set
  4324.      */

  4325.     public boolean setOvernightRatingCorrelation (
  4326.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4327.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4328.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4329.     {
  4330.         if (null == overnightLabel || null == ratingLabel || null == auCorrelation) return false;

  4331.         _mapOvernightRatingCorrelation.put (overnightLabel.fullyQualifiedName() + "@#" +
  4332.             ratingLabel.fullyQualifiedName(), auCorrelation);

  4333.         return true;
  4334.     }

  4335.     /**
  4336.      * Retrieve the Correlation Surface for the specified Overnight and the Recovery Latent States
  4337.      *
  4338.      * @param overnightLabel The Overnight Latent State Label
  4339.      * @param recoveryLabel The Recovery Latent State Label
  4340.      *
  4341.      * @return The Correlation Surface for the specified Overnight and the Recovery Latent States
  4342.      */

  4343.     public org.drip.function.definition.R1ToR1 overnightRecoveryCorrelation (
  4344.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4345.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  4346.     {
  4347.         if (null == overnightLabel || null == recoveryLabel) return null;

  4348.         java.lang.String strCode = overnightLabel.fullyQualifiedName() + "@#" +
  4349.             recoveryLabel.fullyQualifiedName();

  4350.         return _mapOvernightRecoveryCorrelation.containsKey (strCode) ?
  4351.             _mapOvernightRecoveryCorrelation.get (strCode) : null;
  4352.     }

  4353.     /**
  4354.      * (Re)-set the Correlation Surface for the specified Overnight and the Recovery Latent States
  4355.      *
  4356.      * @param overnightLabel The Overnight Latent State Label
  4357.      * @param recoveryLabel The Recovery Latent State Label
  4358.      * @param auCorrelation The Correlation Surface
  4359.      *
  4360.      * @return TRUE - Successfully set
  4361.      */

  4362.     public boolean setOvernightRecoveryCorrelation (
  4363.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4364.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4365.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4366.     {
  4367.         if (null == overnightLabel || null == recoveryLabel || null == auCorrelation) return false;

  4368.         _mapOvernightRecoveryCorrelation.put (overnightLabel.fullyQualifiedName() + "@#" +
  4369.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  4370.         return true;
  4371.     }

  4372.     /**
  4373.      * Retrieve the Correlation Surface for the specified Overnight and the Repo Latent States
  4374.      *
  4375.      * @param overnightLabel The Overnight Latent State Label
  4376.      * @param repoLabel The Repo Latent State Label
  4377.      *
  4378.      * @return The Correlation Surface for the specified Overnight and the Repo Latent States
  4379.      */

  4380.     public org.drip.function.definition.R1ToR1 overnightRepoCorrelation (
  4381.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4382.         final org.drip.state.identifier.RepoLabel repoLabel)
  4383.     {
  4384.         if (null == overnightLabel || null == repoLabel) return null;

  4385.         java.lang.String strCode = overnightLabel.fullyQualifiedName() + "@#" +
  4386.             repoLabel.fullyQualifiedName();

  4387.         return _mapOvernightRepoCorrelation.containsKey (strCode) ?
  4388.             _mapOvernightRepoCorrelation.get (strCode) : null;
  4389.     }

  4390.     /**
  4391.      * (Re)-set the Correlation Surface for the specified Overnight and the Repo Latent States
  4392.      *
  4393.      * @param overnightLabel The Overnight Latent State Label
  4394.      * @param repoLabel The Repo Latent State Label
  4395.      * @param auCorrelation The Correlation Surface
  4396.      *
  4397.      * @return TRUE - Successfully set
  4398.      */

  4399.     public boolean setOvernightRepoCorrelation (
  4400.         final org.drip.state.identifier.OvernightLabel overnightLabel,
  4401.         final org.drip.state.identifier.RepoLabel repoLabel,
  4402.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4403.     {
  4404.         if (null == overnightLabel || null == repoLabel || null == auCorrelation) return false;

  4405.         _mapOvernightRepoCorrelation.put (overnightLabel.fullyQualifiedName() + "@#" +
  4406.             repoLabel.fullyQualifiedName(), auCorrelation);

  4407.         return true;
  4408.     }

  4409.     /**
  4410.      * Retrieve the Correlation Surface for the specified Pay-down and the Rating Latent States
  4411.      *
  4412.      * @param paydownLabel The Pay-down Latent State Label
  4413.      * @param ratingLabel The Rating Latent State Label
  4414.      *
  4415.      * @return The Correlation Surface for the specified Pay-down and the Rating Latent States
  4416.      */

  4417.     public org.drip.function.definition.R1ToR1 paydownRatingCorrelation (
  4418.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4419.         final org.drip.state.identifier.RatingLabel ratingLabel)
  4420.     {
  4421.         if (null == paydownLabel || null == ratingLabel) return null;

  4422.         java.lang.String strCode = paydownLabel.fullyQualifiedName() + "@#" +
  4423.             ratingLabel.fullyQualifiedName();

  4424.         return _mapPaydownRatingCorrelation.containsKey (strCode) ?
  4425.             _mapPaydownRatingCorrelation.get (strCode) : null;
  4426.     }

  4427.     /**
  4428.      * (Re)-set the Correlation Surface for the specified Pay-down and the Rating Latent States
  4429.      *
  4430.      * @param paydownLabel The Pay-down Latent State Label
  4431.      * @param ratingLabel The Rating Latent State Label
  4432.      * @param auCorrelation The Correlation Surface
  4433.      *
  4434.      * @return TRUE - Successfully set
  4435.      */

  4436.     public boolean setPaydownRatingCorrelation (
  4437.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4438.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4439.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4440.     {
  4441.         if (null == paydownLabel || null == ratingLabel || null == auCorrelation) return false;

  4442.         _mapPaydownRatingCorrelation.put (paydownLabel.fullyQualifiedName() + "@#" +
  4443.             ratingLabel.fullyQualifiedName(), auCorrelation);

  4444.         return true;
  4445.     }

  4446.     /**
  4447.      * Retrieve the Correlation Surface for the specified Pay-down and the Recovery Latent States
  4448.      *
  4449.      * @param paydownLabel The Pay-down Latent State Label
  4450.      * @param recoveryLabel The Recovery Latent State Label
  4451.      *
  4452.      * @return The Correlation Surface for the specified Pay-down and the Recovery Latent States
  4453.      */

  4454.     public org.drip.function.definition.R1ToR1 paydownRecoveryCorrelation (
  4455.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4456.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  4457.     {
  4458.         if (null == paydownLabel || null == recoveryLabel) return null;

  4459.         java.lang.String strCode = paydownLabel.fullyQualifiedName() + "@#" +
  4460.             recoveryLabel.fullyQualifiedName();

  4461.         return _mapPaydownRecoveryCorrelation.containsKey (strCode) ?
  4462.             _mapPaydownRecoveryCorrelation.get (strCode) : null;
  4463.     }

  4464.     /**
  4465.      * (Re)-set the Correlation Surface for the specified Pay-down and the Recovery Latent States
  4466.      *
  4467.      * @param paydownLabel The Pay-down Latent State Label
  4468.      * @param recoveryLabel The Recovery Latent State Label
  4469.      * @param auCorrelation The Correlation Surface
  4470.      *
  4471.      * @return TRUE - Successfully set
  4472.      */

  4473.     public boolean setPaydownRecoveryCorrelation (
  4474.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4475.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4476.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4477.     {
  4478.         if (null == paydownLabel || null == recoveryLabel || null == auCorrelation) return false;

  4479.         _mapPaydownRecoveryCorrelation.put (paydownLabel.fullyQualifiedName() + "@#" +
  4480.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  4481.         return true;
  4482.     }

  4483.     /**
  4484.      * Retrieve the Correlation Surface for the specified Pay-down and the Repo Latent States
  4485.      *
  4486.      * @param paydownLabel The Pay-down Latent State Label
  4487.      * @param repoLabel The Repo Latent State Label
  4488.      *
  4489.      * @return The Correlation Surface for the specified Pay-down and the Repo Latent States
  4490.      */

  4491.     public org.drip.function.definition.R1ToR1 paydownRepoCorrelation (
  4492.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4493.         final org.drip.state.identifier.RepoLabel repoLabel)
  4494.     {
  4495.         if (null == paydownLabel || null == repoLabel) return null;

  4496.         java.lang.String strCode = paydownLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  4497.         return _mapPaydownRepoCorrelation.containsKey (strCode) ?
  4498.             _mapPaydownRepoCorrelation.get (strCode) : null;
  4499.     }

  4500.     /**
  4501.      * (Re)-set the Correlation Surface for the specified Pay-down and the Repo Latent States
  4502.      *
  4503.      * @param paydownLabel The Pay-down Latent State Label
  4504.      * @param repoLabel The Repo Latent State Label
  4505.      * @param auCorrelation The Correlation Surface
  4506.      *
  4507.      * @return TRUE - Successfully set
  4508.      */

  4509.     public boolean setPaydownRepoCorrelation (
  4510.         final org.drip.state.identifier.PaydownLabel paydownLabel,
  4511.         final org.drip.state.identifier.RepoLabel repoLabel,
  4512.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4513.     {
  4514.         if (null == paydownLabel || null == repoLabel || null == auCorrelation) return false;

  4515.         _mapPaydownRepoCorrelation.put (paydownLabel.fullyQualifiedName() + "@#" +
  4516.             repoLabel.fullyQualifiedName(), auCorrelation);

  4517.         return true;
  4518.     }

  4519.     /**
  4520.      * Retrieve the Correlation Surface for the specified Rating and the Rating Latent States
  4521.      *
  4522.      * @param ratingLabel1 The Rating Latent State Label #1
  4523.      * @param ratingLabel2 The Rating Latent State Label #2
  4524.      *
  4525.      * @return The Correlation Surface for the specified Pair of Rating Latent States
  4526.      */

  4527.     public org.drip.function.definition.R1ToR1 ratingRatingCorrelation (
  4528.         final org.drip.state.identifier.RatingLabel ratingLabel1,
  4529.         final org.drip.state.identifier.RatingLabel ratingLabel2)
  4530.     {
  4531.         if (null == ratingLabel1 || null == ratingLabel2) return null;

  4532.         java.lang.String strCode = ratingLabel1.fullyQualifiedName() + "@#" +
  4533.             ratingLabel2.fullyQualifiedName();

  4534.         return _mapRatingRatingCorrelation.containsKey (strCode) ?
  4535.             _mapRatingRatingCorrelation.get (strCode) : null;
  4536.     }

  4537.     /**
  4538.      * (Re)-set the Correlation Surface for the specified Pair of Rating Latent States
  4539.      *
  4540.      * @param ratingLabel1 The Rating Latent State Label #1
  4541.      * @param ratingLabel2 The Rating Latent State Label #2
  4542.      * @param auCorrelation The Correlation Surface
  4543.      *
  4544.      * @return TRUE - Successfully set
  4545.      */

  4546.     public boolean setRatingRatingCorrelation (
  4547.         final org.drip.state.identifier.RatingLabel ratingLabel1,
  4548.         final org.drip.state.identifier.RatingLabel ratingLabel2,
  4549.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4550.     {
  4551.         if (null == ratingLabel1 || null == ratingLabel2 || null == auCorrelation) return false;

  4552.         _mapRatingRatingCorrelation.put (ratingLabel1.fullyQualifiedName() + "@#" +
  4553.             ratingLabel2.fullyQualifiedName(), auCorrelation);

  4554.         return true;
  4555.     }

  4556.     /**
  4557.      * Retrieve the Correlation Surface for the specified Rating and Recovery Latent States
  4558.      *
  4559.      * @param ratingLabel The Rating Latent State Label
  4560.      * @param recoveryLabel The Recovery Latent State Label
  4561.      *
  4562.      * @return The Correlation Surface for the specified Rating and Recovery Latent States
  4563.      */

  4564.     public org.drip.function.definition.R1ToR1 ratingRecoveryCorrelation (
  4565.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4566.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel)
  4567.     {
  4568.         if (null == ratingLabel || null == recoveryLabel) return null;

  4569.         java.lang.String strCode = ratingLabel.fullyQualifiedName() + "@#" +
  4570.             recoveryLabel.fullyQualifiedName();

  4571.         return _mapRatingRecoveryCorrelation.containsKey (strCode) ?
  4572.             _mapRatingRecoveryCorrelation.get (strCode) : null;
  4573.     }

  4574.     /**
  4575.      * (Re)-set the Correlation Surface for the specified Rating and Recovery Latent States
  4576.      *
  4577.      * @param ratingLabel The Rating Latent State Label
  4578.      * @param recoveryLabel The Recovery Latent State Label
  4579.      * @param auCorrelation The Correlation Surface
  4580.      *
  4581.      * @return TRUE - Successfully set
  4582.      */

  4583.     public boolean setRatingRecoveryCorrelation (
  4584.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4585.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4586.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4587.     {
  4588.         if (null == ratingLabel || null == recoveryLabel || null == auCorrelation) return false;

  4589.         _mapRatingRecoveryCorrelation.put (ratingLabel.fullyQualifiedName() + "@#" +
  4590.             recoveryLabel.fullyQualifiedName(), auCorrelation);

  4591.         return true;
  4592.     }

  4593.     /**
  4594.      * Retrieve the Correlation Surface for the specified Rating and Repo Latent States
  4595.      *
  4596.      * @param ratingLabel The Rating Latent State Label
  4597.      * @param repoLabel The Repo Latent State Label
  4598.      *
  4599.      * @return The Correlation Surface for the specified Rating and Repo Latent States
  4600.      */

  4601.     public org.drip.function.definition.R1ToR1 ratingRepoCorrelation (
  4602.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4603.         final org.drip.state.identifier.RepoLabel repoLabel)
  4604.     {
  4605.         if (null == ratingLabel || null == repoLabel) return null;

  4606.         java.lang.String strCode = ratingLabel.fullyQualifiedName() + "@#" + repoLabel.fullyQualifiedName();

  4607.         return _mapRatingRepoCorrelation.containsKey (strCode) ? _mapRatingRepoCorrelation.get
  4608.             (strCode) : null;
  4609.     }

  4610.     /**
  4611.      * (Re)-set the Correlation Surface for the specified Rating and Repo Latent States
  4612.      *
  4613.      * @param ratingLabel The Rating Latent State Label
  4614.      * @param repoLabel The Repo Latent State Label
  4615.      * @param auCorrelation The Correlation Surface
  4616.      *
  4617.      * @return TRUE - Successfully set
  4618.      */

  4619.     public boolean setRatingRepoCorrelation (
  4620.         final org.drip.state.identifier.RatingLabel ratingLabel,
  4621.         final org.drip.state.identifier.RepoLabel repoLabel,
  4622.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4623.     {
  4624.         if (null == ratingLabel || null == repoLabel || null == auCorrelation) return false;

  4625.         _mapRatingRepoCorrelation.put (ratingLabel.fullyQualifiedName() + "@#" +
  4626.             repoLabel.fullyQualifiedName(), auCorrelation);

  4627.         return true;
  4628.     }

  4629.     /**
  4630.      * Retrieve the Correlation Surface for the specified Recovery and the Repo Latent States
  4631.      *
  4632.      * @param recoveryLabel The Recovery Latent State Label
  4633.      * @param repoLabel The Repo Latent State Label
  4634.      *
  4635.      * @return The Correlation Surface for the specified Recovery and the Repo Latent States
  4636.      */

  4637.     public org.drip.function.definition.R1ToR1 recoveryRepoCorrelation (
  4638.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4639.         final org.drip.state.identifier.RepoLabel repoLabel)
  4640.     {
  4641.         if (null == recoveryLabel || null == repoLabel) return null;

  4642.         java.lang.String strCode = recoveryLabel.fullyQualifiedName() + "@#" +
  4643.             repoLabel.fullyQualifiedName();

  4644.         return _mapRecoveryRepoCorrelation.containsKey (strCode) ?
  4645.             _mapRecoveryRepoCorrelation.get (strCode) : null;
  4646.     }

  4647.     /**
  4648.      * (Re)-set the Correlation Surface for the specified Recovery and the Repo Latent States
  4649.      *
  4650.      * @param recoveryLabel The Recovery Latent State Label
  4651.      * @param repoLabel The Repo Latent State Label
  4652.      * @param auCorrelation The Correlation Surface
  4653.      *
  4654.      * @return TRUE - Successfully set
  4655.      */

  4656.     public boolean setRecoveryRepoCorrelation (
  4657.         final org.drip.state.identifier.EntityRecoveryLabel recoveryLabel,
  4658.         final org.drip.state.identifier.RepoLabel repoLabel,
  4659.         final org.drip.function.definition.R1ToR1 auCorrelation)
  4660.     {
  4661.         if (null == recoveryLabel || null == repoLabel || null == auCorrelation) return false;

  4662.         _mapRecoveryRepoCorrelation.put (recoveryLabel.fullyQualifiedName() + "@#" +
  4663.             repoLabel.fullyQualifiedName(), auCorrelation);

  4664.         return true;
  4665.     }

  4666.     /**
  4667.      * Retrieve the Product Quote
  4668.      *
  4669.      * @param strProductCode Product Code
  4670.      *
  4671.      * @return Product Quote
  4672.      */

  4673.     public org.drip.param.definition.ProductQuote productQuote (
  4674.         final java.lang.String strProductCode)
  4675.     {
  4676.         if (null == strProductCode || strProductCode.isEmpty() || !_mapProductQuote.containsKey
  4677.             (strProductCode))
  4678.             return null;

  4679.         return _mapProductQuote.get (strProductCode);
  4680.     }

  4681.     /**
  4682.      * (Re)-set the Product Quote
  4683.      *
  4684.      * @param strProductCode Product Code
  4685.      * @param pq Product Quote
  4686.      *
  4687.      * @return TRUE - Successfully set
  4688.      */

  4689.     public boolean setProductQuote (
  4690.         final java.lang.String strProductCode,
  4691.         final org.drip.param.definition.ProductQuote pq)
  4692.     {
  4693.         if (null == strProductCode || strProductCode.isEmpty() || null == pq) return false;

  4694.         _mapProductQuote.put (strProductCode, pq);

  4695.         return true;
  4696.     }

  4697.     /**
  4698.      * Retrieve the Full Set of Quotes
  4699.      *
  4700.      * @return The Full Set of Quotes
  4701.      */

  4702.     public
  4703.         org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.param.definition.ProductQuote>
  4704.             quoteMap()
  4705.     {
  4706.         return _mapProductQuote;
  4707.     }

  4708.     /**
  4709.      * (Re)-set the Map of Quote
  4710.      *
  4711.      * @param mapQuote Map of Quotes
  4712.      *
  4713.      * @return TRUE - Successfully set
  4714.      */

  4715.     public boolean setQuoteMap (
  4716.         final org.drip.analytics.support.CaseInsensitiveTreeMap<org.drip.param.definition.ProductQuote>
  4717.             mapQuote)
  4718.     {
  4719.         if (null == mapQuote || 0 == mapQuote.size()) return false;

  4720.         for (java.util.Map.Entry<java.lang.String, org.drip.param.definition.ProductQuote> meCQ :
  4721.             mapQuote.entrySet()) {
  4722.             if (null == meCQ) continue;

  4723.             java.lang.String strKey = meCQ.getKey();

  4724.             org.drip.param.definition.ProductQuote cq = meCQ.getValue();

  4725.             if (null == strKey || strKey.isEmpty() || null == cq) continue;

  4726.             _mapProductQuote.put (strKey, cq);
  4727.         }

  4728.         return true;
  4729.     }

  4730.     /**
  4731.      * Set the Fixing corresponding to the Date/Label Pair
  4732.      *
  4733.      * @param dt The Fixing Date
  4734.      * @param lsl The Fixing Label
  4735.      * @param dblFixing The Fixing Amount
  4736.      *
  4737.      * @return TRUE - Entry successfully added
  4738.      */

  4739.     public boolean setFixing (
  4740.         final org.drip.analytics.date.JulianDate dt,
  4741.         final org.drip.state.identifier.LatentStateLabel lsl,
  4742.         final double dblFixing)
  4743.     {
  4744.         return _lsfc.add (dt, lsl, dblFixing);
  4745.     }

  4746.     /**
  4747.      * Set the Fixing corresponding to the Date/Label Pair
  4748.      *
  4749.      * @param iDate The Fixing Date
  4750.      * @param lsl The Fixing Label
  4751.      * @param dblFixing The Fixing Amount
  4752.      *
  4753.      * @return TRUE - Entry successfully added
  4754.      */

  4755.     public boolean setFixing (
  4756.         final int iDate,
  4757.         final org.drip.state.identifier.LatentStateLabel lsl,
  4758.         final double dblFixing)
  4759.     {
  4760.         return _lsfc.add (iDate, lsl, dblFixing);
  4761.     }

  4762.     /**
  4763.      * Remove the Fixing corresponding to the Date/Label Pair it if exists
  4764.      *
  4765.      * @param dt The Fixing Date
  4766.      * @param lsl The Fixing Label
  4767.      *
  4768.      * @return TRUE - Entry successfully removed if it existed
  4769.      */

  4770.     public boolean removeFixing (
  4771.         final org.drip.analytics.date.JulianDate dt,
  4772.         final org.drip.state.identifier.LatentStateLabel lsl)
  4773.     {
  4774.         return _lsfc.remove (dt, lsl);
  4775.     }

  4776.     /**
  4777.      * Remove the Fixing corresponding to the Date/Label Pair it if exists
  4778.      *
  4779.      * @param iDate The Fixing Date
  4780.      * @param lsl The Fixing Label
  4781.      *
  4782.      * @return TRUE - Entry successfully removed if it existed
  4783.      */

  4784.     public boolean removeFixing (
  4785.         final int iDate,
  4786.         final org.drip.state.identifier.LatentStateLabel lsl)
  4787.     {
  4788.         return _lsfc.remove (iDate, lsl);
  4789.     }

  4790.     /**
  4791.      * Retrieve the Fixing for the Specified Date/LSL Combination
  4792.      *
  4793.      * @param dt Date
  4794.      * @param lsl The Latent State Label
  4795.      *
  4796.      * @return The Fixing for the Specified Date/LSL Combination
  4797.      *
  4798.      * @throws java.lang.Exception Thrown if the Fixing cannot be found
  4799.      */

  4800.     public double fixing (
  4801.         final org.drip.analytics.date.JulianDate dt,
  4802.         final org.drip.state.identifier.LatentStateLabel lsl)
  4803.         throws java.lang.Exception
  4804.     {
  4805.         return _lsfc.fixing (dt, lsl);
  4806.     }

  4807.     /**
  4808.      * Retrieve the Fixing for the Specified Date/LSL Combination
  4809.      *
  4810.      * @param iDate Date
  4811.      * @param lsl The Latent State Label
  4812.      *
  4813.      * @return The Fixing for the Specified Date/LSL Combination
  4814.      *
  4815.      * @throws java.lang.Exception Thrown if the Fixing cannot be found
  4816.      */

  4817.     public double fixing (
  4818.         final int iDate,
  4819.         final org.drip.state.identifier.LatentStateLabel lsl)
  4820.         throws java.lang.Exception
  4821.     {
  4822.         return _lsfc.fixing (iDate, lsl);
  4823.     }

  4824.     /**
  4825.      * Indicates the Availability of the Fixing for the Specified LSL Label on the specified Date
  4826.      *
  4827.      * @param dt The Date
  4828.      * @param lsl The Label
  4829.      *
  4830.      * @return TRUE - The Fixing for the Specified LSL Label on the specified Date
  4831.      */

  4832.     public boolean available (
  4833.         final org.drip.analytics.date.JulianDate dt,
  4834.         final org.drip.state.identifier.LatentStateLabel lsl)
  4835.     {
  4836.         return _lsfc.available (dt, lsl);
  4837.     }

  4838.     /**
  4839.      * Indicates the Availability of the Fixing for the Specified LSL Label on the specified Date
  4840.      *
  4841.      * @param iDate The Date
  4842.      * @param lsl The Label
  4843.      *
  4844.      * @return TRUE - The Fixing for the Specified LSL Label on the specified Date
  4845.      */

  4846.     public boolean available (
  4847.         final int iDate,
  4848.         final org.drip.state.identifier.LatentStateLabel lsl)
  4849.     {
  4850.         return _lsfc.available (iDate, lsl);
  4851.     }

  4852.     /**
  4853.      * Retrieve the Latent State Fixings
  4854.      *
  4855.      * @return The Latent State Fixings
  4856.      */

  4857.     public org.drip.param.market.LatentStateFixingsContainer fixings()
  4858.     {
  4859.         return _lsfc;
  4860.     }

  4861.     /**
  4862.      * Set the Latent State Fixings Container Instance
  4863.      *
  4864.      * @param lsfc The Latent State Fixings Container Instance
  4865.      *
  4866.      * @return The Latent State Fixings Container Instance successfully set
  4867.      */

  4868.     public boolean setFixings (
  4869.         final org.drip.param.market.LatentStateFixingsContainer lsfc)
  4870.     {
  4871.         _lsfc = lsfc;
  4872.         return true;
  4873.     }
  4874. }