Beispiel #1
0
        public SessionData(
			int idSession,
			bool bIsPreTaxOnlyOperation,
			AtCalculationSession acs,
			List<PpaCalendar> calendarEntries,
			IFeedback hLogger)
        {
            m_idSession = idSession;
            m_gcFeedback = hLogger;

            Utility.clearCalendarData();
            m_pCalendar = Utility.m_calendar_data;

            FillCalendar(calendarEntries);

            m_pCalc = new CalcData();

            m_pCalc.m_bPreTaxCalculationsOnly = bIsPreTaxOnlyOperation;
            m_pCalc.m_calculation_id = idSession;
            m_pCalc.m_calc_from_date = acs.AtCalcYearmonthStart;
            m_pCalc.m_calc_to_date = acs.AtCalcYearmonthEnd;
            m_pCalc.m_bDataFilled = FillData(acs);

            Debug.IndentSize = 4;
            Debug.AutoFlush = true;

            g_hSessionData = this;
        }
Beispiel #2
0
        public static bool CalculatePerformance(
            SessionData session, 
            CalcData pCalc, 
            IFeedback feedback)
        {
            var bComplete = false;

            //calculate the drift weights
            var objDriftCalculator = new DriftCalculator(feedback);
            if (objDriftCalculator.calculateDriftWeights(pCalc))
            {
                var objCoreAccountsPerformance = new CoreAccountsPerformance(feedback);
                if (objCoreAccountsPerformance.calculateCoreAccountPerformance(pCalc))
                {
                    FixedIncome.PrepareFixedIncomeBenchPerformance(session);

                    var objSimulatedBenchmark = new SimulatedBenchmark(feedback);
                    if (objSimulatedBenchmark.calculateSimulatedBenchMarkData(session, pCalc))
                    {
                        // Do after-tax calculations if needed
                        if (!(pCalc.m_bPreTaxCalculationsOnly))
                        {
                            var objATReturns = new Returns(feedback);
                            bComplete = objATReturns.calculateATReturns(pCalc);
                        }
                        else
                        {
                            bComplete = true;
                        }

                        FixedIncome.PrepareFixedIncomeMonthReturns(session);
                    }
                }
            }

            return bComplete;
        }
Beispiel #3
0
 public bool calculateSimulatedBenchMarkData(SessionData session, CalcData pCalc)
 {
     return true;
 }