Exemple #1
0
        }         // ReportDateStr

        private void UpdateCurrentReportDate()
        {
            Log.Debug("UpdateCurrentReportDate('{0}') started...", ReportDateStr);

            SortedDictionary <string, CountryData> oRawByCountry = m_oApp.FetchByCountry(m_oReportDate, m_oReportDate);
            SortedDictionary <PageID, int>         oRawByPage    = m_oApp.FetchByPage();

            var oStats = new SortedDictionary <string, int>();

            m_oApp.ProcessByCountry(oRawByCountry, oStats);

            m_oApp.ProcessByPage(oRawByPage, oStats);

            SaveStats(oStats, "by country and by page");

            SaveStats(m_oApp.FetchBySource(), "by source");

            SaveStats(m_oApp.FetchByLandingPage(), "by landing page");

            Log.Debug("UpdateCurrentReportDate('{0}') complete.", ReportDateStr);
        }         // UpdateCurrentReportDate
Exemple #2
0
        private static void Run(GoogleAnalytics app)
        {
            Log.Debug("Program.Run started...");

            var oRawByCountry = app.FetchByCountry(m_oReportDate, m_oReportDate);
            var oRawByPage    = app.FetchByPage();

            var oStats = new SortedDictionary <string, int>();

            app.ProcessByCountry(oRawByCountry, oStats);

            app.ProcessByPage(oRawByPage, oStats);

            SaveStats(oStats);

            var sourceStats = app.FetchBySource();

            SaveStats(sourceStats);

            var landingPageStats = app.FetchByLandingPage();

            SaveStats(landingPageStats);
            Log.Debug("Program.Run complete.");
        }         // Run