/// <summary>
        /// Constructor for the default logic behind all Shepherds.
        /// </summary>
        /// <param name="AYamlFile">Full path to the Shepherd's YAML Definition file.</param>
        /// <param name="APetraShepherdForm"></param>
        public TPetraShepherdFormLogic(string AYamlFile, IPetraShepherdConcreteFormInterface APetraShepherdForm)
        {
            TLogging.Log(
                "Entering TPetraShepherdFormLogic Constructor. AYamlFile = " + AYamlFile + "; APetraShepherdForm = " +
                APetraShepherdForm.ToString() +
                "...");

            FForm = APetraShepherdForm;

            //// Take AYamlFile and parse it into an XmlNode structure

            ParseYAMLFileElements(AYamlFile);

            FShepherdPages = new TPetraShepherdPagesList(AYamlFile);

            SwitchToStartPage();

            TLogging.Log("The TPetraShepherdFormLogic constructor has switched to the first page.");

            // Iterate over all FPetraShepherdPages and add the VisibleOrEnabledChangedEventHandler

            //// FShepherdPages needs to get added an auto-generated TPetraShepherdFinishPage
            //// for the Finish Page (that is not specified in the YAML file!)
            //// Note: That Finish Page (and only this) will have IsLastPage = true!!!


            TLogging.Log(
                "TPetraShepherdFormLogic Constructor ran and returned to the TPetraShepherdFormLogic constructor in PetraShepherdConcreteForm.");
        }
Exemple #2
0
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="AYamlFile">Full path to the Shepherd's YAML Definition file.</param>
        /// <param name="APetraShepherdForm">An instance of TPetraShepherdConcreteForm.</param>
        public TShepherdChurchFormLogic(string AYamlFile, IPetraShepherdConcreteFormInterface APetraShepherdForm) : base(AYamlFile,
                                                                                                                         APetraShepherdForm)
        {
            TLogging.Log(
                "Entering TShepherdChurchFormLogic Constructor. AYamlFile = " + AYamlFile + "; APetraShepherdForm = " +
                APetraShepherdForm.ToString() +
                "...");

            TLogging.Log("TShepherdChurchFormLogic Constructor ran.");
        }
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="AYamlFile">Full path to the Shepherd's YAML Definition file.</param>
        /// <param name="APetraShepherdForm">An instance of TPetraShepherdConcreteForm.</param>
        public TShepherdChurchFormLogic(string AYamlFile, IPetraShepherdConcreteFormInterface APetraShepherdForm) : base(AYamlFile,
                                                                                                                        APetraShepherdForm)
        {
            TLogging.Log(
                "Entering TShepherdChurchFormLogic Constructor. AYamlFile = " + AYamlFile + "; APetraShepherdForm = " +
                APetraShepherdForm.ToString() +
                "...");

            TLogging.Log("TShepherdChurchFormLogic Constructor ran.");
        }
        /// <summary>
        /// Constructor for the default logic behind all Shepherds.
        /// </summary>
        /// <param name="AYamlFile">Full path to the Shepherd's YAML Definition file.</param>
        /// <param name="APetraShepherdForm"></param>
        public TPetraShepherdFormLogic(string AYamlFile, IPetraShepherdConcreteFormInterface APetraShepherdForm)
        {
            TLogging.Log(
                "Entering TPetraShepherdFormLogic Constructor. AYamlFile = " + AYamlFile + "; APetraShepherdForm = " +
                APetraShepherdForm.ToString() +
                "...");

            FForm = APetraShepherdForm;

            //// Take AYamlFile and parse it into an XmlNode structure

            ParseYAMLFileElements(AYamlFile);

            FShepherdPages = new TPetraShepherdPagesList(AYamlFile);

            SwitchToStartPage();

            TLogging.Log("The TPetraShepherdFormLogic constructor has switched to the first page.");

            // Iterate over all FPetraShepherdPages and add the VisibleOrEnabledChangedEventHandler

            //// FShepherdPages needs to get added an auto-generated TPetraShepherdFinishPage
            //// for the Finish Page (that is not specified in the YAML file!)
            //// Note: That Finish Page (and only this) will have IsLastPage = true!!!


            TLogging.Log(
                "TPetraShepherdFormLogic Constructor ran and returned to the TPetraShepherdFormLogic constructor in PetraShepherdConcreteForm.");
        }