/// <summary>Gets a mutable Swap Market convention template which is initially filled with values of the current instance, i.e. with some standard conventions.
        /// </summary>
        /// <returns>A mutable Swap Market convention template.</returns>
        public SwapMarketConventions GetMutableTemplate()
        {
            SwapMarketConventions marketConventions = new SwapMarketConventions();

            marketConventions.SetStandardBusinessDaysToSettle(BusinessDaysToSettle);
            marketConventions.SetStandardFixingLag(FixingLag);
            marketConventions.SetStandardFixedBusinessDayConvention(FixedBusinessDayConvention);
            marketConventions.SetStandardFixedDayCountConvention(FixedDayCountConvention);
            marketConventions.SetStandardFixedFrequency(FixedFrequency);
            marketConventions.SetStandardFloatingBusinessDayConvention(FloatingBusinessDayConvention);
            marketConventions.SetStandardFloatingDayCountConvention(FloatingDayCountConvention);
            marketConventions.SetStandardFloatingFrequency(FloatingFrequency);

            return(marketConventions);
        }
 /// <summary>Initializes a new instance of the <see cref="ReadOnlySwapMarketConventions"/> class.
 /// </summary>
 /// <param name="swapMarketConventions">The swap market conventions.</param>
 /// <exception cref="ArgumentNullException">Thrown, if <paramref name="swapMarketConventions"/> is <c>null</c>.</exception>
 /// <exception cref="ArgumentException">Thrown, if <paramref name="swapMarketConventions"/> is not completely defined.</exception>
 public ReadOnlySwapMarketConventions(SwapMarketConventions swapMarketConventions)
 {
     if (swapMarketConventions == null)
     {
         throw new ArgumentNullException("swapMarketConventions");
     }
     if (swapMarketConventions.IsCompletelyDefined == false)
     {
         throw new ArgumentException(String.Format(ExceptionMessages.ArgumentIsNotWellDefined, "Swap market conventions"), "swapMarketConventions");
     }
     BusinessDaysToSettle          = swapMarketConventions.BusinessDaysToSettle.Value;
     FixingLag                     = swapMarketConventions.FixingLag;
     FixedBusinessDayConvention    = swapMarketConventions.FixedBusinessDayConvention;
     FixedDayCountConvention       = swapMarketConventions.FixedDayCountConvention;
     FixedFrequency                = swapMarketConventions.FixedFrequency;
     FloatingBusinessDayConvention = swapMarketConventions.FloatingBusinessDayConvention;
     FloatingDayCountConvention    = swapMarketConventions.FloatingDayCountConvention;
     FloatingFrequency             = swapMarketConventions.FloatingFrequency;
 }
 /// <summary>Adds default market conventions that are taken into account into a specific logger.
 /// </summary>
 /// <param name="logger">The logger.</param>
 /// <param name="marketConventions">The market conventions which are taken into account.</param>
 /// <param name="userMarketConventionInput">The user input of market conventions.</param>
 public static void Add_Info(this ILogger logger, ReadOnlySwapMarketConventions marketConventions, SwapMarketConventions userMarketConventionInput = null)
 {
     if ((logger != null) && (marketConventions != null))
     {
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.BusinessDaysToSettleState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Business days to settle", marketConventions.BusinessDaysToSettle);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FixingLagState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Fixing Lag", marketConventions.FixingLag.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FixedBusinessDayConventionState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Fixed Business day convention", marketConventions.FixedBusinessDayConvention.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FixedDayCountConventionState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Fixed Day Count convention", marketConventions.FixedDayCountConvention.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FixedFrequencyState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Fixed frequency", marketConventions.FixedFrequency.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FloatingBusinessDayConventionState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Floating Business day convention", marketConventions.FloatingBusinessDayConvention.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FloatingDayCountConventionState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Floating Day Count convention", marketConventions.FloatingDayCountConvention.Name);
         //}
         //if ((userMarketConventionInput == null) || (userMarketConventionInput.FloatingFrequencyState != ConventionState.UserInput))
         //{
         //    logger.Add_Info_StandardValue("Floating frequency", marketConventions.FloatingFrequency.Name);
         //}
     }
 }