JP5174648B2 - Program development support device, method and program - Google Patents
Program development support device, method and program Download PDFInfo
- Publication number
- JP5174648B2 JP5174648B2 JP2008326794A JP2008326794A JP5174648B2 JP 5174648 B2 JP5174648 B2 JP 5174648B2 JP 2008326794 A JP2008326794 A JP 2008326794A JP 2008326794 A JP2008326794 A JP 2008326794A JP 5174648 B2 JP5174648 B2 JP 5174648B2
- Authority
- JP
- Japan
- Prior art keywords
- source code
- module
- processing
- program
- code
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
- Stored Programmes (AREA)
Description
本発明は、プログラム開発を支援する技術に関する。 The present invention relates to a technique for supporting program development.
近年、ディジタルテレビやハードディスクレコーダ等のプログラム組み込み型システムにおいては、差別化のために製品品質と開発効率の向上が求められている中、工数、コスト、実装機能などの面でプログラム(ソフトウェア)の重要性が高まっており、プログラムの性能向上や不具合解消の高効率化が課題となっている。 In recent years, program embedded systems such as digital TVs and hard disk recorders have been required to improve product quality and development efficiency for differentiation. The importance is increasing, and improving the performance of the program and improving the efficiency of solving the problems are issues.
この課題を解決する従来の技術として、ソースコード解析支援装置があり、例えば、特許文献1に開示がある。
As a conventional technique for solving this problem, there is a source code analysis support device, which is disclosed in
特許文献1などの技術を利用すれば、解析対象ソースコードにおける、関数間の呼び出し関係や関連する引数・変数の情報を図式的に表示することで、ソースコードから文字情報のみで読み解くよりも効率良くプログラム動作(プログラム論理)を理解できる。また、ソースコードとモジュール関連図の一方の編集操作に基づいて双方向に両方を連動して変更するため、プログラムの編集、改造、保守等が容易となる。
If technology such as
また、プログラム開発時に性能向上や不具合解消のために行なう、性能測定、テスト、デバッグ等の作業においては、測定開始、終了、ログ出力等の処理コードを一時的にソースコードに挿入し、作業終了後(製品出荷時)には挿入した処理コードを削除する必要がある。 Also, in performance measurement, testing, debugging, and other work that is performed to improve performance and resolve problems during program development, processing code such as measurement start, end, and log output is temporarily inserted into the source code, and the work ends. It is necessary to delete the inserted processing code later (when the product is shipped).
しかし前記のような技術では、ソースコードに対する処理コードの挿入や削除が自動化されていないため、利用者に処理コードの挿入や削除などの手間がかかり、また、挿入した処理コードによりソースコードとモジュール関連図の両方においてプログラム論理の可読性が損なわれることなどが問題となることがある。 However, in the technology as described above, since insertion and deletion of processing code with respect to source code is not automated, it takes time and effort for the user to insert and delete processing code. In both of the related diagrams, there is a problem that the readability of the program logic is impaired.
本発明は、前記事情に鑑みてなされたものであり、本発明の目的は、開発者によるソースコードに対する、一時的な処理コードの挿入や、削除作業にかかる手間が従来よりも低減が可能であり、挿入時においてもプログラム論理の可読性が損なわれ難い、プログラム開発支援機器、方法およびプログラムを提供することにある。 The present invention has been made in view of the above circumstances, and the object of the present invention is that it is possible to reduce time and effort required for insertion and deletion of temporary processing code with respect to source code by a developer. It is an object of the present invention to provide a program development support device, method and program in which the readability of the program logic is hardly impaired even at the time of insertion.
前記の課題を解決するため、本発明のプログラム開発支援機器、方法およびプログラムは、ソースコードに対する編集内容を設定し、当該設定された編集内容に対応してソースコードを編集し、ソースコードの表示形式を設定し、当該設定された表示形式に対応してソースコードを表示した画面を作成する。 In order to solve the above-described problem, the program development support apparatus, method, and program of the present invention set edit contents for source code, edit the source code corresponding to the set edit contents, and display the source code Set the format and create a screen that displays the source code corresponding to the set display format.
さらに、設定する編集内容は、所定の処理を実行させる処理コードの挿入または削除を含み、設定する表示形式は、挿入された処理コードを所定の文字または図案などに変換して表示する形式を含むことを特徴とする。 Furthermore, the editing content to be set includes insertion or deletion of a processing code for executing a predetermined process, and the display format to be set includes a format for displaying the inserted processing code after being converted into a predetermined character or design. It is characterized by that.
ここで、前記処理コードとは、所定の処理を実行させるものであり、例えば、プログラム開発時での性能向上や不具合解消に対し、性能測定、テスト、デバッグ等の作業において、測定開始、測定終了、プログラム実行についてのログ出力等の処理を実行させるコードを含む。 Here, the processing code is to execute a predetermined process. For example, in order to improve performance or solve problems at the time of program development, measurement start, measurement end, etc. in work such as performance measurement, test, debugging, etc. And code for executing processing such as log output for program execution.
また、本発明のプログラム開発支援機器、方法およびプログラムは、さらに、ソースコードについてモジュール間の呼び出し関係を解析し、モジュール間の呼び出し関係を示すモジュール関連図を作成する。 Moreover, the program development support apparatus, method, and program of the present invention further analyze the call relationship between modules for the source code and create a module relation diagram showing the call relationship between modules.
さらに、設定する編集内容は、モジュール関連図に含まれるモジュールの中から指定された指定モジュールに対する、処理コードの挿入または削除を含み、設定するモジュール関連図の表示形式は、挿入された処理コードをモジュール関連図においてモジュールとして表示せず、挿入された処理コードを所定の文字または図案などに変換して、モジュール関連図の指定モジュール近辺に配置して表示することを特徴とする。 Furthermore, the editing contents to be set include insertion or deletion of processing codes with respect to the designated module specified from among the modules included in the module related diagram. The display format of the module related diagram to be set is the insertion of the processing code inserted. The module-related diagram is not displayed as a module, but the inserted processing code is converted into a predetermined character or design and arranged near the designated module in the module-related diagram.
本発明によれば、ソースコードのテキストデータに対して、設定された編集内容に従って、所定の処理コードの挿入または削除を行なうため、開発者によるソースコードに対する一時的な処理コードの挿入や削除作業にかかる手間が従来よりも低減可能となる。 According to the present invention, since the predetermined processing code is inserted or deleted from the text data of the source code in accordance with the set editing content, the developer temporarily inserts or deletes the processing code from the source code. It is possible to reduce the time and labor required for the conventional method.
また、本発明によれば、ソースコードの内容を挿入された処理コードを別の文字または図案に変換して表示するため、ソースコード表示におけるプログラム論理の可読性が、処理コードの挿入前と比べて損なわれ難くなると言える。 Further, according to the present invention, since the processing code into which the content of the source code is inserted is converted into another character or design and displayed, the readability of the program logic in the source code display is higher than that before the processing code is inserted. It can be said that it is difficult to damage.
また、本発明によれば、ソースコードを解析してモジュール間の呼び出し関係を示すモジュール関連図を作成する。さらに、モジュール関連図の中からモジュールを指定して処理コードの挿入を設定されると、挿入された処理コードを別の文字または図案などに変換して、指定されたモジュール近辺に配置して表示する。 In addition, according to the present invention, a module relation diagram showing the calling relationship between modules is created by analyzing the source code. In addition, when processing code insertion is set by specifying a module from the module-related diagram, the inserted processing code is converted into another character or design, and placed near the specified module and displayed. To do.
このため、モジュール関連図におけるプログラム論理の可読性が、処理の挿入前と比べて損なわれ難くなると言える。 For this reason, it can be said that the readability of the program logic in the module relation diagram is less likely to be impaired than before the process is inserted.
以下、本発明を実施するための形態について説明する。 Hereinafter, modes for carrying out the present invention will be described.
まず、本実施例におけるプログラム開発支援機器1の概略構成について図1を用いて説明する。
First, a schematic configuration of the program
図1に示す様に本実施例のプログラム開発支援機器1は、制御装置11と、記録装置12と、入出力装置13とを有している。
As shown in FIG. 1, the program
制御装置11は、記録装置12が保持している処理プログラムを実行し、機器全体の動作を制御する装置である。 The control device 11 is a device that executes the processing program held by the recording device 12 and controls the operation of the entire device.
記録装置12は、プログラム開発支援機器1の動作を制御する処理プログラムが格納、記憶された処理部と、処理プログラムが読み書きを行うデータが格納、記憶された記録部128とを有する記憶装置である。
The recording device 12 is a storage device that includes a processing unit that stores and stores a processing program that controls the operation of the program
記録装置12の処理部に記憶されている処理プログラムは、機器制御を行う処理プログラムを記憶している機器制御処理部121と、編集内容を設定する処理プログラムを記憶している編集内容設定処理部122と、表示形式を設定する処理プログラムを記憶している表示形式設定処理部123と、ソースコードを編集する処理プログラムを記憶しているソースコード編集処理部124と、ソースコードを解析する処理プログラムを記憶しているソースコード解析処理部125と、ソースコード画面を作成する処理プログラムを記憶しているソースコード画面作成処理部126と、モジュール関連図を作成する処理プログラムを記憶しているモジュール関連図作成処理部127とを有している。記録装置12の例としては、固定ディスク、可搬メディア、テープ、半導体などがある。
The processing program stored in the processing unit of the recording device 12 includes a device control processing unit 121 that stores a processing program for performing device control, and an editing content setting processing unit that stores a processing program for setting editing content. 122, a display format
機器制御処理部121は、プログラム開発支援機器1の各装置を連携させ、プログラム開発支援機器として動作させる処理プログラム部である。編集内容設定処理部122は、ソースコードに対する処理コードの挿入や削除といった編集内容を設定する処理プログラム部である。表示形式設定処理部123は、ソースコードやモジュール関連図において挿入された処理コードを別の文字または図案に変換して表示するといった表示形式を設定する処理プログラム部である。
The device control processing unit 121 is a processing program unit that causes the devices of the program
ソースコード編集処理部124は、ソースコードのテキストデータを設定された編集内容に従って編集する処理プログラム部である。ソースコード解析処理部125は、ソースコードを解析してモジュール間の呼び出し関係を得る処理プログラム部である。ソースコード画面作成処理部126は、ソースコードの内容を設定された表示形式に従って表示した画面を作成する処理プログラム部である。モジュール関連図作成処理部127は、モジュール間の呼び出し関係を設定された表示形式に従って表示したモジュール関連図を作成する処理プログラム部である。
The source code
記録部128には、テキスト形式のファイルとして保存されたソースコードファイルデータなどが記録される。また、記録部128には、挿入または削除される処理コードについての、ログ出力、測定開始、測定終了などの処理内容や、ソースコードにおける位置や、関数の呼出前、呼出後などの挿入条件といった、編集内容を設定した編集設定データが記録される。
The
また、記録部128には、挿入された処理コードについての、文字、図案、色といったの表示形態や、行頭、行末などのソースコードにおける該当箇所での表示位置や、表示の有無といった、表示形式を設定した表示設定データが記録される。
In addition, the
また、記録部128には、編集内容として設定される内容であり、挿入または削除された処理コードについての、処理内容や位置や挿入条件や、挿入または削除された順番、といった編集履歴データが記録される。また、記録部128には、関数間の呼び出し関係などの解析結果データが記録される。また、記録部128には、ソースコードの内容を表示した画面の情報であるソースコード画面データが記録される。また、記録部128には、モジュール間の呼び出し関係を示すモジュール関連図の情報であるモジュール関連図データが記録される。
The
ここで、モジュールとは、関数や、その関数が含まれるクラス、コンポーネント、オブジェクトおよびライブラリ等の解析単位を示す。 Here, the module indicates a function and a unit of analysis such as a class, a component, an object, and a library including the function.
入出力装置13は、利用者が、プログラム開発支援機器1を操作したり、プログラム開発支援機器1から情報を得たりするインタフェイス装置である。入出力装置13の例としては、キーボード、タッチパッド、マウス、タッチパネル、モニタなどがある。
The input /
次に、本実施例におけるプログラム開発支援機器1の概略動作について、図2を用いて説明する。
Next, a schematic operation of the program
機器制御処理部121が、入出力装置13経由で利用者からの指示を受けるまで待ち、指示を受けたならば、その指示を解析する(ステップ1001)。
The device control processing unit 121 waits until receiving an instruction from the user via the input /
ステップ1001で解析した指示が画面更新指示の場合(ステップ1002の「画面更新指示」)、後述の解析・画面作成処理を行う(ステップ1006)。次に、機器制御処理部121が、記録部128に記録されたソースコード画面データとモジュール関連図データを読み取り、入出力装置13で表示し(ステップ1007)、ステップ1001に戻る。
If the instruction analyzed in
ステップ1001で解析した指示が編集内容設定指示の場合(ステップ1002の「編集内容設定指示」)、編集内容設定処理部122が、設定を指示された編集内容を編集設定データとして記録部128に記録する(ステップ1003)。次に、ソースコード編集処理部124が、記録部128からソースコードファイルデータと編集設定データを読み取り、ソースコードのテキストデータを編集設定データに従って編集し、編集履歴を更新して、編集履歴データとして記録部128に記録する(ステップ1004)。
If the instruction analyzed in
次に、ステップ1001で解析した指示が画面更新指示の場合と同様に、後述の解析・画面作成処理を行い(ステップ1006)、入出力装置13が画面を表示して(ステップ1007)、ステップ1001に戻る。
Next, as in the case where the instruction analyzed in
ステップ1001で解析した指示が表示形式設定指示の場合(ステップ1002の「表示形式設定指示」)、表示形式設定処理部123が、設定を指示された表示形式を表示設定データとして記録部128に記録し(ステップ1005)、ステップ1001に戻る。
When the instruction analyzed in
ステップ1001で解析した指示が終了指示の場合(ステップ1002の「終了指示」)、処理を終了する。
If the instruction analyzed in
次に、本実施例におけるプログラム開発支援機器1の解析・画面作成処理(ステップ1006)の動作について、図3を用いて説明する。
Next, the operation of the analysis / screen creation process (step 1006) of the program
まず、ソースコード画面作成処理部126が、記録部128からソースコードファイルデータと編集履歴データと表示設定データを読み取り、ソースコードの内容を表示設定データに従って表示した画面を作成し、ソースコード画面データとして記録部128に記録する(ステップ2001)。編集履歴データからソースコード中のどの処理コードが挿入されたものかが分かるため、その処理コードを表示設定データに従って表示することができる。
First, the source code screen
次に、ソースコード解析処理部125が、記録部128からソースコードファイルデータと編集履歴データを読み取り、解析を行なって、モジュール間の呼び出し関係を得、解析結果データとして記録部128に記録する(ステップ2001)。
Next, the source code
次に、モジュール関連図作成処理部127が、記録部128から解析結果データと編集履歴データと表示設定データを読み取り、モジュール間の呼び出し関係を表示設定データに従って表示したモジュール関連図を作成し、モジュール関連図データとして記録部128に記録する(ステップ2003)。
Next, the module relation diagram
ここで、編集履歴データからソースコード中のどの処理コードが挿入されたものかが分かるため、その処理コードを一時的に削除した状態で解析を行い、解析結果データを得られた後で、その処理コードを元に戻し、モジュール関連図作成時に、処理コードに該当する部分を表示設定データに従って追加で表示する。 Here, since it can be seen from the editing history data which processing code in the source code has been inserted, the analysis is performed with the processing code temporarily deleted, and the analysis result data is obtained. The processing code is returned to the original, and the portion corresponding to the processing code is additionally displayed according to the display setting data when creating the module relation diagram.
もしくは、挿入された処理コードは残したまま解析を行い、得られた解析結果データからモジュール関連図を作成する時に、編集履歴データを参考にして挿入された処理コードに該当する部分をモジュールとして表示しないようにし、処理コードに該当する部分を表示設定データに従って表示する。 Alternatively, the analysis is performed with the inserted processing code remaining, and when the module relation diagram is created from the obtained analysis result data, the portion corresponding to the inserted processing code is displayed as a module with reference to the editing history data. The portion corresponding to the processing code is displayed according to the display setting data.
なお、ステップ2001と、ステップ2002およびステップ2003は、どちらを先に処理しても良いし、並行して処理しても良い。
Note that either
次に、本実施例における、記録装置12の記録部128の例について、図4、図5、図6を用いて説明する。
Next, an example of the
図4は、記録部128の編集履歴データおよび編集設定データの例を示している。
FIG. 4 shows an example of editing history data and editing setting data in the
図4に示すように、編集履歴データおよび編集設定データは、処理順12811と処理コードの処理内容を示す処理内容12812と、挿入/削除の区別12813と、編集位置12814から成る。図4の例では、一番最初にログ出力の処理コードが全関数の入口に挿入されたことを示している。2番目と3番目の履歴は、プログラム中の処理時間を測定する処理コードについて、関数Bの呼出直前に測定開始処理コードが、関数Cの入口に測定終了処理コードが、それぞれ挿入されたことを示している。4番目の履歴は、関数Xの呼出とログ出力を行なうテストの処理コードが、関数Cの117行目に挿入されたことを示している。最下段は、処理順12811欄が「未編集」であり、編集設定データであることを示している。この編集設定が実際にソースコードファイルに反映されると、処理順5として、履歴に追加される。
As shown in FIG. 4, the edit history data and edit setting data include a
なお、図4では、利用者が指示した編集設定をそのまま保持する例を示したが、例えば編集位置は全て行数に変換して編集履歴および編集設定を保持しても良い。 Although FIG. 4 shows an example in which the editing settings designated by the user are held as they are, for example, all editing positions may be converted into the number of lines to hold the editing history and editing settings.
また、図4では、編集履歴データと編集設定データを同じテーブルに保持する例を示したが、それぞれ別のテーブルに保持しても良い。 FIG. 4 shows an example in which editing history data and editing setting data are held in the same table, but they may be held in different tables.
また、図4では、テスト内容である「関数Xの呼出とログ出力」を処理内容12812に保持する例を示したが、別のデータとして保持しても良い。
FIG. 4 shows an example in which the test content “call of function X and log output” is held in the
また、図4では表していないが、各処理内容の処理コードもしくはその雛形を別に保持しておき、ソースコード編集処理部124がソースコードファイルデータを編集する際に利用しても良い。
Although not shown in FIG. 4, the processing code of each processing content or its template may be held separately and used when the source code
また、図4では表していないが、全ての挿入処理コードを一括で削除できるようにしてもよい。 Although not shown in FIG. 4, all insertion processing codes may be deleted at once.
図5は、記録部128の表示設定データの例を示している。
FIG. 5 shows an example of display setting data of the
図5に示すように、表示設定データは、処理コードの処理内容を示す処理内容12821、ソースコード画面での表示形式12822、モジュール関連図での表示形式12823、色12824から成る。図5の例では、ログ出力の処理について、ソースコード画面ではオレンジ色の図案「丸で囲んだL」で、また、モジュール関連図ではオレンジ色の文字列「ログ」で、それぞれ表示する設定になっている。その他の処理についても同様に、色と、ソースコード画面およびモジュール関連図画面のそれぞれについての表示形式が設定されている。
As shown in FIG. 5, the display setting data includes
なお、図5では、ソースコード画面での表示形式を丸で囲んだ図案とし、モジュール関連図での表示形式を文字列とする例を示したが、別な文字、記号、図案で表示しても良いし、表示しない設定でも良いし、処理コードをそのまま表示させる設定でもよい。 In FIG. 5, an example is shown in which the display format on the source code screen is a circled design and the display format on the module-related diagram is a character string, but it is displayed with another character, symbol, or design. Alternatively, the setting may not be displayed, or the processing code may be displayed as it is.
また、図5では、ソースコード画面での表示形式とモジュール関連図での表示形式に共通の色を設定する例を示したが、それぞれ別の色を設定できるようにしても良い。 FIG. 5 shows an example in which a common color is set for the display format on the source code screen and the display format on the module relation diagram, but different colors may be set.
また、図5では表していないが、図案や文字のフォントを設定できるようにしても良い。 Further, although not shown in FIG. 5, a design or a font of characters may be set.
また、図5では表していないが、挿入された処理コードのソースコード画面での表示を、挿入した行の前の処理コードの行末とするのか、挿入した行の後の処理コードの行頭とするのか、を設定できるようにしても良い。 Although not shown in FIG. 5, the display of the inserted processing code on the source code screen is the end of the processing code before the inserted line or the beginning of the processing code after the inserted line. May be set.
図6は、記録部128の解析結果データの例を示している。
FIG. 6 shows an example of analysis result data of the
図6に示すように、解析結果データは、呼元モジュール12831と呼先モジュール12832から成る。
As shown in FIG. 6, the analysis result data includes a
図6の例では、関数Aが関数Bを呼び出し、関数Bが関数Cを呼び出しているという解析結果を示している。 In the example of FIG. 6, the analysis result that the function A calls the function B and the function B calls the function C is shown.
なお、図6では、挿入された処理コードを一時的に削除した状態で解析を行い、解析結果データを得た後で、その処理コードを元に戻す場合の例を示しているため、挿入された処理コードの情報が解析結果データに含まれていないが、挿入された処理コードは残したまま解析を行い、モジュール関連図を作成する際に表示を考慮する場合は、関数Aがログ出力関数を呼び出す、などの挿入処理コードの情報が解析結果データに含まれる。 Note that FIG. 6 shows an example in which analysis is performed in a state where the inserted processing code is temporarily deleted and analysis result data is obtained, and then the processing code is returned to the original state. If the analysis result data is not included in the analysis result data, but the analysis is performed with the inserted process code left, and the display is considered when creating the module related diagram, function A is the log output function. The information of the insertion processing code such as calling is included in the analysis result data.
また、図6では、モジュールとして関数を設定して解析した場合の例を示したが、関数でなくとも、クラス、コンポーネント、ファイル、オブジェクト、ライブラリ、スレッド、任意設定された関数グループなど、ソースコード解析における解析単位であれば他のものでもよい。例えばグループ単位で解析する場合、解析結果データは各グループに含まれる関数の情報をも持つ。例えばグループMには関数Nと関数Oが含まれている場合に、グループMにログ出力処理を挿入するよう設定すると、関数Nと関数Oにログ出力処理が挿入される。 FIG. 6 shows an example in which a function is set as a module and analyzed. However, source code such as a class, a component, a file, an object, a library, a thread, or a function group that is arbitrarily set may be used. Any other analysis unit may be used. For example, when analyzing in units of groups, the analysis result data also includes information on functions included in each group. For example, when the group M includes the function N and the function O, if the log output process is set to be inserted into the group M, the log output process is inserted into the function N and the function O.
図7は、記録部128のソースコード画面データとモジュール関連図データを入出力装置13が出力した表示例、および記録部128のソースコードファイルデータの例を示している。
FIG. 7 shows a display example in which the input /
図7の表示例は、モジュール関連図において、文字列「ログ」がモジュール「関数A」の左側に点線で接続されていることで、また、ソースコード画面において、関数A内の左上に図案「丸で囲んだL」が示されていることで、実際のソースコードでは、関数Aの入口(開始直後)にログ出力の処理コード(ログ出力文)が挿入されていることを示している。図7のソースコードファイルデータは、一時的な処理コードが挿入された「実際のソースコード」のテキストデータを示している。 The display example of FIG. 7 is that the character string “log” is connected to the left side of the module “function A” by a dotted line in the module relation diagram, and the design “ In the actual source code, the log output processing code (log output sentence) is inserted at the entrance of the function A (immediately after the start). The source code file data in FIG. 7 indicates text data of “actual source code” in which a temporary processing code is inserted.
また、図7の表示例では、モジュール関連図において、モジュール「関数A」からモジュール「関数B」に矢印が伸びており、「関数Bの呼出」処理が関数Aに実装されていることを示している。また、モジュール関連図において、モジュール「関数A」とその矢印の交点の左側に文字列「始点」の点線が接続されており、関数Aにおける関数Bの呼出処理の直前に測定開始処理コードが挿入されていることを示している。 In the display example of FIG. 7, in the module related diagram, an arrow extends from the module “function A” to the module “function B”, and “function B call” processing is implemented in the function A. ing. Also, in the module relation diagram, the dotted line of the character string “start point” is connected to the left of the intersection of the module “function A” and its arrow, and the measurement start processing code is inserted immediately before the function B call processing in function A It has been shown.
また、図7の表示例は、モジュール関連図において、文字列「テスト」がモジュール「関数C」の右側に点線で接続されていることで、また、ソースコード画面において、関数Cの最下段に図案「丸で囲んだT」が示されていることで、実際のソースコードでは、関数Cの出口(関数を抜ける直前)にテストを実行する処理コード(テスト実行文)が挿入されていることを示している。 The display example of FIG. 7 shows that the character string “test” is connected to the right side of the module “function C” with a dotted line in the module relation diagram. In the actual source code, the processing code (test execution statement) that executes the test is inserted at the exit of the function C (immediately before exiting the function) because the design "circle T" is shown. Is shown.
本実施例では、利用者が、モジュールを選択して編集内容を設定することで、ソースコードが編集されて画面が更新される。例えば、図7においてモジュール「関数C」を選択し、図4に示したように「117行目に」「テスト実行処理を」「挿入」するように設定することで、関数Cのソースコードファイルデータの117行目にテスト実行の処理コードが挿入され、関数Cのソースコード画面に図案「丸で囲んだT」が表示される。 In this embodiment, when the user selects a module and sets editing contents, the source code is edited and the screen is updated. For example, by selecting the module “function C” in FIG. 7 and setting it to “insert the test execution process” and “insert” on the 117th line as shown in FIG. 4, the source code file of the function C The processing code for test execution is inserted in line 117 of the data, and the design "T circled" is displayed on the function C source code screen.
なお、図7では、時間軸を左から右、および上から下に取った例を示したが、時間軸は片方でも構わないし、反対向きでも構わない。 Although FIG. 7 shows an example in which the time axis is taken from left to right and from top to bottom, the time axis may be one or the other.
また、図7では表していないが、挿入したログ出力処理コードが出力したログを、元のソースコードにあったログ出力処理コードが出力したログと区別して、別のウィンドウに表示させたり、同じウィンドウに色違いで表示させたりしてもよい。 Although not shown in FIG. 7, the log output by the inserted log output processing code is distinguished from the log output by the log output processing code in the original source code and displayed in another window, or the same It may be displayed in a different color on the window.
以上、本発明の実施形態について説明した。 The embodiment of the present invention has been described above.
なお、本発明の実施形態では、処理部と記録部が同じ記録装置12に記録されているものとして説明したが、処理部と記録部が別の記録装置に記録されていても良い。 In the embodiment of the present invention, the processing unit and the recording unit are described as being recorded in the same recording device 12, but the processing unit and the recording unit may be recorded in different recording devices.
また、本発明の実施形態では、ソースコード解析処理部125とモジュール関連図作成処理部127を別の処理部として説明したが、同一の処理部がソースコードの解析とモジュール関連図の作成を行っても良く、その場合は解析結果データを記録部128に記録しなくとも良い。
In the embodiment of the present invention, the source code
また、本発明の実施形態では、編集内容設定処理部122と表示形式設定処理部123を別の処理部として説明したが、同一の処理部がまとめて設定処理を行なっても良く、その場合は編集設定データと表示設定データは統合されて記録部128に保持される。
In the embodiment of the present invention, the editing content
また、本発明の実施形態では、編集履歴データを記録部128に保持することで、ソースコードに挿入された処理コードの内容や位置を得る場合の例を説明したが、編集履歴データで管理せずに、挿入時に特定フォーマットのコメント文を付加しておき、ソースコード画面作成時やモジュール関連図作成時に、ソースコードからその特定フォーマットのコメント文を検索することで、挿入された処理コードを把握するようにしても良い。この場合は、編集履歴データを記録部128に保持する必要はない。
In the embodiment of the present invention, the example in which the content and position of the processing code inserted in the source code is obtained by holding the editing history data in the
また、利用者が手動で処理コードを挿入する際にこの特定フォーマットのコメント文を付加すれば、プログラム開発支援機器1が自動挿入した処理コードと同様に、削除や表示設定などを行なうことができる。
In addition, if the user adds a comment text in this specific format when manually inserting the processing code, deletion or display setting can be performed in the same manner as the processing code automatically inserted by the program
本発明の実施形態によれば、ソースコードのテキストデータに対して、設定された編集内容に従って処理コードの挿入または削除を行なうため、開発者によるソースコードに対する一時的な処理コードの挿入および削除作業が不要になる。 According to the embodiment of the present invention, the processing code is inserted or deleted from the source code according to the set editing content, so that the developer temporarily inserts and deletes the processing code from the source code. Is no longer necessary.
ここで、前記処理コードとは、所定の処理を実行させるものであり、例えば、プログラム開発時での性能向上や不具合解消に対し、性能測定、テスト、デバッグ等の作業において、測定開始、測定終了、プログラム実行についてのログ出力等の処理を実行させるコードを含む。但し、処理コードは、これらに限定されるものではなく、性能測定、テスト、デバッグ等の作業において、必要とされる処理であれば、適宜、設けられるものであっても良い。 Here, the processing code is to execute a predetermined process. For example, in order to improve performance or solve problems at the time of program development, measurement start, measurement end, etc. in work such as performance measurement, test, debugging, etc. And code for executing processing such as log output for program execution. However, the processing code is not limited to these, and may be appropriately provided as long as it is a processing required in performance measurement, testing, debugging, and the like.
また、本発明の実施形態によれば、ソースコードの内容を挿入された処理コードを別の文字または図案に変換して表示するため、ソースコード表示におけるプログラム論理の可読性が、処理の挿入前と比べて損なわれることがない。 In addition, according to the embodiment of the present invention, since the processing code into which the content of the source code is inserted is converted into another character or design and displayed, the readability of the program logic in the source code display is There is no damage compared to this.
また、本発明の実施形態によれば、ソースコードを解析してモジュール間の呼び出し関係を得、モジュール関連図を作成する。さらに、モジュール関連図の中からモジュールを指定して処理コードの挿入を設定されると、挿入された処理コードを別の文字または図案に変換して、指定されたモジュール近辺に配置して表示する。このため、モジュール関連図におけるプログラム論理の可読性が、処理の挿入前と比べて損なわれることがない。 Further, according to the embodiment of the present invention, the source code is analyzed to obtain a calling relationship between modules, and a module relation diagram is created. In addition, when a module is specified from the module-related diagram and processing code insertion is set, the inserted processing code is converted into another character or design and displayed near the specified module. . For this reason, the readability of the program logic in the module relation diagram is not impaired as compared with that before the process is inserted.
以上のように、本発明の実施形態によれば、開発者によるソースコードに対する一時的な処理コードの挿入および削除作業が不要で、挿入時においてもプログラム論理の可読性が損なわれない、プログラム開発支援機器、方法およびプログラムを提供することができる。 As described above, according to the embodiment of the present invention, it is not necessary for the developer to temporarily insert and delete the processing code from the source code, and program readability is not impaired even at the time of insertion. Equipment, methods and programs can be provided.
1…プログラム開発支援機器、11…制御装置、12…記録装置、13…入出力装置。
DESCRIPTION OF
Claims (4)
当該設定された編集内容に対応してソースコードを編集するソースコード編集手段と、
ソースコードの表示形式を設定する表示形式設定手段と、
当該設定された表示形式に対応してソースコードを表示した画面を作成するソースコード画面作成手段と、
ソースコードについてモジュール間の呼び出し関係を解析するソースコード解析手段と、
モジュール間の呼び出し関係を示すモジュール関連図を作成するモジュール関連図作成手段と、を有し、
前記編集内容は、前記モジュール関連図に含まれるモジュールの中から指定された指定モジュールに対する、処理コードの挿入または削除を含み、
前記表示形式設定手段は、前記モジュール関連図の表示形式を設定し、
当該設定された表示形式は、挿入された処理コードを前記モジュール関連図においてモジュールとして表示せず、前記挿入された処理コードを所定の文字または図案に変換して、前記モジュール関連図の前記指定モジュール近辺に配置して表示することを特徴とするプログラム開発支援機器。 Edit content setting means for setting edit content for source code,
A source code editing means for editing the source code corresponding to the set editing content;
Display format setting means for setting the display format of the source code;
Source code screen creation means for creating a screen displaying source code corresponding to the set display format ;
Source code analysis means for analyzing the call relationship between modules for source code,
Module-related diagram creating means for creating a module-related diagram showing a calling relationship between modules ;
The edited content includes insertion or deletion of a processing code with respect to a designated module designated from among modules included in the module relation diagram,
The display format setting means sets the display format of the module related diagram,
The set display format does not display the inserted processing code as a module in the module-related diagram, converts the inserted processing code into a predetermined character or design, and designates the designated module in the module-related diagram. Program development support equipment characterized by being placed in the vicinity and displayed .
前記処理コードは、開発するプログラムの性能測定、テスト、デバッグを含むプログラム開発作業において、開発するプログラムに対する測定処理の開始、測定処理の終了、開発プログラムの実行についてのログ出力を含む所定の処理を実行させるコードを含むことを特徴とするプログラム開発支援機器。 The program development support device according to claim 1 ,
In the program development work including performance measurement, testing, and debugging of the program to be developed, the processing code performs predetermined processing including start of measurement processing for the program to be developed, termination of the measurement processing, and log output for execution of the development program. A program development support device including a code to be executed.
当該設定された編集内容に対応してソースコードを編集するソースコード編集ステップと、
ソースコードの表示形式を設定する表示形式設定ステップと、
当該設定された表示形式に対応してソースコードを表示した画面を作成するソースコード画面作成ステップと、
ソースコードについてモジュール間の呼び出し関係を解析するソースコード解析ステップと、
モジュール間の呼び出し関係を示すモジュール関連図を作成するモジュール関連図作成ステップと、を有し、
前記編集内容は、前記モジュール関連図に含まれるモジュールの中から指定された指定モジュールに対する、処理コードの挿入または削除を含み、
前記表示形式設定ステップは、前記モジュール関連図の表示形式を設定し、
当該設定された表示形式は、挿入された処理コードを前記モジュール関連図においてモジュールとして表示せず、前記挿入された処理コードを所定の文字または図案に変換して、前記モジュール関連図の前記指定モジュール近辺に配置して表示することを特徴とするプログラム開発支援プログラム。 An editing content setting step for setting editing content for the source code;
A source code editing step for editing the source code corresponding to the set editing content;
A display format setting step for setting the display format of the source code;
A source code screen creation step for creating a screen displaying source code corresponding to the set display format;
Source code analysis step for analyzing the call relationship between modules for the source code,
A module relation diagram creating step for creating a module relation diagram showing a calling relationship between modules ;
The edited content includes insertion or deletion of a processing code with respect to a designated module designated from among modules included in the module relation diagram,
The display format setting step sets a display format of the module relation diagram,
The set display format does not display the inserted processing code as a module in the module-related diagram, converts the inserted processing code into a predetermined character or design, and designates the designated module in the module-related diagram. A program development support program characterized by being displayed in the vicinity.
前記処理コードは、開発するプログラムの性能測定、テスト、デバッグを含むプログラム開発作業において、開発するプログラムに対する測定処理の開始、測定処理の終了、開発プログラムの実行についてのログ出力を含む所定の処理を実行させるコードを含むことを特徴とするプログラム開発支援プログラム。 In the program development work including performance measurement, testing, and debugging of the program to be developed, the processing code performs predetermined processing including start of measurement processing for the program to be developed, termination of the measurement processing, and log output for execution of the development program. A program development support program characterized by including a code to be executed.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008326794A JP5174648B2 (en) | 2008-12-24 | 2008-12-24 | Program development support device, method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008326794A JP5174648B2 (en) | 2008-12-24 | 2008-12-24 | Program development support device, method and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2010152428A JP2010152428A (en) | 2010-07-08 |
JP5174648B2 true JP5174648B2 (en) | 2013-04-03 |
Family
ID=42571487
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008326794A Expired - Fee Related JP5174648B2 (en) | 2008-12-24 | 2008-12-24 | Program development support device, method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5174648B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP7484206B2 (en) | 2020-02-12 | 2024-05-16 | 日本電気株式会社 | Software development support device, software development support method, program, and software development support system |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH07110765A (en) * | 1993-10-13 | 1995-04-25 | Hitachi Ltd | Document editing system |
JP2001022611A (en) * | 1999-07-07 | 2001-01-26 | Nec Corp | Method and system for converting program and recording medium |
JP2004094374A (en) * | 2002-08-29 | 2004-03-25 | Ntt Comware Corp | Logging system |
JP4957017B2 (en) * | 2006-03-02 | 2012-06-20 | 富士通セミコンダクター株式会社 | Performance tuning method and apparatus, program, and storage medium |
JP4879782B2 (en) * | 2007-03-07 | 2012-02-22 | 株式会社エヌ・ティ・ティ・データ | Program profiling method and program |
JP2008293486A (en) * | 2007-04-25 | 2008-12-04 | Hitachi Ltd | Source code analysis device, analysis program, and analysis method |
-
2008
- 2008-12-24 JP JP2008326794A patent/JP5174648B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2010152428A (en) | 2010-07-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8429613B2 (en) | Stepping and application state viewing between points | |
US7721253B2 (en) | Software development support system | |
JP2008293486A (en) | Source code analysis device, analysis program, and analysis method | |
EP1650619A1 (en) | Sequence program editing apparatus | |
US9910576B2 (en) | Automated multimedia content editing | |
CN113448845A (en) | UI automation test method and system | |
CN114897296A (en) | RPA flow labeling method, execution process playback method and storage medium | |
JP5174648B2 (en) | Program development support device, method and program | |
KR20200051167A (en) | Electronic terminal device supporting easy undo processing of electronic document and operating method thereof | |
JP2011204069A (en) | Testing method, and automatic test specification and test data generation apparatus | |
KR101940719B1 (en) | Task graph construct apparatus and method of conversational processing system based on task graph | |
EP0404399A2 (en) | Audio editing system | |
JPS6254337A (en) | Specification displaying system for program hierarchy | |
KR102067431B1 (en) | Source code displaying device, source code didsplaying method, and computer readable recording medium having program performing the same | |
JP2002215391A (en) | Device and method for program analysis and recording medium | |
JPS61160139A (en) | Automatic stepping editor of program list | |
JP2008002825A (en) | Test data editing device | |
JPS60200346A (en) | Production of program test data | |
JP2009042951A (en) | Data extraction method and device from program | |
JP4249038B2 (en) | Document display device, document display method, and document display program | |
CN114490285A (en) | System and method for replaying RPA flow execution process | |
JP2005259169A (en) | Program generation method | |
JP4458491B2 (en) | Test command file creation system, method and program | |
JP3966355B2 (en) | Program generation method and apparatus | |
JP2008047083A (en) | Program preparation support device, and program preparation support program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20110307 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120918 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20120919 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20121114 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20121204 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20121228 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 5174648 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20160111 Year of fee payment: 3 |
|
LAPS | Cancellation because of no payment of annual fees |