Exemple #1
0
        //────────────────────────────────────────

        /// <summary>
        /// このデータは、ファイルパス型だ、と想定して、ファイルパスを取得します。
        /// </summary>
        /// <returns></returns>
        public Expression_Node_Filepath Execute4_OnExpressionString_AsFilepath(
            EnumHitcount request,
            Log_Reports log_Reports
            )
        {
            return(Expression_Node_StringImpl.Execute4_OnExpressionString_AsFilepath_Impl(this, request, log_Reports));
        }
Exemple #2
0
 /// <summary>
 /// 属性。
 /// </summary>
 /// <param name="out_E_Result">検索結果。</param>
 /// <param name="sName"></param>
 /// <param name="bRequired"></param>
 /// <param name="hits"></param>
 /// <param name="log_Reports"></param>
 /// <returns>検索結果が1件以上あれば真。</returns>
 public bool TrySelectAttribute(
     out Expression_Node_String ec_Result_Out,
     string sName,
     EnumHitcount hits,
     Log_Reports log_Reports
     )
 {
     // 使いません。
     ec_Result_Out = new Expression_Node_StringImpl(this, this.Cur_Configuration);
     return(false);
 }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolCheckbox uctChk = new UsercontrolCheckbox();

            // 名前だけ初期設定
            uctChk.ControlCommon.Expression_Name_Control = ec_FcName;
            uctChk.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctChk;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolTabPage uctTpg = new UsercontrolTabPage();

            // 名前だけ初期設定
            uctTpg.Expression_Name_Control = ec_FcName;
            uctTpg.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctTpg;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolPanel uctPnl = new UsercontrolPanel();

            // 名前だけ初期設定
            uctPnl.Expression_Name_Control = ec_FcName;
            uctPnl.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctPnl;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolButton uctBtn = new UsercontrolButton();

            // 名前だけ初期設定
            uctBtn.Expression_Name_Control = ec_FcName;
            uctBtn.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctBtn;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolNumericUpDown uctNum = new UsercontrolNumericUpDown();

            // 名前だけ初期設定
            uctNum.Expression_Name_Control = ec_FcName;
            uctNum.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctNum;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolArea uctAra = new UsercontrolArea();

            // 名前だけ初期設定
            uctAra.Expression_Name_Control = ec_FcName;
            uctAra.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctAra;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolWindow uctWnd = new UsercontrolWindow();

            // 名前だけ初期設定
            uctWnd.Expression_Name_Control = ec_FcName;
            uctWnd.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;
            uctWnd.CustomcontrolWindow1.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;//.CenterParent;

            return uctWnd;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            //
            // ▲▲▲ ※暫定で テキストボックス
            //
            UsercontrolTextbox uctTxt = new UsercontrolTextbox();

            // 名前だけ初期設定
            uctTxt.Expression_Name_Control = ec_FcName;
            uctTxt.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctTxt;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            //
            // 既に起動されているウィンドウに、パネルを埋め込む指定です。
            //

            UsercontrolTextbox uctTxt = new UsercontrolTextbox();

            // 名前だけ初期設定
            uctTxt.Expression_Name_Control = ec_FcName;
            uctTxt.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctTxt;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            //
            // 既に起動されているウィンドウに、パネルを埋め込む指定です。
            //

            // パネルとして作成します。
            UsercontrolPanel uctPnl = new UsercontrolPanel();
            //ucPanel.BackColor = Color.Transparent;

            // 名前だけ初期設定
            uctPnl.Expression_Name_Control = ec_FcName;
            uctPnl.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            return uctPnl;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolTextbox uctTxt = new UsercontrolTextbox();

            // 名前だけ初期設定
            uctTxt.Expression_Name_Control = ec_FcName;
            uctTxt.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            //
            // 複数行入力のテキストボックスに設定することで、
            // テキストエリアになります。
            //
            uctTxt.Multiline = true;
            uctTxt.UsercontrolScrollbars = ScrollBars.Both;

            return uctTxt;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_Name_Control,
            MemoryApplication owner_MemoryApplication
            )
        {
            UsercontrolListbox uctLst = new UsercontrolListbox();

            // 名前だけ初期設定
            uctLst.Expression_Name_Control = ec_Name_Control;
            uctLst.ControlCommon.Owner_MemoryApplication = owner_MemoryApplication;

            // E_Action08、E_Action26 の内容をここに移動。
            {
                // 動作
                uctLst.ListboxItemDrawer = new ListboxItemDrawer_01Impl(owner_MemoryApplication);

                // リストボックスの表示を自作します。項目の高さが固定の場合。
                uctLst.DrawMode = DrawMode.OwnerDrawFixed;
            }

            return uctLst;
        }
        //────────────────────────────────────────
        public Usercontrol Perform(
            Expression_Node_StringImpl ec_FcName,
            MemoryApplication moApplication
            )
        {
            UsercontrolListbox uctLst = new UsercontrolListbox();

            // 名前だけ初期設定
            uctLst.Expression_Name_Control = ec_FcName;
            uctLst.ControlCommon.Owner_MemoryApplication = moApplication;

            //
            // 項目に色を付けるなどの機能に、変更。
            //
            {
                uctLst.ListboxItemDrawer = new ListboxItemDrawer_03Impl(moApplication);
                // リストボックスの表示を自作します。項目の高さが固定の場合。
                uctLst.DrawMode = DrawMode.OwnerDrawFixed;
            }

            return uctLst;
        }
        //────────────────────────────────────────
        /// <summary>
        /// プロジェクト読取り時の定形アクション実行。
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="st_PrevProjectElm_OrNull"></param>
        /// <param name="bProjectValid"></param>
        /// <param name="log_Reports"></param>
        public override string Execute5_Main(Log_Reports log_Reports)
        {
            //()メソッド開始
            Log_Method log_Method = new Log_MethodImpl(1);
            log_Method.BeginMethod(Info_Functions.Name_Library, this, "Execute5_Main",log_Reports);

            //
            if (log_Method.CanDebug(1))
            {
                log_Method.WriteDebug_ToConsole("「プロジェクト選択時」用のイベントハンドラーを実行します。");
            }

            //()タスク_デスクリプション
            {
                string sFncName0;
                this.TrySelectAttribute(out sFncName0, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                if (this.Functionparameterset.Sender is Customcontrol)
                {
                    Customcontrol ccFc = (Customcontrol)this.Functionparameterset.Sender;
                    string sName_Usercontrol = ccFc.ControlCommon.Expression_Name_Control.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);
                    log_Reports.Comment_EventCreationMe += "/追加:[" + sName_Usercontrol + "]コントロールが、[" + sFncName0 + "]アクションを実行。";
                }
                else
                {
                    log_Reports.Comment_EventCreationMe += "/追加:[" + sFncName0 + "]アクションを実行。";
                }
            }

            Configurationtree_Node conf_ThisMethod = new Configurationtree_NodeImpl(log_Method.Fullname, null);

            if (this.EnumEventhandler == EnumEventhandler.Editor_B_Lr)
            {
                //(4)独自モデルの取得
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(4)独自モデルの取得");
                }
                //
                this.On_P04_ReadNewModel(log_Reports);

                //(5)エディター名。ツール設定ファイルに記載されている方。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(5)エディター名。ツール設定ファイルに記載されている方。");
                }

                // 表示用の名称。
                string sName_SelectingEditor;
                if (this.Functionparameterset.SelectedProjectElement_Configurationtree == null)
                {
                    //
                    // 切り替えるプロジェクトが判明していない場合は、空文字列。
                    //
                    sName_SelectingEditor = "";
                }
                else
                {
                    //
                    // todo: エディター設定ファイルの方のエディター名を入れても意味ないのでは?
                    //
                    sName_SelectingEditor = ((MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree).Name;
                }

                //(6)まず、きれいさっぱり プロジェクトをクリアーします。(切替用)
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(6)まず、きれいさっぱり プロジェクトをクリアーします。(切替用)");
                }
                // todo:イベントハンドラーを外してから、フォームを外すこと。リストボックスが誤挙動を起こしている。
                this.On_P06_ClearProject(this.Functionparameterset.Sender, log_Reports);

                //(7)「Aa_Editor.xml」読取。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(7)「Aa_Editor.xml」読取。");
                }
                //
                if (!this.Functionparameterset.IsProjectValid || this.Functionparameterset.SelectedProjectElement_Configurationtree == null)
                {
                    MemoryAatoolxml_Editor moAatoolxml_PrevEditorElm_OrNull = null;

                    //
                    //
                    //
                    // デフォルト・プロジェクト名が指定されていない場合、
                    // ツール設定ファイルの最初に記述されているプロジェクトを選択します。
                    //
                    //
                    //
                    if (log_Reports.Successful)
                    {
                        if ("" == sName_SelectingEditor)
                        {
                            //
                            // デフォルト・エディター名が未指定の場合。
                            //
                            MemoryAatoolxml_Editor moAatoolxml_DefaultEditor = this.Owner_MemoryApplication.MemoryAatoolxml.GetDefaultEditor(true, log_Reports);
                            if (!log_Reports.Successful)
                            {
                                // 既エラー。
                                goto gt_EndMethod;
                            }

                            // ↓これ要る?
                            sName_SelectingEditor = moAatoolxml_DefaultEditor.Name;
                        }
                    }

                    this.On_P07_SelectDefaultProject(ref sName_SelectingEditor, ref moAatoolxml_PrevEditorElm_OrNull, this.Functionparameterset.IsProjectValid, log_Reports);

                    this.Functionparameterset.SelectedProjectElement_Configurationtree = moAatoolxml_PrevEditorElm_OrNull;

                    //
                    //
                    //
                    //「プロジェクトを開いた時の初期化」イベントハンドラーで使うために、ここで設定します。
                    //
                    //
                    //
                    this.Functionparameterset.SelectedProjectElement_Configurationtree = this.Owner_MemoryApplication.MemoryAatoolxml.GetEditorByName(sName_SelectingEditor, true, log_Reports);
                    if (!log_Reports.Successful)
                    {
                        // 既エラー。
                        goto gt_EndMethod;
                    }
                }

                // ↓追加
                if (null == this.Functionparameterset.SelectedProjectElement_Configurationtree)
                {
                    {
                        Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                        tmpl.SetParameter(1, sName_SelectingEditor, log_Reports);//エディター名

                        this.Owner_MemoryApplication.CreateErrorReport("Er:110003;", tmpl, log_Reports);
                    }
                }
                // ↑追加

                //(13a)エディター・フォルダー。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(13a)エディター・フォルダーパス類推。");
                }
                //
                //
                //
                Expression_Node_Filepath ec_Fopath_Editor;
                if (log_Reports.Successful)
                {
                    MemoryAatoolxml_Editor moAatoolxml_SelectedEditor = (MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree;
                    ec_Fopath_Editor = moAatoolxml_SelectedEditor.GetFilepathByFsetvarname(
                        NamesVar.S_SP_EDITOR,
                        this.Owner_MemoryApplication.MemoryVariables,
                        true,
                        log_Reports
                        );
                }
                else
                {
                    ec_Fopath_Editor = null;
                }

                //(13b)「Aa_Editor.xml」読取。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(13b)「Aa_Editor.xml」ファイルパス類推。");
                }
                //
                Expression_Node_Filepath ec_Fpath_AaEditorXml;
                if (log_Reports.Successful)
                {

                    //
                    // ツール設定ファイルで指定された値から、自動類推で設定されているはず。
                    //
                    Configurationtree_NodeFilepath cf_Fpath_EditorXml = new Configurationtree_NodeFilepathImpl(
                        "ツール設定ファイル[" + Application.StartupPath + System.IO.Path.DirectorySeparatorChar + ValuesAttr.S_FPATHR_AATOOLXML + "]の中の[" + sName_SelectingEditor + "]エディターへの指定から自動類推",
                        null);

                    // フォルダーパス + \Aa_Editor.xml
                    string sFpatha_Aaeditorxml = ec_Fopath_Editor.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports) + System.IO.Path.DirectorySeparatorChar + NamesFile.S_AA_EDITOR_XML;

                    // プロジェクト起動時に。
                    cf_Fpath_EditorXml.InitPath(
                        sFpatha_Aaeditorxml,
                        log_Reports
                        );
                    ec_Fpath_AaEditorXml = new Expression_Node_FilepathImpl(cf_Fpath_EditorXml);
                }
                else
                {
                    ec_Fpath_AaEditorXml = null;
                }

                //(8)「エディター設定ファイル」に記述されている<f-set-var>要素を、「エディター設定ファイル・モデル」に格納。Cf→M
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(8)「エディター設定ファイル」に記述されている<f-set-var>要素を、「エディター設定ファイル・モデル」に格納。Cf→M。この時点で「Sp:Engine;」といったシステム変数は自動類推が終わっている必要があります。");
                }
                //
                MemoryAaeditorxml_Editor moAaeditorxml_Editor = null;
                if (log_Reports.Successful)
                {
                    this.On_P08_SpToVar_(
                        out moAaeditorxml_Editor,
                        ec_Fpath_AaEditorXml,
                        ec_Fopath_Editor,
                        (MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree,
                        log_Reports
                        );
                }

                //
                //
                //
                // ここで「Aa_Files.csv」を読み込みたい。
                //
                //
                //

                if (log_Reports.Successful)
                {
                    //(9)変数ファイル読取
                    if (log_Method.CanDebug(1))
                    {
                        log_Method.WriteDebug_ToConsole("(9)変数ファイル読取");
                    }
                    //
                    this.Owner_MemoryApplication.MemoryVariables.LoadVariables(
                        Application.StartupPath,
                        log_Reports
                        );
                }

                if (log_Reports.Successful)
                {
                    //(10)プログラマー用・デバッグモードのON/OFF。
                    if (log_Method.CanDebug(1))
                    {
                        log_Method.WriteDebug_ToConsole("(10)プログラマー用・デバッグモードのON/OFF。");
                    }
                    //
                    //mainWndの作成より先に設定する必要がある。ステータスバーを出す、出さないについて。
                    {
                        Expression_Leaf_StringImpl ec_Varname = new Expression_Leaf_StringImpl(this, this.Cur_Configuration.Parent);
                        ec_Varname.SetString(NamesVar.S_SS_DEBUGMODE_PROGRAMMER, log_Reports);
                        string sValue = this.Owner_MemoryApplication.MemoryVariables.GetStringByVariablename(ec_Varname, false, log_Reports);
                        if (ValuesAttr.S_ON == sValue)
                        {
                            Log_ReportsImpl.BDebugmode_Static = true;
                        }
                        else if (ValuesAttr.S_OFF == sValue)
                        {
                            Log_ReportsImpl.BDebugmode_Static = false;
                        }
                        else if (ValuesAttr.S_EMPTY == sValue)
                        {
                            // 無視
                        }
                        else
                        {
                            // TODO:エラー
                        }
                    }
                }

                if (log_Reports.Successful)
                {
                    //(11)画面レイアウト・デバッグモードのON/OFF。
                    if (log_Method.CanDebug(1))
                    {
                        log_Method.WriteDebug_ToConsole("(11)フォーム・デバッグモードのON/OFF。");
                    }
                    //
                    Expression_Leaf_StringImpl ec_Varname = new Expression_Leaf_StringImpl(this, this.Cur_Configuration.Parent);
                    ec_Varname.SetString(NamesVar.S_SS_DEBUGMODE_FORM, log_Reports);
                    string sValue = this.Owner_MemoryApplication.MemoryVariables.GetStringByVariablename(ec_Varname, false, log_Reports);
                    if (ValuesAttr.S_ON == sValue)
                    {
                        Log_ReportsImpl.BDebugmode_Form = true;
                    }
                    else if (ValuesAttr.S_OFF == sValue)
                    {
                        Log_ReportsImpl.BDebugmode_Form = false;
                    }
                    else if (ValuesAttr.S_EMPTY == sValue)
                    {
                        // 無視
                    }
                    else
                    {
                        // TODO:エラー
                    }
                }

                //(14)「Aa_Files.csv」読取。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(14)「Aa_Files.csv」読取。");
                }
                //
                List<Expression_Node_Filepath> ecList_Fpath_BackupRequest;
                {
                    if (log_Reports.Successful)
                    {
                        // 正常時

                        Expression_Node_Function function_Expr = Collection_Function.NewFunction2(
                                Expression_Node_Function22Impl.NAME_FUNCTION, this, this.Cur_Configuration,
                                this.Owner_MemoryApplication, log_Reports);

                        // 実行
                        function_Expr.Execute4_OnLr(this.Functionparameterset.Sender, log_Reports);

                        // 実行後
                        ecList_Fpath_BackupRequest = ((Expression_Node_Function22Impl)function_Expr).List_Expression_Filepath_BackupRequest_Out;
                    }
                    else
                    {
                        //
                        // エラー
                        //

                        ecList_Fpath_BackupRequest = null;
                    }
                }

                //(14b)ユーザー定義関数設定ファイル読取【2012-03-30追加】
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(14b)ユーザー定義関数設定ファイル読取【2012-03-30追加】");
                }
                //
                if (log_Reports.Successful)
                {
                    // タイプデータ値。
                    Expression_Leaf_StringImpl ec_NameVariable = new Expression_Leaf_StringImpl(this, new Configurationtree_NodeImpl("!ハードコーディング",null));
                    ec_NameVariable.SetString(ValuesTypeData.S_CODE_FUNCTIONS, log_Reports);

                    List<MemoryCodefileinfo> listInfo = null;
                    if (log_Reports.Successful)
                    {
                        listInfo = this.Owner_MemoryApplication.MemoryCodefiles.GetCodefileinfoByTypedata(ec_NameVariable, true, log_Reports);
                    }

                    if (log_Reports.Successful)
                    {
                        foreach (MemoryCodefileinfo scriptfile in listInfo)
                        {
                            if (log_Reports.Successful)
                            {
                                this.Owner_MemoryApplication.MemoryFunctions.LoadFile(
                                    scriptfile.Expression_Filepath,
                                    log_Reports);

                            }
                            else
                            {
                                break;
                            }
                        }
                    }

                }

                //(16)『スタイルシート設定ファイル』読取
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(16)『スタイルシート設定ファイル』読取");
                }
                //
                if (log_Reports.Successful)
                {
                    Expression_Node_Function expr_Func = Collection_Function.NewFunction2(
                        Expression_Node_Function19Impl.NAME_FUNCTION, this, this.Cur_Configuration,
                        this.Owner_MemoryApplication, log_Reports);

                    Expression_Node_StringImpl ec_Str = new Expression_Node_StringImpl(this, conf_ThisMethod);
                    ec_Str.AppendTextNode(NamesVar.S_ST_STYLESHEET, this.Cur_Configuration, log_Reports);

                    expr_Func.SetAttribute(Expression_Node_Function19Impl.PM_NAME_TABLE_STYLESHEET, ec_Str, log_Reports);

                    expr_Func.Execute4_OnLr(
                        this.Functionparameterset.Sender,
                        log_Reports
                        );
                }

                //(17a)「バックアップを取る」前にしておく独自実装をするタイミング。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(17a)「バックアップを取る」前にしておく独自実装をするタイミング。");
                }
                //
                this.On_P17a_PreviousBackup(
                    this.Functionparameterset.Sender,
                    moAaeditorxml_Editor,
                    ec_Fpath_AaEditorXml,
                    ec_Fopath_Editor,
                    (MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree,
                    log_Reports);

                //(17b)今日の分のバックアップを取ります。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(17b)今日の分のバックアップを取ります。");
                }
                //
                this.On_P17b_DateBackup(ecList_Fpath_BackupRequest, this.Functionparameterset.Sender, log_Reports);

                //(17c)「新規ウィンドウを開く」前にしておく独自実装をするタイミング。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(17c)「新規ウィンドウを開く」前にしておく独自実装をするタイミング。");
                }
                //
                this.On_P17c_PreviousOpenWindow(
                    this.Functionparameterset.Sender,
                    moAaeditorxml_Editor,
                    ec_Fpath_AaEditorXml,
                    ec_Fopath_Editor,
                    (MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree,
                    log_Reports);

                //(18)関数30「新規ウィンドウを開く」実行。引数には関数を2つ指定できる。
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(18)関数30「新規ウィンドウを開く」実行。引数には関数を2つ指定できる。");
                }
                //
                {

                    Expression_Node_Function expr_Func = Collection_Function.NewFunction2(
                            Expression_Node_Function30Impl.NAME_FUNCTION, this, this.Cur_Configuration,
                            this.Owner_MemoryApplication, log_Reports);

                    {
                        //Expression_Node_Function30Impl f1 =

                        {
                            Expression_Node_StringImpl ec_FormStart;
                            {
                                Expression_FvarImpl ec_Fvar = new Expression_FvarImpl(this, this.Cur_Configuration, this.Owner_MemoryApplication);
                                ec_Fvar.AppendTextNode(NamesVar.S_SS_FORM_START, this.Cur_Configuration, log_Reports);

                                ec_FormStart = new Expression_Node_StringImpl(this, this.Cur_Configuration);
                                ec_FormStart.List_Expression_Child.Add(ec_Fvar, log_Reports);
                            }
                            ((Expression_Node_Function30Impl)expr_Func).SetAttribute(Expression_Node_Function30Impl.PM_NAME_FORM, ec_FormStart, log_Reports);
                        }

                        ((Expression_Node_Function30Impl)expr_Func).In_Subroutine_Function30_1 = this.In_Subroutine_Function30_1_OrNull;
                        ((Expression_Node_Function30Impl)expr_Func).In_Subroutine_Function30_2 = this.In_Subroutine_Function30_2_OrNull;
                        ((Expression_Node_Function30Impl)expr_Func).SetAttribute(
                            Expression_Node_Function30Impl.PM_NAME_TOGETHER,
                            new Expression_Leaf_StringImpl(NamesStg.S_STG_BEGIN_APPLICATION, null, conf_ThisMethod), log_Reports);
                    }

                    expr_Func.Execute4_OnLr(
                        this.Functionparameterset.Sender,
                        log_Reports
                        );
                }

                //(19)最後に
                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole("(19)最後に");
                }
                //
                this.On_P19_AtLast(
                    this.Functionparameterset.Sender,
                    (MemoryAatoolxml_Editor)this.Functionparameterset.SelectedProjectElement_Configurationtree,
                    this.Functionparameterset.IsProjectValid,
                    log_Reports);

                //
                // 「S」と「E」を出力したい。
                if (false)
                {
                    // 「S」全てのコントロールと、ユーザー定義関数について。

                    log_Method.WriteInfo_ToConsole("┌──────────┐「S」全てのコントロールについて。");
                    this.Owner_MemoryApplication.MemoryForms.ForEach_Children(delegate(string sKey, Usercontrol fcUc, ref bool bRemove, ref bool bBreak)
                    {
                        Log_TextIndented s = new Log_TextIndentedImpl();
                        s.Append("[" + sKey + "]");
                        s.Newline();
                        fcUc.ControlCommon.Expression_Control.Cur_Configuration.ToText_Content(s);
                        log_Method.WriteInfo_ToConsole(s.ToString());
                    });
                    log_Method.WriteInfo_ToConsole("└──────────┘");

                    log_Method.WriteInfo_ToConsole("┌──────────┐「S」全てのユーザー定義関数について。");
                    this.Owner_MemoryApplication.MemoryFunctions.ForEach_Children(delegate(string sKey, Expression_Node_Function ec_CommonFunction, ref bool bRemove, ref bool bBreak)
                    {
                        Log_TextIndented s = new Log_TextIndentedImpl();
                        s.Append("[" + sKey + "]");
                        s.Newline();
                        ec_CommonFunction.Cur_Configuration.ToText_Content(s);
                        log_Method.WriteInfo_ToConsole(s.ToString());
                    });
                    log_Method.WriteInfo_ToConsole("└──────────┘");

                    // 「E」全てのコントロールと、ユーザー定義関数について。

                    log_Method.WriteInfo_ToConsole("┌──────────┐「E」全てのコントロールについて。");
                    this.Owner_MemoryApplication.MemoryForms.ForEach_Children(delegate(string sKey, Usercontrol fcUc, ref bool bRemove, ref bool bBreak)
                    {
                        Log_TextIndented s = new Log_TextIndentedImpl();
                        s.Append("[" + sKey + "]");
                        s.Newline();
                        fcUc.ControlCommon.Expression_Control.ToText_Snapshot(s);
                        log_Method.WriteInfo_ToConsole(s.ToString());
                    });
                    log_Method.WriteInfo_ToConsole("└──────────┘");

                    log_Method.WriteInfo_ToConsole("┌──────────┐「E」全てのユーザー定義関数について。");
                    this.Owner_MemoryApplication.MemoryFunctions.ForEach_Children(delegate(string sKey, Expression_Node_Function ec_CommonFunction, ref bool bRemove, ref bool bBreak)
                    {
                        Log_TextIndented s = new Log_TextIndentedImpl();
                        s.Append("[" + sKey + "]");
                        s.Newline();
                        ec_CommonFunction.ToText_Snapshot(s);
                        log_Method.WriteInfo_ToConsole(s.ToString());
                    });
                    log_Method.WriteInfo_ToConsole("└──────────┘");

                }
                log_Method.WriteInfo_ToConsole("◆起動終了");

                goto gt_EndMethod;
            //
            gt_EndMethod:
                log_Method.EndMethod(log_Reports);
            }

            return "";
        }
        //────────────────────────────────────────
        public override void Translate(
            Configurationtree_Node cur_Cf,//<lookup-id>
            Expression_Node_String parent_Ec,//< Sf:text-template;>
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE",log_Reports);

            if (log_Method.CanDebug(1))
            {
                pg_ParsingLog.Increment("(9)" + cur_Cf.Name);
            }

            //
            //

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_String cur_Ec = new Expression_Node_StringImpl(parent_Ec, cur_Cf);

            //
            //
            //
            // 親へ連結 (value属性)
            //
            //
            //
            {
                //
                // 自要素の value="" 属性を、親へ連結
                //
                PmName pmName = PmNames.S_VALUE;

                string sValue;
                bool bHit = cur_Cf.Dictionary_Attribute.TryGetValue(pmName, out sValue, false, log_Reports);
                if (bHit)
                {

                    cur_Ec.AppendTextNode(
                        sValue,
                        cur_Cf,
                        log_Reports
                        );

                    //
                    //
                    //
                    // 子
                    //
                    //
                    //
                    this.ParseChild_InConfigurationtreeToExpression(
                        cur_Cf,
                        cur_Ec,//自
                        memoryApplication,
                        pg_ParsingLog,
                        log_Reports
                        );

                    //
                    //
                    //
                    // 親へ連結 ※属性連結
                    //
                    //
                    //
                    parent_Ec.SetAttribute(PmNames.S_LOOKUP_ID.Name_Pm, cur_Ec, log_Reports);

                    goto gt_EndMethod;
                }
                else
                {
                }

            }

            //
            //
            //
            // 子
            //
            //
            //
            {
                //<a-default>の子要素を確認し、親<f-switch>のdefault属性に追加します。

                this.ParseChild_InConfigurationtreeToExpression(
                    cur_Cf,
                    cur_Ec,
                    memoryApplication,
                    pg_ParsingLog,
                    log_Reports
                    );
            }

            //
            //
            //
            // 親へ連結
            //
            //
            //
            parent_Ec.SetAttribute(PmNames.S_LOOKUP_ID.Name_Pm, cur_Ec, log_Reports);

            //
            //
            //
            // 親へ連結 debug
            //
            //
            //
            if (log_Method.CanDebug(1))
            {
                string parent_SName_Fnc;
                parent_Ec.TrySelectAttribute(out parent_SName_Fnc, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                log_Method.WriteDebug_ToConsole(" ☆☆☆☆☆☆☆☆ 親<[" + parent_Ec.Cur_Configuration.Name + "] name=”[" + parent_SName_Fnc + "]” >");

                string sName_MyFnc;
                cur_Ec.TrySelectAttribute(out sName_MyFnc, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                log_Method.WriteDebug_ToConsole(" ☆☆☆☆☆☆☆☆ 自<[" + cur_Ec.Cur_Configuration.Name + "] name=”[" + sName_MyFnc + "]” >");
            }

            goto gt_EndMethod;
            //
            //
            gt_EndMethod:
            if (Log_ReportsImpl.BDebugmode_Static)
            {
                pg_ParsingLog.Decrement(cur_Cf.Name);
            }
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        public Expression_Node_String Compile(
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl();
            log_Method.BeginMethod(Info_Syntax.Name_Library, this, "Compile",log_Reports);
            //

            String sTxtTmpl = this.Text;

            Configurationtree_Node parent_Cnf = new Configurationtree_NodeImpl("!ハードコーディング_TextTemplateImpl#Compile", null);
            Expression_Node_StringImpl result = new Expression_Node_StringImpl(null,parent_Cnf);

            int nCur = 0;

            while (nCur < sTxtTmpl.Length)
            {
                int nPreCur = nCur;

                // 開き%記号(open percent)
                int nOp = sTxtTmpl.IndexOf('%', nCur);

                if (nOp != -1)
                {
                    // 開き%記号があった。

                    nCur = nOp + 1;//「開き%」の次へ。

                    // 閉じ%記号(close percent)
                    int cp = sTxtTmpl.IndexOf('%', nCur);

                    if (cp != -1)
                    {
                        // 閉じ%記号があれば。

                        nCur = cp + 1;//「閉じ%」の次へ。

                        // 「%」と「%」の間に数字があるはず。
                        // 「開き%」の次から、「閉じ% - 開き% - 1」文字分。(-1しないと、終了%を含んでしまう)
                        string sMarker = sTxtTmpl.Substring(nOp + 1, cp - nOp - 1);

                        // 「%1%」といった記号の数字部分。
                        int nParameterIndex;

                        try
                        {
                            nParameterIndex = Int32.Parse(sMarker);

                            // 開き「%」までを、まず文字列化。
                            int nPreLen = nOp - nPreCur;
                            string sPre = sTxtTmpl.Substring(nPreCur, nPreLen);
                            result.AppendTextNode(
                                sPre,
                                parent_Cnf,
                                log_Reports
                                );

                            // 引数から値を取得。

                            // %数字%を、Expression化して追加。
                            Expression_TexttemplateP1pImpl expr_P1p = new Expression_TexttemplateP1pImpl(null,parent_Cnf);
                            expr_P1p.NumberP1p = nParameterIndex;
                            expr_P1p.Dictionary_P1p = this.Dictionary_NumberAndValue_Parameter;

                            result.List_Expression_Child.Add(
                                expr_P1p,
                                log_Reports
                                );

                            // 続行。
                        }
                        catch (Exception)
                        {
                            // 数字でないようなら。

                            // 今回の判定は失敗したものとして、残りの長さ全て
                            int nRestLen = sTxtTmpl.Length - nPreCur;

                            result.AppendTextNode(
                                sTxtTmpl.Substring(nPreCur, nRestLen),
                                parent_Cnf,
                                log_Reports
                                );

                            nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                        }
                    }
                    else
                    {
                        // 閉じ%がなければ。

                        // 今回の判定は失敗したものとして、残りの長さ全て
                        int nRestLen = sTxtTmpl.Length - nPreCur;

                        result.AppendTextNode(
                            sTxtTmpl.Substring(nPreCur, nRestLen),
                            parent_Cnf,
                            log_Reports
                            );

                        nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                    }
                }
                else
                {
                    // 開き%がなければ。

                    // 残りの長さ全て
                    int nRestLen = sTxtTmpl.Length - nCur;

                    result.AppendTextNode(
                        sTxtTmpl.Substring(nCur, nRestLen),
                        parent_Cnf,
                        log_Reports
                        );

                    nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                }
            }

            //
            //
            log_Method.EndMethod(log_Reports);
            return result;
        }
        //────────────────────────────────────────
        public override void Translate(
            Configurationtree_Node cur_Cf,
            Expression_Node_String parent_Ec,
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            // throw new Exception(Info_SToE.LibraryName + ":" + this.GetType().Name + "#SToE: このメソッドは廃止方針です。");

            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE",log_Reports);

            if (log_Method.CanDebug(1))
            {
                pg_ParsingLog.Increment("(18)" + cur_Cf.Name);
            }

            //
            //
            //
            //

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_String ec_Value;
            {
                ec_Value = new Expression_Node_StringImpl(parent_Ec, cur_Cf);
                ec_Value.AppendTextNode(
                    cur_Cf.Name,
                    cur_Cf,
                    log_Reports
                    );
            }

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_StringImpl ec_Ap1p = new Expression_Node_StringImpl(parent_Ec, cur_Cf);

            ec_Ap1p.SetAttribute(
                PmNames.S_NAME.Name_Pm,
                ec_Value,
                log_Reports
                );

            StringBuilder sb = new StringBuilder();
            sb.Append("p");
            sb.Append(this.NP1p);
            sb.Append("p");

            //
            //
            //
            // 属性
            //
            //
            //
            parent_Ec.SetAttribute(
                sb.ToString(),
                ((Expression_Node_String)ec_Ap1p),
                log_Reports
                );

            //
            // 子要素
            //
            this.ParseChild_InConfigurationtreeToExpression(
                cur_Cf,
                ec_Ap1p,
                memoryApplication,
                pg_ParsingLog,
                log_Reports
                );

            goto gt_EndMethod;
            //
            //
            //
            //
            gt_EndMethod:
            if (Log_ReportsImpl.BDebugmode_Static)
            {
                pg_ParsingLog.Decrement(cur_Cf.Name);
            }
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        protected void Execute6_Sub(
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_Functions.Name_Library, this, "Execute6_Sub", log_Reports);

            string sFncName0;
            this.TrySelectAttribute(out sFncName0, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);

            if (log_Reports.CanStopwatch)
            {
                log_Method.Log_Stopwatch.Message = "Nアクション[" + sFncName0 + "]実行";
                log_Method.Log_Stopwatch.Begin();
            }

            //
            // 指定された引数から、または、
            // このNAction29要素を含んでいる control要素から、コントロールの名前を取得。
            List<Usercontrol> list_Usercontrol;
            if (log_Reports.Successful)
            {
                // 正常時

                Expression_Node_String ec_Name_Control;

                //
                // コントロール名が指定されていれば、そのコントロール名。
                //
                this.TrySelectAttribute(out ec_Name_Control, Expression_Node_Function29Impl.PM_NAME_CONTROL, EnumHitcount.One_Or_Zero, log_Reports);

                string sName_Control = ec_Name_Control.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);

                if ("" == sName_Control.Trim())
                {
                    //コントロール名が指定されていない場合。
                    //
                    //  ・このシステム関数を含んでいるイベント要素→コントロール要素と辿り、コントロール名を取得。
                    Configuration_Node cf_Event = this.Cur_Configuration.GetParentByNodename(
                        NamesNode.S_EVENT, EnumConfiguration.Unknown, false, log_Reports);

                    if (null != cf_Event)
                    {
                        Configuration_Node owner_Configuration_Control = cf_Event.GetParentByNodename(
                            NamesNode.S_CONTROL1, EnumConfiguration.Tree, true, log_Reports);

                        if (null != (Configurationtree_Node)owner_Configuration_Control)
                        {
                            bool bHit = ((Configurationtree_Node)owner_Configuration_Control).Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_Control, false, log_Reports);

                            if (bHit)
                            {
                                ec_Name_Control = new Expression_Node_StringImpl(this, this.Cur_Configuration);
                                ec_Name_Control.AppendTextNode(
                                    sName_Control,
                                    this.Cur_Configuration,
                                    log_Reports
                                    );
                            }
                        }
                        else
                        {
                            //nFcName_prm = null;
                        }

                    }
                    else
                    {
                        //nFcName_prm = null;
                    }
                }

                //
                // 指定のコントロール
                //
                list_Usercontrol = this.Owner_MemoryApplication.MemoryForms.GetUsercontrolsByName(
                    ec_Name_Control,
                    true,
                    log_Reports
                    );
            }
            else
            {
                list_Usercontrol = new List<Usercontrol>();
            }

            //
            // 妥当性判定を行います。
            //
            if (log_Reports.Successful)
            {
                if (0 < list_Usercontrol.Count)
                {
                    Usercontrol uct = list_Usercontrol[0];
                    uct.JudgeValidity(log_Reports);
                }

                //.WriteLine(this.GetType().Name + "#: ◆ 妥当性判定を行った。");
            }

            if (log_Reports.Successful)
            {
                //
                // 指定のコントロールの内容を、データ・ソースから読取り直して最新表示します。
                //

                if (0 < list_Usercontrol.Count)
                {
                    Usercontrol uct = list_Usercontrol[0];

                    //.WriteLine(this.GetType().Name + "#: ◆ 指定のコントロールに、データのアップデートを指示。");

                    if (uct.ControlCommon.BAutomaticinputting)
                    {
                        // コンピューターにより自動入力されたとき。
                        //essageBox.Show("コンピュータによって自動入力されました。 コントロールID=[" + this.FormObjectId + "]", "デバッグ");
                    }
                    else
                    {
                        // 手入力による更新。

                        uct.UsercontrolToMemory(log_Reports);
                    }
                }

                //.WriteLine(this.GetType().Name + "#: ◆ 指示終了。");

            }

            //
            //
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        public override string Execute5_Main(Log_Reports log_Reports)
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_Functions.Name_Library, this, "Execute5_Main",log_Reports);

            string sFncName0;
            this.TrySelectAttribute(out sFncName0, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);

            if (log_Reports.CanStopwatch)
            {
                log_Method.Log_Stopwatch.Message = "Nアクション[" + sFncName0 + "]実行";
                log_Method.Log_Stopwatch.Begin();
            }

            //
            //

            Expression_Node_String err_Ec_FcName1;
            if (this.EnumEventhandler == EnumEventhandler.O_Lr)
            {

                if (this.Functionparameterset.Sender is Customcontrol)
                {
                    Customcontrol fcCc = (Customcontrol)this.Functionparameterset.Sender;

                    string sName_Usercontrol = fcCc.ControlCommon.Expression_Name_Control.Execute4_OnExpressionString(
                        EnumHitcount.Unconstraint,
                        log_Reports
                        );

                    log_Reports.Comment_EventCreationMe = "[" + sName_Usercontrol + "]コントロールが、[" + sFncName0 + "]アクションを実行。";
                }
                else
                {
                    log_Reports.Comment_EventCreationMe = "[" + sFncName0 + "]アクションを実行。";
                }

                //
                //
                //
                //

                //
                // このNAction29を含んでいるcontrol要素から
                // コントロールの名前を取得。
                Expression_Node_String ec_FcName1;

                //
                // このNAction29要素を含んでいる control要素から、コントロールの名前を取得。
                List<Usercontrol> list_FcUc;
                if (log_Reports.Successful)
                {
                    // 正常時

                    Configuration_Node cf_Event = this.Cur_Configuration.GetParentByNodename(
                        NamesNode.S_EVENT, EnumConfiguration.Unknown, false, log_Reports);

                    if (null != cf_Event)
                    {
                        Configuration_Node owner_Configurationtree_Control = cf_Event.GetParentByNodename(
                            NamesNode.S_CONTROL1, EnumConfiguration.Tree, true, log_Reports);

                        if (null != owner_Configurationtree_Control)
                        {
                            string sName_Usercontrol;
                            ((Configurationtree_Node)owner_Configurationtree_Control).Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_Usercontrol, true, log_Reports);

                            Expression_Node_StringImpl ec_Str = new Expression_Node_StringImpl(this, this.Cur_Configuration);
                            ec_Str.AppendTextNode(
                                sName_Usercontrol,
                                this.Cur_Configuration,
                                log_Reports
                                );

                            ec_FcName1 = ec_Str;
                        }
                        else
                        {
                            ec_FcName1 = null;
                        }

                    }
                    else
                    {
                        ec_FcName1 = null;
                    }

                    //
                    // 指定のコントロール
                    //
                    list_FcUc = this.Owner_MemoryApplication.MemoryForms.GetUsercontrolsByName(
                        ec_FcName1,
                        true,
                        log_Reports
                        );
                }
                else
                {
                    //
                    // エラー。
                    ec_FcName1 = null;
                    list_FcUc = null;
                    err_Ec_FcName1 = ec_FcName1;
                    goto gt_Error_NullFcUc;
                }
                // ここで、fcUc は必ずある。
                Usercontrol fct = list_FcUc[0];

                //
                //
                //
                // View
                //
                //
                //

                // 最初の1個のみ有効。必ずあるとする。
                List<Expression_Node_String> ecList_View = fct.ControlCommon.Expression_Control.SelectDirectchildByNodename(NamesNode.S_VIEW, false, EnumHitcount.One, log_Reports);
                if (!log_Reports.Successful)
                {
                    goto gt_EndMethod;
                }
                Expression_Node_StringImpl ec_View = (Expression_Node_StringImpl)ecList_View[0];

                //
                // O → N は、Fcnfをロードした時点で実行済み。
                if (ec_View.List_Expression_Child.Count < 1)
                {
                    //
                    // エラー。
                    //
                    // このアクションを使うからには、
                    // 必ず<view>の中に子要素がないといけない。
                    err_Ec_FcName1 = ec_FcName1;
                    goto gt_Error_EmptyView;
                }

                object errorRule = null;
                Expression_Node_String err_Ec_DataTarget = null;
                if (log_Reports.Successful)
                {
                    // 正常時

                    ec_View.List_Expression_Child.ForEach(delegate(Expression_Node_String ec_Child, ref bool bRemove, ref bool bBreak)
                    {
                        string sFncName;
                        ec_Child.TrySelectAttribute(out sFncName, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);

                        if (
                            NamesNode.S_FNC == ec_Child.Cur_Configuration.Name &&
                            NamesFnc.S_LISTBOX_LABELS == sFncName
                            )
                        {
                            // <f-list-box-labels>

                            //
                            // fcUc は、必ずリストボックス。
                            if (!(fct is UsercontrolListbox))
                            {
                                //
                                // エラー。
                                goto gt_Error_NotListbox;
                            }

                            UsercontrolListbox uctLst = (UsercontrolListbox)fct;

                            //
                            // リストボックスの表示を自作します。項目の高さが固定の場合。
                            uctLst.DrawMode = DrawMode.OwnerDrawFixed;

                            //
                            // N → Uc

                            //
                            // 描画プログラムの作成。
                            ListboxItemDrawer_02Impl drawer = new ListboxItemDrawer_02Impl(
                                this.Owner_MemoryApplication);

                            //
                            // item-valur-to-variable="" 属性
                            //
                            //if (null == nF11.E_ItemValueToVariable)
                            {
                                // <データ access="to">から取りたい。
                                Expression_Node_String ec_ItemValueToVariable = null;//ソース情報利用

                                List<Expression_Node_String> ecList_DataTarget;
                                {
                                    List<Expression_Node_String> ecList_Data = uctLst.ControlCommon.Expression_Control.SelectDirectchildByNodename( NamesNode.S_DATA, false, EnumHitcount.Unconstraint, log_Reports);
                                    ecList_DataTarget = Utility_Expression_NodeImpl.SelectItemsByPmAsCsv(ecList_Data, PmNames.S_ACCESS.Name_Pm, ValuesAttr.S_TO, false, EnumHitcount.First_Exist, log_Reports);
                                }

                                if (!log_Reports.Successful)
                                {
                                    goto gt_EndMethod2;
                                }
                                Expression_Node_String ec_DataTarget = ecList_DataTarget[0];
                                err_Ec_DataTarget = ec_DataTarget;

                                if (null != ec_DataTarget)
                                {
                                    bool bHit = ec_DataTarget.TrySelectAttribute(
                                        out ec_ItemValueToVariable, PmNames.S_NAME_VAR.Name_Pm, EnumHitcount.One, log_Reports);
                                    if (bHit)
                                    {
                                        drawer.Expression_ValueVariableName = ec_ItemValueToVariable;
                                    }
                                    else
                                    {
                                        // エラー。
                                        goto gt_Error_NullItemValueToVariable;
                                    }
                                }
                                else
                                {
                                    // エラー。
                                    goto gt_Error_NotFoundDataTarget;
                                }
                            }
                            //else
                            //{
                            //    //
                            //    // 変数名設定。
                            //    drawer.Ec_ValueVariableName = nF11.E_ItemValueToVariable;
                            //}

                            //
                            // <fnc name=”Sf:item-label;”>
                            List<Expression_Node_String> ecList_Fnc = ec_Child.SelectDirectchildByNodename(NamesNode.S_FNC, false, EnumHitcount.Unconstraint, log_Reports);
                            ecList_Fnc = Utility_Expression_NodeImpl.SelectItemsByPmAsCsv(ecList_Fnc, PmNames.S_NAME.Name_Pm, NamesFnc.S_ITEM_LABEL2, false, EnumHitcount.First_Exist, log_Reports);
                            if (!log_Reports.Successful)
                            {
                                // エラー。
                                goto gt_EndMethod2;
                            }

                            drawer.Expression_ItemLabel = ecList_Fnc[0];

                            if (log_Reports.Successful)
                            {
                                //
                                // 描画プログラムの変更。
                                uctLst.ListboxItemDrawer = drawer;
                            }

                        }
                        else
                        {
                            errorRule = ec_Child;

                            //
                            // エラー。未定義の<view>。
                            goto gt_Error_UndefinedView;
                        }

                        goto gt_EndMethod2;

                        //
                        //
                        //
                        //

            //
                    // エラー。
                    gt_Error_NotListbox:
                        {
                            Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                            tmpl.SetParameter(1, ec_FcName1.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports), log_Reports);//コントロール名
                            tmpl.SetParameter(2, fct.GetType().Name, log_Reports);//コントロールのクラス名

                            this.Owner_MemoryApplication.CreateErrorReport("Er:110019;", tmpl, log_Reports);
                        }
                        goto gt_EndMethod2;

                    //
                    // エラー。
                    gt_Error_NotFoundDataTarget:
                        {
                            Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                            tmpl.SetParameter(1, ec_FcName1.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports), log_Reports);//コントロール名

                            this.Owner_MemoryApplication.CreateErrorReport("Er:110020;", tmpl, log_Reports);
                        }
                        goto gt_EndMethod2;

                    //
                    // エラー。
                    gt_Error_NullItemValueToVariable:
                        {
                            Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                            tmpl.SetParameter(1, PmNames.S_NAME_VAR.Name_Pm, log_Reports);//引数名NameVar
                            tmpl.SetParameter(2, ec_FcName1.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports), log_Reports);//コントロール名

                            //
                            // 「access="to"」要素を取得しているような。
                            //
                            Log_TextIndented s1 = new Log_TextIndentedImpl();
                            err_Ec_DataTarget.ToText_Snapshot(s1);
                            tmpl.SetParameter(3, s1.ToString(), log_Reports);//データターゲットの変数の中身

                            Log_TextIndented s2 = new Log_TextIndentedImpl();
                            err_Ec_DataTarget.Cur_Configuration.ToText_Content(s2);
                            tmpl.SetParameter(4, s2.ToString(), log_Reports);//データターゲットの設定の中身

                            this.Owner_MemoryApplication.CreateErrorReport("Er:110021;", tmpl, log_Reports);
                        }
                        goto gt_EndMethod2;

            //
                    // エラー。
                    gt_Error_UndefinedView:
                        {
                            Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                            tmpl.SetParameter(1, errorRule.GetType().Name, log_Reports);//要素のクラス名
                            tmpl.SetParameter(2, ec_Child.Cur_Configuration.Name, log_Reports);//設定の子要素のノード名
                            tmpl.SetParameter(3, sFncName, log_Reports);//設定の子要素の関数名

                            this.Owner_MemoryApplication.CreateErrorReport("Er:110022;", tmpl, log_Reports);
                        }
                        goto gt_EndMethod2;

                    gt_EndMethod2:
                        ;
                    });

                    //
                    // 「表示プログラム」を作成、
                    // リストボックスにその「リスト作成プログラム」を渡す。
                    // リストボックスは再表示されるたびに、
                    // その「リスト作成プログラム」を実行。

                    // 以下、その「表示プログラム」の内容。

                    //
                    // ループカウンタの回数だけ、リストに項目を追加。

                    //
                    // その内容は、値が<a-item-value>から取得。

                    //
                    // その内容は、表示ラベルが<a-item-label>から取得。

                    //
                    // その表示ラベルは、次の条件に一致した時、グレー色にする。
                    //
                    // <a-item-gray-out>
                    // <f-all-true>
                    // <a-empty-field>
                }
                goto gt_EndMethod;
            }

            goto gt_EndMethod;
            //
            //
            #region 異常系
            //────────────────────────────────────────
            gt_Error_NullFcUc:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, err_Ec_FcName1.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports), log_Reports);//コントロール名

                this.Owner_MemoryApplication.CreateErrorReport("Er:110023;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            gt_Error_EmptyView:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, err_Ec_FcName1.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports), log_Reports);//検索ヒット数

                this.Owner_MemoryApplication.CreateErrorReport("Er:110024;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            #endregion
            //
            //
            gt_EndMethod:
            log_Method.EndMethod(log_Reports);
            return "";
        }
        /// <summary>
        /// 再帰関数。
        /// 
        /// (A)「E■@where」のrec-condリストを抽出。
        /// (B)「E■fnc name=”Sf:rec-cond;”」のrec-condリストを抽出。
        /// </summary>
        /// <param name="dst_Recordcondition"></param>
        /// <param name="src_E_ReccondParent"></param>
        /// <param name="log_Reports"></param>
        private void Execute_ParseChildRecordconditionList(
            List<Recordcondition> list_Reccond_Dst,
            Expression_Node_StringImpl parent_Expression_ReccondList_Src,//「E■@where」か、「E■fnc name=”Sf:rec-cond;”」。子に「E■rec-cond」のリストを持つもの。
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_Expr.Name_Library, this, "Execute_ParseChildReccndList",log_Reports);
            //
            //

            string err_SOpe;

            // 「E■@where」の子要素<rec-cond>。
            //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: src_E_ReccondParent=[" + src_E_ReccondListParent.Cur_Configurationtree.Name_Node + "] 属性数=[" + src_E_ReccondListParent.E_AttrDic.Count + "] 子要素数=[" + src_E_ReccondListParent.CountChildNodes + "]");
            foreach (Expression_Node_String ec_Reccond_Src in parent_Expression_ReccondList_Src.List_Expression_Child.SelectList(EnumHitcount.Unconstraint, log_Reports))
            {
                // logic属性=""
                EnumLogic enumLogic = EnumLogic.None;
                // field属性="" (logic属性の指定がない場合、必須)
                string sField = "";
                // ope属性=""
                string sOpe = "";
                // value属性=""
                string sValue = "";
                // 属性
                Expression_Node_String ec_Description = null;

                //
                //
                //
                //

                bool bRead_Logic = false;
                bool bRead_Field = false;
                bool bRead_Ope = false;
                bool bRead_Value = false;
                bool bRead_Description = false;

                if (NamesNode.S_FNC == ec_Reccond_Src.Cur_Configuration.Name)
                {
                    string sFncName;
                    ec_Reccond_Src.TrySelectAttribute(out sFncName, PmNames.S_NAME.Name_Pm, EnumHitcount.One, log_Reports);
                    if (sFncName == NamesFnc.S_REC_COND)
                    {
                        //
                        // 【2012-05-30】
                        // <fnc name=”Sf:rec-cond;”>
                        //

                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 「E■fnc name=”Sf:rec-cond;”」を解析したい。 子要素数=[" + src_E_Reccond.CountChildNodes + "] 属性数=[" + src_E_Reccond.E_AttrDic.Count + "]");

                        //
                        //
                        ec_Reccond_Src.Dictionary_Expression_Attribute.ForEach(
                            delegate(string sPmName, Expression_Node_String ec_Attr2, ref bool bBreak)
                            {
                                //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: [属性] " + sAttrName + "=”" + e_Attr.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports) + "”");

                                if (sPmName == PmNames.S_LOGIC.Name_Pm)
                                {
                                    // 「@logic」値
                                    enumLogic = Utility_Table.LogicStringToEnum(ec_Attr2.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports));
                                    bRead_Logic = true;
                                }
                                else if (sPmName == PmNames.S_FIELD.Name_Pm)
                                {
                                    // field属性="" (logic属性がない場合は必須)
                                    sField = ec_Attr2.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);
                                    bRead_Field = true;
                                }
                                else if (sPmName == PmNames.S_OPE.Name_Pm)
                                {
                                    // ope属性=""
                                    sOpe = ec_Attr2.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);
                                    bRead_Ope = true;
                                }
                                else if (sPmName == PmNames.S_VALUE.Name_Pm)
                                {
                                    // #エラー? todo: valueは属性にせず、子要素にしたい。
                                    throw new Exception("※valueは属性にせず、子要素にしたい。★★★★★★★★★☆★★★★★★★★★☆★★★★★★★★★☆");
                                    System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: ※valueは属性にせず、子要素にしたい。★★★★★★★★★☆★★★★★★★★★☆★★★★★★★★★☆");

                                    // value属性=""
                                    sValue = ec_Attr2.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);
                                    bRead_Value = true;
                                }
                                else if (sPmName == PmNames.S_DESCRIPTION.Name_Pm)
                                {
                                    throw new Exception("使ってる?");
                                    ec_Description = ec_Attr2;
                                    bRead_Description = true;
                                }
                                else
                                {
                                    // todo:未定義の属性
                                }

                            });

                        // 「E■fnc」の子要素。
                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 「E■fnc」の子要素数=[" + src_E_Reccond.CountChildNodes + "]");
                        ec_Reccond_Src.List_Expression_Child.ForEach(
                            delegate(Expression_Node_String ec_Child, ref bool bRemove, ref bool bBreak)
                            {
                                //
                                // 「E■fnc」の子要素は、次の4種類。
                                //
                                //━━━━━
                                //f-str
                                //f-var
                                //fnc
                                //━━━━━
                                //
                                //
                                if (
                                    NamesNode.S_F_STR == ec_Child.Cur_Configuration.Name ||
                                    NamesNode.S_F_VAR == ec_Child.Cur_Configuration.Name ||
                                    NamesNode.S_FNC == ec_Child.Cur_Configuration.Name
                                    )
                                {
                                    sValue = ec_Child.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports);
                                    bRead_Value = true;
                                    //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 「E■fnc」の子要素=[" + e_Child.Cur_Configurationtree.Name_Node + "] sValue=[" + sValue + "]");
                                }
                                else
                                {
                                    // #エラー? todo:未定義の子要素。
                                    System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 「E■fnc」の未定義の子要素=[" + ec_Child.Cur_Configuration.Name + "]");
                                }
                            }
                        );
                    }
                    else
                    {
                        // #エラー? todo:エラー
                        System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: <fnc>だったが、「Sf:rec-cond;」ではなかった。");
                    }
                }
                else
                {
                    // #エラー todo:エラー
                    System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 「E■fnc」でも、「E■rec-cond」でもなかった。 未定義の子要素<" + ec_Reccond_Src.Cur_Configuration.Name + ">。");
                }

                Recordcondition dst_Recordcondition = null;

                //
                //
                //

                if (bRead_Logic)
                {
                    if (EnumLogic.None != enumLogic)
                    {
                        // logic属性がある場合
                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: rec-condに、logic属性が指定されています。解析。[" + logic.ToString() + "]★★★★★★★★★☆★★★★★★★★★☆★★★★★★★★★☆★★★★★★★★★☆");

                        bool bSuccessful = RecordconditionImpl.TryBuild(
                            out dst_Recordcondition,//作られるオブジェクト
                            enumLogic,//andとかorとか。
                            "",//フィールドID指定なし。
                            this.Cur_Configuration.Parent,
                            log_Reports
                            );

                        // 再帰。
                        //
                        // 子要素に<fnc name=”Sf:rec-cond;”>がある。
                        this.Execute_ParseChildRecordconditionList(
                            dst_Recordcondition.List_Child,
                            (Expression_Node_StringImpl)ec_Reccond_Src,
                            log_Reports
                            );

                        //
                        // rec-condの子要素化を終えます。
                        //
                        goto end_recCond;
                    }
                }

                bool bSuccessful2 = false;
                if (bRead_Field)
                {
                    bSuccessful2 = RecordconditionImpl.TryBuild(out dst_Recordcondition, EnumLogic.None, sField, this.Cur_Configuration.Parent, log_Reports);
                }

                if (bSuccessful2)
                {

                    if (bRead_Ope)
                    {
                        // ope属性=""
                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: ope解析。[" + sOpe + "]");

                        switch (sOpe)
                        {
                            case Expression_SfcellImpl.S_EQ:
                                dst_Recordcondition.EnumOpe = EnumOpe.Eq;
                                break;

                            case Expression_SfcellImpl.S_NEQ:
                                dst_Recordcondition.EnumOpe = EnumOpe.Neq;
                                break;

                            case Expression_SfcellImpl.S_LT:
                                dst_Recordcondition.EnumOpe = EnumOpe.Lt;
                                break;

                            case Expression_SfcellImpl.S_LTEQ:
                                dst_Recordcondition.EnumOpe = EnumOpe.Lteq;
                                break;

                            case Expression_SfcellImpl.S_GT:
                                dst_Recordcondition.EnumOpe = EnumOpe.Gt;
                                break;

                            case Expression_SfcellImpl.S_GTEQ:
                                dst_Recordcondition.EnumOpe = EnumOpe.Gteq;
                                break;

                            default:
                                // エラー
                                err_SOpe = sOpe;
                                goto gt_Error_UndefinedOpe;
                        }
                    }

                    if (bRead_Value)
                    {
                        // value属性="" TODO:子要素としてのvalue値もあるはず。
                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: value解析。["+sValue+"]");

                        dst_Recordcondition.Value = sValue;
                    }

                    if (bRead_Description)
                    {
                        dst_Recordcondition.Expression_Description = ec_Description;
                    }
                }

                //
                // rec-condの解析終わり、次は親要素の子要素リストに追加するか否か。
                //
            end_recCond:

                // 親要素に、この要素を追加。
                if (
                    bRead_Logic ||
                    bRead_Field ||
                    bRead_Ope ||
                    bRead_Value ||
                    bRead_Description
                    )
                {
                    if (dst_Recordcondition != null)
                    {
                        // 条件指定がある場合。
                        //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: ★★親要素に、この要素を追加します。");
                        list_Reccond_Dst.Add(dst_Recordcondition);
                    }
                    else
                    {
                        // #エラー?
                        System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 親要素に、この要素できませんでした。");
                    }
                }
                else
                {
                    // #エラー?
                    System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#Execute_ParseChildReccndList: 親要素に、この要素は追加しません。 bRead_Logic=[" + bRead_Logic + "] bRead_Field=[" + bRead_Field + "] bRead_Ope=[" + bRead_Ope + "] bRead_Value=[" + bRead_Value + "] bRead_Description=[" + bRead_Description + "]");
                }
            }//foreach

            goto gt_EndMethod;
            //
            #region 異常系
            //────────────────────────────────────────
            gt_Error_UndefinedOpe:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, err_SOpe, log_Reports);//演算子
                tmpl.SetParameter(2, Log_RecordReportsImpl.ToText_Configuration(this.Cur_Configuration), log_Reports);//設定位置パンくずリスト

                this.Owner_MemoryApplication.CreateErrorReport("Er:6014;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            #endregion
            //
            gt_EndMethod:
            log_Method.EndMethod(log_Reports);
        }
        /// <summary>
        /// セレクト文を作成します。
        /// </summary>
        /// <param name="out_bOneCellSelectCondition"></param>
        /// <param name="selectSt"></param>
        /// <param name="out_bExists_Awhr"></param>
        /// <param name="s_Fcell"></param>
        /// <param name="log_Reports"></param>
        private void E_Execute_P1_CleateSelect(
            out bool bOneCellSelectCondition_Out,//「フィールド名 = 値」の形のみ true。 エラー時もfalse。
            out Selectstatement selectSt,
            out bool bExists_Awhr_Out,//@whereの有無を返します。エラー時はfalse。
            Configuration_Node cf_Fcell,//「S■f-cell」。
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_Expr.Name_Library, this, "E_Execute_P1_CleateSelect",log_Reports);
            //
            //

            //
            // 空っぽのセレクト文。
            //
            bExists_Awhr_Out = false;
            bOneCellSelectCondition_Out = false;
            selectSt = new SelectstatementImpl(this, cf_Fcell);
            Expression_Node_StringImpl ec_Awhr_Src = null;//子「E■where」

            //
            // (1)select=”☆”
            //    抽出する列名のリスト。
            //
            Expression_Node_String ec_Aselect = null;//ソース情報利用のE
            if (log_Reports.Successful)
            {
                this.TrySelectAttribute(out ec_Aselect, PmNames.S_SELECT.Name_Pm, EnumHitcount.One, log_Reports);
            }

            if (log_Reports.Successful)
            {
                selectSt.List_SName_SelectField = new CsvTo_ListImpl().Read(ec_Aselect.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports));
            }

            //
            // (2)into 属性
            //
            if (log_Reports.Successful)
            {
                Expression_Node_String ec_Into;//ソース情報利用のE
                bool bHit = this.TrySelectAttribute(out ec_Into, "into", EnumHitcount.One_Or_Zero, log_Reports);
                if (bHit)
                {
                    selectSt.Expression_Into = ec_Into;
                }
            }

            //
            // (3)「E■@where」。無いものもある。
            //
            if (log_Reports.Successful)
            {
                Expression_Node_String ec_Awhr1_Src;
                this.List_Expression_Child.ForEach(delegate(Expression_Node_String e_Child, ref bool bRemove, ref bool bBreak)
                {
                    string sValue;
                    e_Child.TrySelectAttribute(out sValue, PmNames.S_NAME.Name_Pm, EnumHitcount.One, log_Reports);

                    if (NamesNode.S_FNC == e_Child.Cur_Configuration.Name &&
                        NamesFnc.S_WHERE == sValue)
                    {
                        ec_Awhr1_Src = e_Child;// Expression_Node_StringImpl である必要がある。E_String_AtomImplではダメ。

                        if (ec_Awhr1_Src is Expression_Node_StringImpl)
                        {
                            ec_Awhr_Src = (Expression_Node_StringImpl)ec_Awhr1_Src;
                        }
                        else
                        {
                            // エラー。
                            goto gt_Error_AtomWhr2;
                        }

                        bBreak = true;
                    }

                    goto gt_EndMethod2;

                // エラー。
                gt_Error_AtomWhr2:
                    {
                        Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();

                        Expression_Leaf_StringImpl ec_Leaf = (Expression_Leaf_StringImpl)ec_Awhr1_Src;
                        tmpl.SetParameter(1, ec_Leaf.List_Expression_Child.Count.ToString(), log_Reports);//子要素の数

                        tmpl.SetParameter(2, Log_RecordReportsImpl.ToText_Configuration(this.Cur_Configuration), log_Reports);//設定位置パンくずリスト

                        this.Owner_MemoryApplication.CreateErrorReport("Er:6015;", tmpl, log_Reports);
                    }
                    goto gt_EndMethod2;

                    //
                gt_EndMethod2:
                    ;
                });

                if (null != ec_Awhr_Src)
                {
                    // 子「E■where」あり。
                    bExists_Awhr_Out = true;
                }
                else
                {
                    // 正常。無いこともあります。
                    bExists_Awhr_Out = false;
                    Configurationtree_Node cf_Node = new Configurationtree_NodeImpl(this + ":Where属性該当なし", null);
                    ec_Awhr_Src = new Expression_Node_StringImpl(this, cf_Node);
                }
            }
            else
            {
                // エラーがあるのでさっさと抜ける。
                bOneCellSelectCondition_Out = false;
                bExists_Awhr_Out = false;
                goto gt_EndMethod;
            }

            //
            // (3)required=”★”
            //    レコードが1件以上ヒットすることが必須か。"true","TRUE"等。
            //
            if (log_Reports.Successful)
            {
                // <f-cell required=”☆”>を使う。

                //
                // <f-cell>は required属性を持たないはず。
                // <fnc name=”Sf:where;”>のrequired引数が登録される?
                //
                //

                string sRequired;
                bool bHit = this.TrySelectAttribute(out sRequired, PmNames.S_REQUIRED.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                if (bHit)
                {
                    selectSt.Required = sRequired;
                }
                else
                {
                    //
                    // <f-cell>が required属性を持っていないとき。
                    //
                    //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect: <f-cell>が required属性を持っていないとき。");

                    //
                    // where属性で「E■where」(fnc)を持っているはず。(無条件のときは持っていない)
                    //
                    Expression_Node_String ec_Whr;//属性利用
                    bool bHit2 = this.TrySelectAttribute(out ec_Whr, PmNames.S_WHERE.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                    if (bHit2)
                    {
                        bool bHit3 = ec_Whr.TrySelectAttribute(out sRequired, PmNames.S_REQUIRED.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                        if (bHit3)
                        {
                            selectSt.Required = sRequired;
                            //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect: <f-cell>が required属性を持っていなかったので、whereのrequired属性から取得した。[" + selectSt.Required + "]");
                        }
                        else
                        {
                            // whereのrequired設定が未指定。

                            // #エラー
                            System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect: <f-cell>が required属性を持っていなかったので、whereのrequired属性から取得しようとしたが、whereのrequiredは未設定だった。[" + selectSt.Required + "]");
                        }
                    }
                    else
                    {
                        //
                        // <f-cell>が、where属性を持っていない。 【正常】
                        //

                        //// required設定が未指定。

                        //// #エラー
                        //System.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect: <f-cell>が required属性を持っていなかったので、whereのrequired属性から取得しようとしたが、whereは未設定だった。[" + selectSt.Required + "]");

                        //if (bDbg1)
                        //{
                        //    System.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect:┌────────┐this.E_AttrDic.Count=[" + this.E_AttrDic.Count + "]");
                        //    this.E_AttrDic.Each_E_Nodes(delegate(string sName, Expression_Node_String e_Child, ref bool bBreak)
                        //    {
                        //        System.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect: [" + sName + "]=[" + e_Child.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports) + "]");
                        //    });
                        //    System.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_CleateSelect:└────────┘");
                        //}
                    }
                }
            }

            //
            // (4)テーブル名。"Ut:モンスター表"等。
            //
            if (log_Reports.Successful)
            {
                // <f-cell from=”☆”>を使う。
                Expression_Node_String ec_From;//ソース情報利用
                bool bHit = this.TrySelectAttribute(out ec_From, PmNames.S_FROM.Name_Pm, EnumHitcount.One, log_Reports);
                if (bHit)
                {
                    selectSt.Expression_From = ec_From;
                }

                // テーブル名は必須。
                if ("" == selectSt.Expression_From.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports).Trim())
                {
                    //
                    // エラー。
                    //dst_Rs = null;
                    goto gt_Error_EmptyTableName;
                }
            }

            //
            // 「E■f-cell」は、子要素を持たない。
            //
            // 「E■f-cell」には、次の属性がある。
            // (1)「E■@where」
            //
            //
            // 「E■@where」は、次の子要素のリストがある。
            // ・「E■fnc name=”Sf:rec-cond;”」
            //

            //
            // f-cellの子要素の数は、where要素1つ、または 0 が正しい。
            //
            if (log_Reports.Successful)
            {
                // 子要素。
                List<Expression_Node_String> ecList = this.List_Expression_Child.SelectList(EnumHitcount.Unconstraint, log_Reports);
                //if (0 < e_List.Count)
                if (1 < ecList.Count)
                {
                    goto gt_Error_ExistsFcellChild;
                }
            }

            //
            // (2)探したいキー値の有無。"1000"等。
            if (log_Reports.Successful)
            {

                // key属性(@where)、record-set-load-from属性のどちらかが書かれているはず。

                if (
                    bExists_Awhr_Out ||
                    "" != selectSt.Expression_Where_RecordSetLoadFrom.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports).Trim()
                    )
                {
                    //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_PP1_FcellToSelectSt: 「E■a-where keyField=”☆”」は無かったが、「子E■rec-cond」要素はあった場合。");

                    // 次へ進む。
                }
                else
                {
                    // エラー。key値(@where)も、record-set-load-from属性もない。
                    goto gt_Error_EmptyKey;
                }
            }

            //
            // <f-cell>が、keyField=”★”属性("ID"などの値)を持つのは、R4-100版で廃止されました。
            //

            //
            // (5)あれば、「E■@where」の解析。(2012-02-07)
            //
            if (log_Reports.Successful)
            {
                if (bExists_Awhr_Out)
                {
                    // 「E■@where」条件が付いているとき。

                    // 「E■@where」の logic属性を取得しておく。
                    {
                        string sLogic;
                        bool bHit = ec_Awhr_Src.TrySelectAttribute(out sLogic, PmNames.S_LOGIC.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                        if (bHit)
                        {
                            selectSt.EnumWherelogic = Utility_Table.LogicStringToEnum(sLogic);
                            //ystem.Console.WriteLine(Info_E.LibraryName + ":" + this.GetType().Name + "#E_Execute_P1_SelectSt: where要素のlogic属性もきちんと読み取り。[" + sAwhrLogic + "]");
                        }
                    }

                    this.Execute_ParseChildRecordconditionList(
                        selectSt.List_Recordcondition,
                        ec_Awhr_Src,
                        log_Reports
                        );
                }
                else
                {
                    // 「E■@where」条件が無い場合。

                    // #警告。正常。
                    System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#E_Execute_P1_SelectSt: 条件がないタイプ(whereを持たない)です。親ノード=" + this.Cur_Configuration.Parent);
                }
            }

            //
            // 「E■@where」は、2種類に判別。
            // (1)「E■rec-cond」が1つだけ入っている形式
            // (2)「E■rec-cond」が1つ以上入っている形式
            //
            if (log_Reports.Successful)
            {
                if (0 == selectSt.List_Recordcondition.Count())
                {
                    //
                    // 0個なら、無条件。
                    //
                }
                else if (1 == selectSt.List_Recordcondition.Count())
                {
                    //
                    // 「フィールド値=値」の形の条件式かどうかを調べます。
                    //

                    // ・<rec-cond>が1つ
                    Recordcondition firstReccond = selectSt.List_Recordcondition[0];
                    if (null == firstReccond)
                    {
                        // #エラー? TODO:エラー?
                        System.Console.WriteLine(Info_Expr.Name_Library + ":" + this.GetType().Name + "#E_Execute_P1_SelectSt: rec-condリストにヌルが入っていた。エラー?");

                        // 条件ハズレ。
                        goto end_conditionSpec;
                    }

                    // ・その<rec-cond>は logic属性を持たない。
                    if (EnumLogic.None != firstReccond.EnumLogic)
                    {
                        // 条件ハズレ。
                        goto end_conditionSpec;
                    }

                    // field属性には1つのフィールド名が書かれている。(selectではないので、そうでなければエラー)
                    List<string> sList_FieldName = new CsvTo_ListImpl().Read(firstReccond.Name_Field);
                    if (1 != sList_FieldName.Count)
                    {
                        // 条件ハズレ。
                        goto end_conditionSpec;
                    }

                    // valueを持つ。
                    if ("" == firstReccond.Value.Trim())
                    {
                        // 条件ハズレ。
                        goto end_conditionSpec;
                    }

                    //「=」で結ばれている条件のもの。
                    if (EnumOpe.Eq != firstReccond.EnumOpe)
                    {
                        // 条件ハズレ。
                        goto end_conditionSpec;
                    }

                    // 適合。「フィールド名=値」の形の条件式。セル1つが選ばれる。
                    bOneCellSelectCondition_Out = true;
                }
                else
                {
                    // 条件ハズレ。
                }
            }

            end_conditionSpec:

            goto gt_EndMethod;
            //
            //
            #region 異常系
            //────────────────────────────────────────
            gt_Error_ExistsFcellChild:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, this.Cur_Configuration.Name, log_Reports);//設定ノード名

                List<Expression_Node_String> e_List = this.List_Expression_Child.SelectList(EnumHitcount.Unconstraint, log_Reports);
                tmpl.SetParameter(2, e_List.Count.ToString(), log_Reports);//子要素の数

                Log_TextIndented s = new Log_TextIndentedImpl();
                foreach (Expression_Node_String ec_Child in e_List)
                {
                    s.Append("Expr[" + ec_Child.Cur_Configuration.Name + "]");
                    s.Newline();
                }
                tmpl.SetParameter(3, s.ToString(), log_Reports);//要素のリスト

                tmpl.SetParameter(4, Log_RecordReportsImpl.ToText_Configuration(this.Cur_Configuration), log_Reports);//設定位置パンくずリスト

                this.Owner_MemoryApplication.CreateErrorReport("Er:6016;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            gt_Error_EmptyKey:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, bExists_Awhr_Out.ToString(), log_Reports);//Where句の有無
                tmpl.SetParameter(2, selectSt.Expression_Where_RecordSetLoadFrom.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports).Trim(), log_Reports);//RecordSetLoadFrom属性
                tmpl.SetParameter(3, this.Dictionary_Expression_Attribute.Count.ToString(), log_Reports);//属性の数

                Log_TextIndented s1 = new Log_TextIndentedImpl();
                this.Dictionary_Expression_Attribute.ForEach(delegate(string sName3, Expression_Node_String e_Attr3, ref bool bBreak)
                {
                    s1.Append("Attribute[" + sName3 + "]=Expr[" + e_Attr3.Cur_Configuration.Name + "] 値=[" + e_Attr3.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports) + "]");
                    s1.Newline();
                });
                tmpl.SetParameter(4, s1.ToString(), log_Reports);//属性リスト

                tmpl.SetParameter(5, this.Dictionary_Expression_Attribute.Count.ToString(), log_Reports);//子要素の数

                Log_TextIndented s2 = new Log_TextIndentedImpl();
                this.List_Expression_Child.ForEach(delegate(Expression_Node_String e_Child, ref bool bRemove, ref bool bBreak)
                {
                    s2.Append("子 [" + e_Child.Cur_Configuration.Name + "]=[" + e_Child.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports) + "]");
                    s2.Newline();
                });
                tmpl.SetParameter(6, s2.ToString(), log_Reports);//子要素リスト

                tmpl.SetParameter(7, Log_RecordReportsImpl.ToText_Configuration(this.Cur_Configuration), log_Reports);//設定位置パンくずリスト

                this.Owner_MemoryApplication.CreateErrorReport("Er:6017;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            gt_Error_EmptyTableName:
            {
                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                tmpl.SetParameter(1, Log_RecordReportsImpl.ToText_Configuration(cf_Fcell), log_Reports);//設定位置パンくずリスト

                this.Owner_MemoryApplication.CreateErrorReport("Er:6018;", tmpl, log_Reports);
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            #endregion
            //
            //
            gt_EndMethod:
            log_Method.EndMethod(log_Reports);
        }
Exemple #24
0
        //────────────────────────────────────────

        public Expression_Node_String Compile(
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl();

            log_Method.BeginMethod(Info_Syntax.Name_Library, this, "Compile", log_Reports);
            //

            String sTxtTmpl = this.Text;



            Configurationtree_Node     parent_Cnf = new Configurationtree_NodeImpl("!ハードコーディング_TextTemplateImpl#Compile", null);
            Expression_Node_StringImpl result     = new Expression_Node_StringImpl(null, parent_Cnf);

            int nCur = 0;

            while (nCur < sTxtTmpl.Length)
            {
                int nPreCur = nCur;

                // 開き%記号(open percent)
                int nOp = sTxtTmpl.IndexOf('%', nCur);

                if (nOp != -1)
                {
                    // 開き%記号があった。

                    nCur = nOp + 1;//「開き%」の次へ。

                    // 閉じ%記号(close percent)
                    int cp = sTxtTmpl.IndexOf('%', nCur);

                    if (cp != -1)
                    {
                        // 閉じ%記号があれば。

                        nCur = cp + 1;//「閉じ%」の次へ。

                        // 「%」と「%」の間に数字があるはず。
                        // 「開き%」の次から、「閉じ% - 開き% - 1」文字分。(-1しないと、終了%を含んでしまう)
                        string sMarker = sTxtTmpl.Substring(nOp + 1, cp - nOp - 1);


                        // 「%1%」といった記号の数字部分。
                        int nParameterIndex;


                        try
                        {
                            nParameterIndex = Int32.Parse(sMarker);


                            // 開き「%」までを、まず文字列化。
                            int    nPreLen = nOp - nPreCur;
                            string sPre    = sTxtTmpl.Substring(nPreCur, nPreLen);
                            result.AppendTextNode(
                                sPre,
                                parent_Cnf,
                                log_Reports
                                );



                            // 引数から値を取得。

                            // %数字%を、Expression化して追加。
                            Expression_TexttemplateP1pImpl expr_P1p = new Expression_TexttemplateP1pImpl(null, parent_Cnf);
                            expr_P1p.NumberP1p      = nParameterIndex;
                            expr_P1p.Dictionary_P1p = this.Dictionary_NumberAndValue_Parameter;

                            result.List_Expression_Child.Add(
                                expr_P1p,
                                log_Reports
                                );

                            // 続行。
                        }
                        catch (Exception)
                        {
                            // 数字でないようなら。

                            // 今回の判定は失敗したものとして、残りの長さ全て
                            int nRestLen = sTxtTmpl.Length - nPreCur;

                            result.AppendTextNode(
                                sTxtTmpl.Substring(nPreCur, nRestLen),
                                parent_Cnf,
                                log_Reports
                                );


                            nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                        }
                    }
                    else
                    {
                        // 閉じ%がなければ。

                        // 今回の判定は失敗したものとして、残りの長さ全て
                        int nRestLen = sTxtTmpl.Length - nPreCur;

                        result.AppendTextNode(
                            sTxtTmpl.Substring(nPreCur, nRestLen),
                            parent_Cnf,
                            log_Reports
                            );

                        nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                    }
                }
                else
                {
                    // 開き%がなければ。

                    // 残りの長さ全て
                    int nRestLen = sTxtTmpl.Length - nCur;

                    result.AppendTextNode(
                        sTxtTmpl.Substring(nCur, nRestLen),
                        parent_Cnf,
                        log_Reports
                        );

                    nCur = sTxtTmpl.Length;//終了(最後の文字の次へカーソルを出す)
                }
            }


            //
            //
            log_Method.EndMethod(log_Reports);
            return(result);
        }
        //────────────────────────────────────────
        public override void Translate(
            Configurationtree_Node cur_Cf,//「S■fnc name=”Sf:f-list-box-labels;”」
            Expression_Node_String parent_Expr,//「E■view」
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE", log_Reports);

            if (log_Method.CanDebug(1))
            {
            }

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_String cur_Expr = new Expression_Node_StringImpl(parent_Expr, cur_Cf);

            //
            //
            //
            // 属性
            //
            //
            //
            this.ParseAttr_InConfigurationtreeToExpression(
                cur_Cf,
                cur_Expr,
                true,
                true,
                log_Reports
                );

            //
            //
            //
            // 子
            //
            //
            //
            cur_Cf.List_Child.ForEach(delegate( Configurationtree_Node child_Cf, ref bool bBreak2)
            {
                string sName_Fnc;
                child_Cf.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_Fnc, false, log_Reports);

                if (log_Method.CanDebug(1))
                {
                    log_Method.WriteDebug_ToConsole( " 子解析。 <~ name=”[" + sName_Fnc + "]”>");
                }

                // todo: Sf:item-value;
                if(NamesFnc.S_ITEM_VALUE == sName_Fnc)
                {
                    //
                    // 自
                    //
                    Expression_Node_String child_Expr = new Expression_Node_StringImpl(cur_Expr, child_Cf);

                    //
                    // 属性
                    //
                    this.ParseAttr_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        true,
                        true,
                        log_Reports
                        );

                    //
                    // 子
                    //
                    this.ParseChild_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        memoryApplication,
                        pg_ParsingLog,
                        log_Reports
                        );

                    //
                    // 親
                    //
                    cur_Expr.List_Expression_Child.Add(child_Expr, log_Reports);
                }
                else if (NamesFnc.S_ITEM_LABEL2 == sName_Fnc)
                {
                    //
                    // 自
                    //
                    Expression_Node_String child_Expr = new Expression_Node_StringImpl(cur_Expr, child_Cf);

                    //
                    // 属性
                    //
                    this.ParseAttr_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        true,
                        true,
                        log_Reports
                        );

                    //
                    // 子
                    //
                    this.ParseChild_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        memoryApplication,
                        pg_ParsingLog,
                        log_Reports
                        );

                    //
                    // 親
                    //
                    cur_Expr.List_Expression_Child.Add(child_Expr, log_Reports);
                }
                else if (NamesFnc.S_ITEM_GRAY_OUT == sName_Fnc)
                {
                    //
                    // 自
                    //
                    Expression_Node_String child_Expr = new Expression_Node_StringImpl(cur_Expr, child_Cf);

                    //
                    // 属性
                    //
                    this.ParseAttr_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        true,
                        true,
                        log_Reports
                        );

                    //
                    // 子
                    //
                    this.ParseChild_InConfigurationtreeToExpression(
                        child_Cf,
                        child_Expr,
                        memoryApplication,
                        pg_ParsingLog,
                        log_Reports
                        );

                    //
                    // 親
                    //
                    cur_Expr.List_Expression_Child.Add(child_Expr, log_Reports);
                }
                else
                {
                    {
                        Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                        tmpl.SetParameter(1, child_Cf.Name, log_Reports);//子設定ノード名

                        memoryApplication.CreateErrorReport("Er:7019;", tmpl, log_Reports);
                    }

                    bBreak2 = true;
                    goto gt_gt_EndMethod2;
                }
                goto gt_gt_EndMethod2;

                //
            //
            //
            //
            gt_gt_EndMethod2:
                ;
            });

            //
            //
            //
            // 親へ連結
            //
            //
            //
            parent_Expr.List_Expression_Child.Add(cur_Expr, log_Reports);
            //
            log_Method.EndMethod(log_Reports);
        }
 /// <summary>
 /// 属性。
 /// </summary>
 /// <param name="out_E_Result">検索結果。</param>
 /// <param name="sName"></param>
 /// <param name="bRequired"></param>
 /// <param name="hits"></param>
 /// <param name="log_Reports"></param>
 /// <returns>検索結果が1件以上あれば真。</returns>
 public bool TrySelectAttribute(
     out Expression_Node_String ec_Result_Out,
     string sName,
     EnumHitcount hits,
     Log_Reports log_Reports
     )
 {
     // 使いません。
     ec_Result_Out = new Expression_Node_StringImpl(this, null);
     return false;
 }
Exemple #27
0
        //────────────────────────────────────────
        private void RefreshUsercontrol(
            Configurationtree_Node cf_TgTarget,
            Configurationtree_Node cf_TgTogether,
            Configurationtree_Node cf_RfrConfig_Hint,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_MiddleImpl.Name_Library, this, "RefreshUsercontrol",log_Reports);
            //
            //
            Expression_Node_String err_EFcName;

            //
            //
            // 1:ターゲットの再表示
            // 所要時間目安[?]ミリ秒ほど
            //
            //

            if (log_Reports.CanStopwatch)
            {
                // コメント作成
                {
                    StringBuilder sb = new StringBuilder();

                    string sName_Together;
                    {
                        bool bHit = cf_TgTogether.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_Together, false, log_Reports);
                    }

                    string sIn_Together;
                    {
                        bool bHit = cf_TgTogether.Dictionary_Attribute.TryGetValue(PmNames.S_IN, out sIn_Together, false, log_Reports);
                    }

                    string sTarget_Together;
                    {
                        bool bHit = cf_TgTogether.Dictionary_Attribute.TryGetValue(PmNames.S_TARGET1, out sTarget_Together, false, log_Reports);
                    }

                    sb.Append(" Together-");

                    if ("" != sName_Together)
                    {
                        sb.Append("name[");
                        sb.Append(sName_Together);
                        sb.Append("]");
                    }

                    if ("" != sIn_Together)
                    {
                        sb.Append("in[");
                        sb.Append(sIn_Together);
                        sb.Append("]");
                    }

                    sb.Append(".TRGT[");
                    sb.Append(sTarget_Together);
                    sb.Append("]");

                    log_Method.Log_Stopwatch.Message = sb.ToString();
                }

                log_Method.Log_Stopwatch.Begin();
            }

            string sName_TgTarget;
            bool bDirty = false;
            if (log_Reports.Successful)
            {
                // target.NNの文字列表現
                cf_TgTarget.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_TgTarget, true, log_Reports);

                //TODO:末尾に「*」(dirty再読込要求)が付いてたら外したい。
                if (sName_TgTarget.EndsWith("*"))
                {
                    sName_TgTarget = sName_TgTarget.Substring(0, sName_TgTarget.Length - 1);
                    // デバッグ
                    //ystem.Console.WriteLine(Info_OpyopyoImpl.LibraryName + ":MemoryFormsImpl#RefreshDataByRefreaher: 末尾の*を取り除いた。sTargetName=[" + sTargetName + "]");
                    bDirty = true;
                }
            }
            else
            {
                sName_TgTarget = "";
            }

            //
            //
            //
            // (3)対象コントロール
            //
            //
            //
            if (log_Reports.Successful)
            {
                List<Usercontrol> list_Usercontrol;
                // コントロール名。
                Expression_Node_StringImpl ec_Name = new Expression_Node_StringImpl(null, cf_TgTarget);
                ec_Name.AppendTextNode(
                    sName_TgTarget,
                    cf_TgTarget,
                    log_Reports
                    );

                list_Usercontrol = this.GetUsercontrolsByName(
                    ec_Name,
                    false,// エラー対応は後でやるので、このメソッドの中ではしません。
                    log_Reports
                    );

                if (0 < list_Usercontrol.Count)
                {
                    //
                    //
                    //
                    // (4)再表示
                    //
                    //
                    //
                    Usercontrol uct = list_Usercontrol[0];
                    if (null == uct)
                    {
                        // エラー
                        err_EFcName = ec_Name;
                        goto gt_Error_NullFirstFc;
                    }

                    // 必要なら再読込
                    if (bDirty)
                    {
                        uct.Dirty(log_Reports);
                    }

                    // 再表示
                    uct.RefreshData(
                        log_Reports
                        );
                }
                else
                {
                    goto gt_Error_NotFoundUsercontrol;
                }
            }
            else
            {
            }

            goto gt_EndMethod;
            //
            //
            #region 異常系
            //────────────────────────────────────────
            gt_Error_NullFirstFc:
            if (log_Reports.CanCreateReport)
            {
                Log_RecordReports r = log_Reports.BeginCreateReport(EnumReport.Error);
                r.SetTitle("▲エラー721!", log_Method);

                StringBuilder s = new StringBuilder();
                s.Append("コントロールを取得できませんでした。");

                s.Append(Environment.NewLine);
                s.Append("コントロール名=[");
                s.Append(err_EFcName.Execute4_OnExpressionString(EnumHitcount.Unconstraint, log_Reports));
                s.Append("]");

                r.Message = s.ToString();
                log_Reports.EndCreateReport();
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            gt_Error_NotFoundUsercontrol:
            if (log_Reports.CanCreateReport)
            {
                Log_RecordReports r = log_Reports.BeginCreateReport(EnumReport.Error);
                r.SetTitle("▲エラー933!", log_Method);

                StringBuilder t = new StringBuilder();
                t.Append(" リフレッシュ設定の<"+NamesNode.S_TOGETHER+">要素に、");
                t.Append(Environment.NewLine);
                t.Append(" 存在しないユーザー・コントロールの名前[");
                t.Append(sName_TgTarget);
                t.Append("]が指定されています。");
                t.Append(Environment.NewLine);
                t.Append(" 確認してください。");
                t.Append(Environment.NewLine);
                t.Append(Environment.NewLine);

                t.Append(" ユーザー・コントロール[" + sName_TgTarget + "]の値を更新しようとしたとき。");
                t.Append(Environment.NewLine);
                t.Append(Environment.NewLine);

                // ヒント
                t.Append(r.Message_Configuration(cf_RfrConfig_Hint));

                r.Message = t.ToString();
                log_Reports.EndCreateReport();
            }
            goto gt_EndMethod;
            //────────────────────────────────────────
            #endregion
            //
            //
            gt_EndMethod:
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        public void Translate(
            Configurationtree_Node cur_Conf,
            Expression_Node_String parent_Expr,
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE",log_Reports);

            if (log_Method.CanDebug(1))
            {
                pg_ParsingLog.Increment("(40)" + cur_Conf.Name);
            }

            //
            //
            //
            //

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_String ec_Value = new Expression_Node_StringImpl(parent_Expr, cur_Conf);
            ec_Value.AppendTextNode(
                cur_Conf.Name,
                cur_Conf,
                log_Reports
                );

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_StringImpl cur_Expr = new Expression_Node_StringImpl(parent_Expr, cur_Conf);

            //
            //
            //
            // 属性
            //
            //
            //
            {
                cur_Expr.SetAttribute(
                    PmNames.S_NAME.Name_Pm,
                    ec_Value,
                    log_Reports
                    );

                parent_Expr.SetAttribute(
                    NamesNode.S_RECORD_SET_LOAD_FROM,
                    ((Expression_Node_String)cur_Expr),
                    log_Reports
                    );
            }

            //
            //
            //
            // 子要素
            //
            //
            //
            {
                this.ParseChild_InConfigurationtreeToExpression(
                    cur_Conf,
                    cur_Expr,
                    memoryApplication,
                    pg_ParsingLog,
                    log_Reports
                    );
            }

            //
            //
            //
            //

            if (Log_ReportsImpl.BDebugmode_Static)
            {
                pg_ParsingLog.Decrement(cur_Conf.Name);
            }

            log_Method.EndMethod(log_Reports);
        }
Exemple #29
0
        /// <summary>
        /// 『レイアウト設定ファイル』をもとに、コントロールを作成し、
        /// フォームと、アプリケーション・モデルにコントロールを動的に追加します。
        /// </summary>
        /// <param name="fo_Config"></param>
        /// <param name="form"></param>
        protected void CreateForm(
            TableUserformconfig fo_Config,
            Form form,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_MiddleImpl.Name_Library, this, "CreateForm",log_Reports);
            //
            //

            //this.form_noren = form;

            // レイアウトするロジックを一時停止。(メインフォーム)
            form.SuspendLayout();

            // フォームにステータスバーを付けます。(デバッグモードでのみ) TODO:1回限りであること。
            if (null == statusStrip1 && Log_ReportsImpl.BDebugmode_Static)
            {
                statusStrip1 = new System.Windows.Forms.StatusStrip();

                //
                // statusStrip1
                //
                statusStrip1.Location = new System.Drawing.Point(0, 244);
                statusStrip1.Name = "statusStrip1";
                statusStrip1.Size = new System.Drawing.Size(292, 22);
                statusStrip1.TabIndex = 0;
                statusStrip1.Text = "statusStrip1";

                this.statusStripLabel2 = new System.Windows.Forms.ToolStripStatusLabel();
                this.statusStripLabel2.Name = "toolStripStatusLabel1";
                this.statusStripLabel2.Size = new System.Drawing.Size(114, 17);
                this.statusStripLabel2.Text = "toolStripStatusLabel1";
                this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
                this.statusStripLabel2});

                form.Controls.Add(statusStrip1);

                // #情報
                if (log_Method.CanInfo())
                {
                    log_Method.WriteInfo_ToConsole("ステータスバーをフォームに追加した。(デバッグモードでのみ)TODO:1回限りであること。");
                }
            }

            //// フォームに「マルチロール_テキストボックス」を付けます。 TODO:1回限りであること。
            //if (null == this.multiroleTextBox)
            //{
            //    this.multiroleTextBox = new System.Windows.Forms.TextBox();
            //    this.multiroleTextBox.Multiline = true;
            //    form.Controls.Add(this.multiroleTextBox);

            //    // #デバッグ
            //    ystem.Console.WriteLine(Info_NorenImpl.LibraryName + ":MoNorenImpl#CreateForm:マルチロール_テキストボックスをフォームに追加した。TODO:1回限りであること。");
            //}

            // 1つ前のコントロールが入っている仕組み。
            List<Usercontrol> list_StackFc = new List<Usercontrol>();
            List<int> nList_StackTree = new List<int>();

            //
            // レコードの並び順は、記述されている順番とします。
            //
            foreach (RecordUserformconfig fo_Record in fo_Config.List_RecordUserformconfig)
            {
                int nCurTree;
                fo_Record.TryGetInt(out nCurTree, NamesFld.S_TREE, true, -1, this.Owner_MemoryApplication, log_Reports);

                //
                //
                // ここで、コントロール(UserControl)を作成。
                // 作成できなかった、または作成しなかった場合はヌル。
                //
                //
                Usercontrol uct = ucontrolCreator1.Create(
                    fo_Record,
                    true,
                    this.Owner_MemoryApplication,
                    log_Reports
                    );

                //.WriteLine(this.GetType().Name + "#CreateForm: (10) この要素=[" + fcUc.ControlCommon.Name + "] curTree=[" + curTree + "]");

                if (log_Reports.Successful)
                {
                    if (null != uct)
                    {
                        string sName_Control;
                        fo_Record.TryGetString(out sName_Control, NamesFld.S_NAME, true, "", this.Owner_MemoryApplication, log_Reports);

                        Expression_Node_StringImpl ec_Str = new Expression_Node_StringImpl(null, fo_Record.Parent_TableUserformconfig.Cur_Configurationtree);
                        ec_Str.AppendTextNode(
                            sName_Control,
                            fo_Record.Parent_TableUserformconfig.Cur_Configurationtree,
                            log_Reports
                            );

                        //
                        //
                        // コントロール名の登録。
                        //
                        //
                        this.Owner_MemoryApplication.MemoryForms.PutUsercontrol(
                            ec_Str,
                            uct,
                            log_Reports
                            );

                        if (uct is UsercontrolWindow)
                        {
                            //
                            // 「ウィンドウ」(別窓)を開けたい場合。
                            //
                            UsercontrolWindow uctWnd = (UsercontrolWindow)uct;

                            //ucWindow.SetupStatusStrip();
                            uctWnd.CustomcontrolWindow1.Show();

                            //.WriteLine(this.GetType().Name + "#CreateForm: (20) 【ウィンドウ追加】トップに、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                        }
                        else
                        {

                            if (0 == nList_StackTree.Count)
                            {
                                //
                                // ★追加:   メインフォームのトップに、この要素を追加
                                //
                                form.Controls.Add((Control)uct);

                                // 普通、メインウィンドウもここになる。
                            }
                            else
                            {
                                int nPrevTree = nList_StackTree.Last();

                                if (nPrevTree == nCurTree)
                                {
                                    // 1つ前の要素と ツリー値が同じなら、

                                    // 1つ前の要素をスタックから削除し、
                                    list_StackFc.RemoveAt(list_StackFc.Count - 1);
                                    nList_StackTree.RemoveAt(nList_StackTree.Count - 1);

                                    if (0 != nList_StackTree.Count)
                                    {
                                        nPrevTree = nList_StackTree.Last();

                                        //
                                        // ★追加:   前の要素(スタックの最後の要素)に、この要素を追加。
                                        //
                                        Usercontrol prevUc = list_StackFc.Last();

                                        prevUc.AppendChild(
                                            uct,
                                            log_Reports
                                            );

                                        //.WriteLine(this.GetType().Name + "#CreateForm: (40) 【前の要素に、この要素を追加】 前の要素=[" + prevUc.ControlCommon.Name + "]に、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                                    }
                                    else
                                    {
                                        nPrevTree = 0;

                                        //
                                        // ★追加:   メインフォームのトップに、この要素を追加
                                        //
                                        form.Controls.Add((Control)uct);

                                        //.WriteLine(this.GetType().Name + "#CreateForm: (50) 【メインフォームのトップ要素として追加2】 メインフォームのトップに、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                                    }
                                }
                                else if (nPrevTree < nCurTree)
                                {
                                    // 1つ前の要素より、大きなtree値を持つなら、

                                    //
                                    // ★追加: 1つ前の要素に、この要素を追加。
                                    //
                                    Usercontrol prevUc = list_StackFc.Last();

                                    prevUc.AppendChild(
                                        uct,
                                        log_Reports
                                        );

                                    //.WriteLine(this.GetType().Name + "#CreateForm: (60) 【前の要素に、この要素を追加】 前の要素=[" + prevUc.ControlCommon.Name + "]に、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                                }
                                else
                                {
                                    // 1つ前の要素より、小さなtree値を持つなら、

                                    //
                                    // ★削除:
                                    //   自分より小さなtree値を持つ要素が出てくるまで、
                                    //   前の要素を消す。
                                    //
                                    list_StackFc.RemoveAt(list_StackFc.Count - 1);
                                    nList_StackTree.RemoveAt(nList_StackTree.Count - 1);
                                    //.WriteLine(this.GetType().Name + "#CreateForm: (70) 【前要素削除】 この要素=[" + fcUc.ControlCommon.Name + "]");

                                    //
                                    // foreachループの中で、リストの要素数が変わると、
                                    // foreachループは失敗する。
                                    //
                                    // whileループを使うことにする。
                                    //
                                    while (0 < nList_StackTree.Count)
                                    {
                                        Usercontrol prevUc = list_StackFc.Last();
                                        nPrevTree = nList_StackTree.Last();

                                        if (nCurTree <= nPrevTree)
                                        {
                                            list_StackFc.RemoveAt(list_StackFc.Count - 1);
                                            nList_StackTree.RemoveAt(nList_StackTree.Count - 1);
                                            //.WriteLine(this.GetType().Name + "#CreateForm: (80) 【前要素削除】 この要素=[" + fcUc.ControlCommon.Name + "] 前の要素=[" + prevUc.ControlCommon.Name + "]");
                                        }
                                        else
                                        {
                                            break;
                                        }
                                    }

                                    if (0 == nList_StackTree.Count)
                                    {
                                        // 空っぽになったらループを止める。
                                        // エラー?
                                        nPrevTree = -1;
                                    }
                                    else
                                    {
                                        nPrevTree = nList_StackTree.Last();
                                    }

                                    if (0 == nList_StackTree.Count)
                                    {
                                        //
                                        // ★追加:   メインフォームのトップに、この要素を追加
                                        //
                                        form.Controls.Add((Control)uct);

                                        //.WriteLine(this.GetType().Name + "#CreateForm: (90) 【メインフォームのトップ要素として追加3】 メインフォームのトップに、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                                    }
                                    else
                                    {
                                        //
                                        // ★追加: 1つ前の要素に、この要素を追加。
                                        //
                                        Usercontrol prevUc = list_StackFc.Last();

                                        prevUc.AppendChild(
                                            uct,
                                            log_Reports
                                            );

                                        //.WriteLine(this.GetType().Name + "#CreateForm: (100) 【前の要素に、この要素を追加】 前の要素=[" + prevUc.ControlCommon.Name + "]に、この要素=[" + fcUc.ControlCommon.Name + "]を追加。");
                                    }

                                }
                            }
                        }

                    }
                }

                list_StackFc.Add(uct);
                nList_StackTree.Add(nCurTree);
            }

            // レイアウトの一時停止を解除。レイアウト実行の強制はしない。(メインフォーム)
            form.ResumeLayout(false);

            //
            //
            //
            //
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        /// <summary>
        /// <arg1>
        /// </summary>
        /// <param name="oFStrNode"></param>
        /// <param name="nFAelem"></param>
        /// <param name="moOpyopyo"></param>
        /// <param name="log_Reports"></param>
        public override void Translate(
            Configurationtree_Node cur_Cf,//「S■arg1」
            Expression_Node_String parent_Ec,//親「E■fnc」
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE",log_Reports);

            //
            // デバッグオープンの前に。
            //
            // 「S■arg1 name=”★”」属性
            //
            string sName_MyFnc;
            cur_Cf.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_MyFnc, false, log_Reports);

            if (log_Method.CanDebug(1))
            {
                Dictionary<string, string> s_Dic = new Dictionary<string, string>();
                s_Dic.Add(PmNames.S_NAME.Name_Pm, sName_MyFnc);
                pg_ParsingLog.Increment("(6.arg1・3要素)" + cur_Cf.Name, s_Dic);
            }

            //
            //

            if (log_Method.CanDebug(2))
            {
                log_Method.WriteDebug_ToConsole("「S■arg1・3」要素 解析開始┌────────────────┐ 自arg1・3は、e_Parent=[" + parent_Ec.Cur_Configuration.Name + "]の”" + sName_MyFnc + "”属性になる。");
            }

            string parent_SName_Fnc;
            {
                // ヒット必須にするとエラーになる?
                parent_Ec.TrySelectAttribute(out parent_SName_Fnc, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);
                if (!log_Reports.Successful)
                {
                    goto gt_EndMethod;
                }

                //if (0 < d_InMethod.NDebugLevel)
                //{
                //    if (NamesNode.S_FNC != e_Parent.Cur_Configurationtree.Name)
                //    {
                //        d_InMethod.WriteDebug_ToConsole(1, "fnc以外の親要素「E■[" + e_Parent.Cur_Configurationtree.Name + "]」");
                //    }
                //}
            }

            //
            //
            //
            // 自
            //
            //
            //
            Expression_Node_String cur_Ec = new Expression_Node_StringImpl(parent_Ec, cur_Cf);

            //
            //
            //
            // 属性
            //
            //
            //
            if (log_Reports.Successful)
            {
                // 元からあった。
                this.ParseAttr_InConfigurationtreeToExpression(
                    cur_Cf,
                    cur_Ec,
                    true,//name属性は必須。
                    true,//value属性は、子<f-str>にする。
                    log_Reports
                    );
            }

            //
            //
            //
            // 子
            //
            //
            //
            if (log_Reports.Successful)
            {
                this.ParseChild_InConfigurationtreeToExpression(
                    cur_Cf,
                    cur_Ec,
                    memoryApplication,
                    pg_ParsingLog,
                    log_Reports
                    );
            }

            //
            //
            //
            // 親へ連結 ※属性連結。
            //
            //
            //
            if (log_Reports.Successful)
            {
                parent_Ec.SetAttribute(sName_MyFnc, cur_Ec, log_Reports);
            }

            goto gt_EndMethod;
            //
            //
            gt_EndMethod:
            if (Log_ReportsImpl.BDebugmode_Static)
            {
                pg_ParsingLog.Decrement(cur_Cf.Name);
            }

            if (log_Method.CanDebug(2))
            {
                log_Method.WriteDebug_ToConsole( "「S■arg1・3」要素 解析終了└────────────────┘");
            }

            log_Method.EndMethod(log_Reports);
        }
Exemple #31
0
        //────────────────────────────────────────

        /// <summary>
        /// 親E_Stringを遡って検索。一致するものがなければヌル。
        /// </summary>
        /// <param name="sName_Node"></param>
        /// <returns></returns>
        public Expression_Node_String GetParentExpressionOrNull(string sName_Node)
        {
            return(Expression_Node_StringImpl.GetParentEOrNull_(this, sName_Node));
        }
Exemple #32
0
        //────────────────────────────────────────
        /// <summary>
        /// フォームのデータの再読み込みを行います。
        /// 
        /// どのフォームを再読み込みするかは、コントロール・リローディング設定ファイルで
        /// 設定しているリローダー要素の名前を指定します。
        /// </summary>
        /// <param select="o_Name_Together"></param>
        public void RefreshDataRange(
            XenonName o_Name_Together,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_MiddleImpl.Name_Library, this, "RefreshDataRange",log_Reports);

            //
            //
            //
            //

            List<Configurationtree_Node> listCf_Together = this.Configurationtree_Togetherconfig.GetChildrenByNodename(NamesNode.S_TOGETHER, false, log_Reports);
            foreach (Configurationtree_Node cf_Together in listCf_Together)
            {
                string sFncName;
                cf_Together.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sFncName, false, log_Reports);

                // 一致するのは1件しかない前提。
                if (sFncName == o_Name_Together.SValue)
                {
                    if (log_Reports.Successful)
                    {
                        // 最新表示にするコントロールの名前のリスト。
                        List<Configurationtree_Node> cfList_RfrTarget = cf_Together.GetChildrenByNodename(NamesNode.S_TARGET, false, log_Reports);

                        foreach (Configurationtree_Node cf_RfrTarget in cfList_RfrTarget)
                        {
                            List<Usercontrol> list_FcUc;
                            {
                                string sName;
                                cf_RfrTarget.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName, true, log_Reports);

                                Expression_Node_StringImpl e_str = new Expression_Node_StringImpl(null, cf_RfrTarget);
                                e_str.AppendTextNode(
                                    sName,
                                    cf_RfrTarget,
                                    log_Reports
                                    );

                                list_FcUc = this.Owner_MemoryApplication.MemoryForms.GetUsercontrolsByName(
                                    e_str,
                                    true,
                                    log_Reports
                                    );
                            }

                            if (log_Reports.Successful)
                            {
                                Usercontrol fcUc = list_FcUc[0];

                                fcUc.RefreshData(
                                    log_Reports
                                    );
                            }

                        }
                    }

                }

            }

            //
            //
            //
            //
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        /// <summary>
        /// 読取。
        /// </summary>
        /// <param name="s_View"></param>
        /// <param name="ef_View"></param>
        /// <param name="moOpyopyo"></param>
        /// <param name="log_Reports"></param>
        public void Translate(
            Configurationtree_Node cur_Cf,//<view>
            Expression_Node_String parent_Ec,//「E■form-component」
            MemoryApplication memoryApplication,
            Log_TextIndented_ConfigurationtreeToExpression pg_ParsingLog,
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_ConfigurationtreeToExpression.Name_Library, this, "SToE",log_Reports);

            if (log_Method.CanDebug(1))
            {
                pg_ParsingLog.Increment("(3)"+cur_Cf.Name);
            }

            //
            //
            //
            //

            //
            //
            //
            // 自
            //
            //
            //

            Expression_Node_StringImpl cur_Ec = new Expression_Node_StringImpl(parent_Ec, cur_Cf);

            //
            //
            //
            // 子
            //
            //
            //
            {
                //<●●>要素を全検索。<f-list-box-labels>があることが期待されます。

                cur_Cf.List_Child.ForEach(delegate(Configurationtree_Node cf_Child, ref bool bBreak)
                {
                    if (cf_Child is Configurationtree_Node)
                    {
                        Configurationtree_Node cf_Node = (Configurationtree_Node)cf_Child;

                        string sName_Node = cf_Node.Name;
                        string sName_Fnc = "";
                        {
                            bool bRequired;

                            if (NamesNode.S_FNC == sName_Node)
                            {
                                bRequired = true;
                            }
                            else
                            {
                                bRequired = false;
                            }

                            // todo; 子要素のnameも取りたい。
                            cf_Node.Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName_Fnc, bRequired, log_Reports);
                        }

                        if (NamesNode.S_FNC == sName_Node && NamesFnc.S_LISTBOX_LABELS == sName_Fnc)
                        {
                            // 「S■fnc name=”Sf:f-listbox-labels;”」

                            ConfigurationtreeToExpression_F91_FListboxLabelsImpl_ to = new ConfigurationtreeToExpression_F91_FListboxLabelsImpl_();
                            to.Translate(
                                cf_Child,
                                cur_Ec,
                                memoryApplication,
                                pg_ParsingLog,
                                log_Reports
                                );
                        }
                        else
                        {
                            // エラー
                            {
                                Builder_TexttemplateP1p tmpl = new Builder_TexttemplateP1pImpl();
                                tmpl.SetParameter(1, sName_Node, log_Reports);//設定ノード名
                                tmpl.SetParameter(2, sName_Fnc, log_Reports);//関数名

                                memoryApplication.CreateErrorReport("Er:7003;", tmpl, log_Reports);
                            }

                            bBreak = true;
                        }
                    }
                });
            }

            //
            //
            //
            // 親へ連結
            //
            //
            //
            {
                parent_Ec.List_Expression_Child.Add(cur_Ec, log_Reports);
            }

            goto gt_EndMethod;
            //
            //

            gt_EndMethod:
            if (Log_ReportsImpl.BDebugmode_Static)
            {
                pg_ParsingLog.Decrement(cur_Cf.Name);
            }
            log_Method.EndMethod(log_Reports);
        }
        //────────────────────────────────────────
        protected void Execute6_Sub(
            Log_Reports log_Reports
            )
        {
            Log_Method log_Method = new Log_MethodImpl(0, Log_ReportsImpl.BDebugmode_Static);
            log_Method.BeginMethod(Info_Functions.Name_Library, this, "Execute6_Sub", log_Reports);

            string sFncName0;
            this.TrySelectAttribute(out sFncName0, PmNames.S_NAME.Name_Pm, EnumHitcount.One_Or_Zero, log_Reports);

            if (log_Reports.CanStopwatch)
            {
                log_Method.Log_Stopwatch.Message = "Nアクション[" + sFncName0 + "]実行";
                log_Method.Log_Stopwatch.Begin();
            }
            //
            //

            //
            // 指定された引数から、または、
            // この<action>要素を含んでいる control要素から、コントロールの名前を取得。
            List<Usercontrol> list_FcUc = new List<Usercontrol>();
            if (log_Reports.Successful)
            {
                // 正常時

                Expression_Node_String ec_FcName_Prm;
                this.TrySelectAttribute(out ec_FcName_Prm, Expression_Node_Function36Impl.PM_CONTROL_NAME, EnumHitcount.One_Or_Zero, log_Reports);

                string sFcName_Prm = ec_FcName_Prm.Execute4_OnExpressionString(EnumHitcount.Unconstraint,log_Reports);

                List<Expression_Node_String> ecList_FcName = new List<Expression_Node_String>();
                if ("" == sFcName_Prm)
                {
                    //
                    // fcName未設定時は、この<action>要素を含んでいるcontrol要素から
                    // コントロールの名前を取得。
                    //

                    Configuration_Node cf_Event = this.Cur_Configuration.GetParentByNodename(
                        NamesNode.S_EVENT, EnumConfiguration.Unknown, false, log_Reports);

                    if (null != cf_Event)
                    {
                        Configuration_Node owner_Configurationtree_Control = cf_Event.GetParentByNodename(
                            NamesNode.S_CONTROL1, EnumConfiguration.Tree, true, log_Reports);

                        if (null != owner_Configurationtree_Control)
                        {
                            string sName;
                            bool bHit = ((Configurationtree_Node)owner_Configurationtree_Control).Dictionary_Attribute.TryGetValue(PmNames.S_NAME, out sName, false, log_Reports);

                            if (bHit)
                            {
                                Expression_Node_StringImpl ec_Str = new Expression_Node_StringImpl(this, this.Cur_Configuration);
                                ec_Str.AppendTextNode(
                                    sName,
                                    this.Cur_Configuration,
                                    log_Reports
                                    );

                                // 上書き
                                ec_FcName_Prm = ec_Str;
                                ecList_FcName.Add(ec_FcName_Prm);
                            }
                            else
                            {
                            }
                        }
                        else
                        {
                            //nFcName_prm = null;
                        }

                    }
                    else
                    {
                        //nFcName_prm = null;
                    }
                }
                else
                {
                    //
                    // fcName 指定時。

                    // カンマ区切りか確認。
                    CsvTo_ListImpl csvTo = new CsvTo_ListImpl();
                    List<string> sList_FcName_Prm = csvTo.Read(sFcName_Prm);

                    foreach (string sFcName2 in sList_FcName_Prm)
                    {
                        // コントロール名。
                        Expression_Node_StringImpl ec_FcName4 = new Expression_Node_StringImpl(this, this.Cur_Configuration);
                        ec_FcName4.AppendTextNode(
                            sFcName2,
                            this.Cur_Configuration,
                            log_Reports
                            );

                        ecList_FcName.Add(ec_FcName4);
                    }

                }

                foreach (Expression_Node_String ec_FcName5 in ecList_FcName)
                {
                    //
                    // 指定のコントロール
                    //
                    List<Usercontrol> list_FcUc2 = this.Owner_MemoryApplication.MemoryForms.GetUsercontrolsByName(
                        ec_FcName5,
                        true,
                        log_Reports
                        );

                    if (0 < list_FcUc2.Count)
                    {
                        Usercontrol fcUc = list_FcUc2[0];
                        list_FcUc.Add(fcUc);
                    }
                }
            }
            else
            {
            }

            foreach (Usercontrol fcUc in list_FcUc)
            {
                if (log_Reports.Successful)
                {
                    ////
                    //// 妥当性判定を行います。
                    ////
                    //if (log_Reports.Successful)
                    //{
                    //    fcUc.JudgeValidity(
                    //        log_Reports
                    //        );

                    //    //.WriteLine(this.GetType().Name + "#: ◆ 妥当性判定を行った。");
                    //}

                    if (fcUc.ControlCommon.BAutomaticinputting)
                    {
                        // コンピューターにより自動入力されたとき。
                    }
                    else
                    {
                        // 手入力による更新。

                        {
                            ToMemory_Performer toM = new ExpressionDataTargetUpdaterImpl();
                            toM.ToMemory(
                                "",// 空文字列
                                fcUc.ControlCommon.Expression_Control,
                                fcUc.ControlCommon.Owner_MemoryApplication,
                                log_Reports
                                );
                        }
                    }
                }
            }

            log_Method.EndMethod(log_Reports);
        }