Ejemplo n.º 1
0
        FileDetails LoadIntro()
        {
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 1. Intro</b><p/>");
            }
            if (_morning)
            {
                //string filebase = string.Format("{0}.{1}", _base, _baseName[PrayerSect.Intro]);
                //string filename = string.Format("{0}.{1}", filebase, _fileEnd);

                string filenamePart2 = string.Format("{0}.{1}", _baseName[PrayerSect.Intro], _fileEnd);
                fileDetails.Add(base.LoadIntro(filenamePart2));                                                 // Load 1.Intro.morning/evening_opening.txt
                string filename = string.Format("{0}.{1}", _base, filenamePart2);
                fileDetails.Add(LoadFile(filename, PrayerSect.Intro));
            }
            else
            {
                fileDetails.Add(base.LoadIntro(""));                                                 // Load 1.Intro.morning/evening_opening.txt
            }

            return(fileDetails);
        }
Ejemplo n.º 2
0
        override protected FileDetails LoadPraise()
        {
            string filebase = string.Format("{0}.{1}", _base, _baseName[PrayerSect.Praise]);
            //string fileEnd = string.Format("ordinary{0}.{1}{2}.txt", _week,_sectionOfDay, _dayNo);

            string filename = "";

            if (_dayInMonth >= 17 && _month == 12 && _dayNo != "1")
            {
                filename = string.Format("{0}.opening_hymn._17_31Dec.{1}.txt", filebase, _sectionOfDay);
            }
            else
            {
                filename = string.Format("{0}.opening_hymn.{1}", filebase, _fileEnd);
            }
            //string text = LoadFile(filename);
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 2. Praise</b><p/>");
            }
            fileDetails.Add(LoadFile(filename, PrayerSect.Praise));

            int weekNo = Int32.Parse(_weekNo) % 4;

            if (weekNo == 0)
            {
                weekNo = 4;
            }
            string fileEnd        = string.Format("advent{0}.{1}{2}.txt", weekNo, _sectionOfDay, _dayNo);
            string psalmsFilename = string.Format("{0}.psalms.{1}", filebase, fileEnd);

            //fileEnd = string.Format("_17_31Dec.{1}{2}.txt", filebase, _sectionOfDay, _dayNo);
            if (_dayInMonth >= 17 && _month == 12)
            {
                //fileEnd = string.Format("_17_31Dec.{0}{1}.txt", _sectionOfDay, _dayNo);
                if (_dayNo != "1")
                {
                    fileEnd = string.Format("_17_31Dec.week{0}.{1}{2}.txt", weekNo, _sectionOfDay, _dayNo);
                }
                else
                {
                    fileEnd = string.Format("_17_31Dec.{0}_Dec_{1}.txt", _dayInMonth, _sectionOfDay);
                }
            }

            else
            {
                fileEnd = _fileEnd;
            }

            string refrainsFilename = string.Format("{0}.refrains.{1}", filebase, fileEnd);

            fileDetails.Add(LoadRefrainAndPsalms(refrainsFilename, psalmsFilename));

            return(fileDetails);
        }
Ejemplo n.º 3
0
        FileDetails LoadIntro()
        {
            //am/pm opening, am psalm, am refrain.
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 1. Intro</b><p/>");
            }
            if (_morning)
            {
                String filenamePart2 = string.Format("{0}.advent.morning.txt", _baseName[PrayerSect.Intro]);
                fileDetails.Add(base.LoadIntro(filenamePart2));                                                 // Load 1.Intro.morning/evening_opening.txt
                string filename = string.Format("{0}.{1}", _base, filenamePart2);
                fileDetails.Add(LoadFile(filename, PrayerSect.Intro));
            }

            return(fileDetails);
        }
Ejemplo n.º 4
0
        override protected FileDetails LoadPraise()
        {
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 2. Praise</b><p/>");
            }
            string filebase = string.Format("{0}.{1}", _base, _baseName[PrayerSect.Praise]);

            string openHymnFilename = string.Format("{0}.opening_hymn.{1}", filebase, _fileEnd);
            string psalmsFilename   = string.Format("{0}.psalms.{1}", filebase, _psalmEnd);
            string refrainsFilename = string.Format("{0}.refrains.{1}", filebase, _refrainEnd);

            System.Diagnostics.Debug.WriteLine($"{_Tag}.LoadPraise({openHymnFilename}, \n\t\t{psalmsFilename}, \n\t\t{refrainsFilename})");

            fileDetails.Add(LoadFile(openHymnFilename, PrayerSect.Praise));
            fileDetails.Add(LoadRefrainAndPsalms(refrainsFilename, psalmsFilename));

            return(fileDetails);
        }
Ejemplo n.º 5
0
        protected override FileDetails LoadPraise()
        {
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 2. Praise</b><p/>");
            }

            string filebase = string.Format("{0}.{1}", _base, _baseName[PrayerSect.Praise]);

            string filename = string.Format("{0}.opening_hymn.{1}.txt", filebase, _sectionOfDay);       // just morning/evening here

            fileDetails.Add(LoadFile(filename, PrayerSect.Praise));
            string psalmsFilename   = string.Format("{0}.psalms.{1}", filebase, _fileEnd);
            string refrainsFilename = string.Format("{0}.refrains.{1}", filebase, _fileEnd);

            fileDetails.Add(LoadRefrainAndPsalms(refrainsFilename, psalmsFilename));

            return(fileDetails);
        }
Ejemplo n.º 6
0
        protected override FileDetails LoadPraise()
        {
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 2. Praise</b><p/>");
            }
            if (_weekNo == "7" && _dayNo == "1" && _morning)
            {
                // This Ascending morning opening is actually a special refrain for the Sunday when we celebrate Jesus ascending to Heaven.
                // This feast takes place on the 7th Sunday of Easter.
                fileDetails.Add(SundayOfJesusAscending());
            }
            else
            {
                fileDetails.Add(base.LoadPraise());
            }

            return(fileDetails);
        }
Ejemplo n.º 7
0
        FileDetails LoadIntro()
        {
            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 1. Intro</b><p/>");
            }
            if (_morning)
            {
                string filenamePart2 = string.Format("{0}.ordinary{1}.refrain{2}.txt", _baseName[PrayerSect.Intro], _week, _dayNo);
                fileDetails.Add(base.LoadIntro(filenamePart2));                                                 // Load 1.Intro.morning/evening_opening.txt
                string filename = string.Format("{0}.{1}", _base, filenamePart2);
                fileDetails.Add(LoadFile(filename, PrayerSect.Intro));
            }
            else
            {
                fileDetails.Add(base.LoadIntro(""));
            }

            return(fileDetails);
        }
Ejemplo n.º 8
0
        override protected FileDetails LoadResponse()
        {
            string filename = "";

            if (_dayInMonth >= 17 && _month == 12 && _dayNo != "1")
            {
                filename = string.Format("{0}.{1}._17_31Dec.{2}.txt", _base, _baseName[PrayerSect.Response], _sectionOfDay);
            }
            else
            {
                filename = string.Format("{0}.{1}.{2}", _base, _baseName[PrayerSect.Response], _fileEnd);
            }

            FileDetails fileDetails = new FileDetails();

            if (_testMode)
            {
                fileDetails.AddText($"<p/><b>{_Tag} - 3. Response</b><p/>");
            }
            fileDetails.Add(LoadFile(filename, PrayerSect.Response));

            return(fileDetails);
        }