JPH03144728A - Device and method for automatic program formation - Google Patents

Device and method for automatic program formation

Info

Publication number
JPH03144728A
JPH03144728A JP28326989A JP28326989A JPH03144728A JP H03144728 A JPH03144728 A JP H03144728A JP 28326989 A JP28326989 A JP 28326989A JP 28326989 A JP28326989 A JP 28326989A JP H03144728 A JPH03144728 A JP H03144728A
Authority
JP
Japan
Prior art keywords
program
source code
existing
component
differential
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.)
Pending
Application number
JP28326989A
Other languages
Japanese (ja)
Inventor
Akira Masuda
明 増田
Koichi Yasutake
剛一 安武
Kazutoshi Sumiya
和俊 角谷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP28326989A priority Critical patent/JPH03144728A/en
Publication of JPH03144728A publication Critical patent/JPH03144728A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To easily grasp the parts of a program by discriminating an existing program source code from a difference program part. CONSTITUTION:The automatic program forming device consists of a source code forming part 11, a specification control part 12, a program specification data base 13, a parts control 14, an existing program source code data base 15, a difference program part data base 16, and a difference program part forming part 17. After extracting a stored program specification, a difference program part written in the program specification is selected and the existing program source code is corrected based upon the difference program part to form a program source code satisfying the program specification. Thus, a part having no selection branch is previously formed and a part consisting of a changing part is independently formed as the difference program part. Consequently, the contents of the program part are easily grasped.

Description

【発明の詳細な説明】 産業上の利用分野 本発明は プログラム設計開発に関し 特にプログラム
部品を用いてプログラム仕様を満足するプログラムソー
スコードを生成するプログラム自動生成装置及び方法に
関すも 従来の技術 一般に 部品生成法によるプログラム自動生成において
(よ 再利用の単位であるプログラム部品を取り込へ 
このプログラム部品に適合化ルールを適用することによ
り、複数あるプログラムソースコードの候補からプログ
ラム仕様に応じたプログラムソースコードを選択すると
いった手順をとる。
[Detailed Description of the Invention] Industrial Field of Application The present invention relates to program design and development, and in particular to an automatic program generation device and method for generating program source code that satisfies program specifications using program parts, but also to conventional technology in general. In automatic program generation using the generation method (to import program parts, which are units of reuse)
By applying the adaptation rule to this program component, a procedure is taken in which a program source code according to the program specifications is selected from a plurality of program source code candidates.

従来の方法で1よ ソースコード生成部が部品管理部に
要求を出して、プログラム部品データベースから取り込
んだプログラム部品を解析し 仕様管理部に要求を出し
て、プログラム部品が有する生成ルールに対応するプロ
グラム仕様をプログラム仕様データベースから取り送水
 先に取り出したプログラム部品に生成ルールを適用し
 プログラムソースコードを生成した 発明が解決しようとする課題 ところカミ 新たにプログラムソースコードが必要にな
ったとき、従来の方法で(よ プログラム部品を新しい
プログラムソースコードが作成できるように修正する必
要があん このような修正は選択肢が増えてくると煩わ
しいものになり、部品も見づらいものになる。
The conventional method is 1. The source code generation section issues a request to the component management section, analyzes the program component imported from the program component database, and sends a request to the specification management section to create a program that corresponds to the generation rules of the program component. Specifications are retrieved from the program specification database and transferred. Application of generation rules to the previously extracted program parts generates program source code. Problems to be solved by the invention When a new program source code is needed, conventional methods are used. (Yo) I need to modify the program parts so that new program source code can be created. Such modifications become cumbersome as the number of options increases, and the parts become difficult to see.

上記課題を解決するために本発明のプログラム生成装置
及び方法(よ 初めに選択肢のない部品を作成しておき
、変更部分のみの部品を差分プログラム部品として別に
作成することによって、プログラム部品の内容を把握し
易くすることを目的とすも 課題を解決するための手段 上記目的を遠戚するために 本発明のプログラム自動生
成装置(よ プログラム仕様を記憶する手段と、前記プ
ログラム仕様を管理する手段と、既存プログラムソース
コードを記憶する手段と、プログラムの仕様によって前
記既存プログラムソースコードを変更する場合にその変
更内容を記述した差分プログラム部品を記憶する手段と
、前記既存プログラムソースコードと前記差分プログラ
ム部品を管理する手段と、前記差分プログラム部品を作
成する手段と、前記プログラム仕楓 前記既存プログラ
ムソースコード、及び 前記差分プログラム部品から新
たにプログラムソースコードを自動生成する手段とを備
えた構成である。
In order to solve the above problems, the program generation device and method of the present invention (1) first create a component with no options, and then separately create a component with only changed parts as a differential program component, thereby changing the contents of the program component. In order to achieve the above-mentioned object in a distant manner, an automatic program generation device of the present invention (including means for storing program specifications and means for managing the program specifications) is provided. , a means for storing an existing program source code; a means for storing a differential program component that describes the changes when the existing program source code is changed according to program specifications; and the existing program source code and the differential program component. The present invention is configured to include: a means for managing the difference program component; a means for creating the difference program component; a means for automatically generating a new program source code from the program source code, the existing program source code, and the difference program component.

作   用 本発明のプログラム自動生成装置及び方法1よ上記構成
により、記憶されているプログラム仕様を取り出した後
、プログラム仕様中に書かれている差分プログラム部品
を選択し この差分プログラム部品に基づいて既存プロ
グラムソースコードを修正することによってプログラム
仕様を満足するプログラムソースコードを生威すも 実施例 第1図は本発明のプログラム自動生成装置及び方法の実
施例を示す構成国であも 11はソースコード生成i 
 12は仕様管理部 13はプログラム仕様データベー
ス 14は部品管理部15は既存プログラムソースコー
ドデータベーXI6は差分プログラム部品データベー入
 I7は差分プログラム部品作成部17である。
Operation: With the above configuration, the program automatic generation device and method 1 of the present invention extracts the stored program specifications, selects the difference program parts written in the program specifications, and generates the existing program based on the difference program parts. Embodiment 1 shows an embodiment of the automatic program generation device and method of the present invention. 11 indicates the source code. generation i
12 is a specification management unit; 13 is a program specification database; 14 is a component management unit 15 is an existing program source code database;

第2図は本発明の実施例の処理の流れを示すフローチャ
ートであも ま哄 ステップ21でソースコード生成部
11が仕様管理部12に要求を出して、ステップ22で
プログラム仕様を取り出す。
FIG. 2 is a flowchart showing the processing flow of the embodiment of the present invention.In step 21, the source code generation section 11 issues a request to the specification management section 12, and in step 22, the program specification is extracted.

プログラム仕様にはプログラム自動生成に使われる既存
ソースコードの番号が示されてあり、これに基づいて、
ステップ23で部品管理部14に既存プログラムソース
コードを取り出す要求を出す。
The program specifications indicate the existing source code numbers used for automatic program generation, and based on this,
In step 23, a request is issued to the component management section 14 to extract the existing program source code.

つぎに ステップ25で取り出された既存プログラムソ
ースコードに対するプログラム仕様がある間プログラム
仕様を取り出す。今度は差分プログラム部品の番号が示
されたあり、これに基づいて、ステップ26でソースコ
ード生成部11は部品管理部14に差分プログラム部品
を取り出す要求を出す。更に ステップ27でソースコ
ード生l1111は取り出された差分プログラム部品の
記述に基づいて既存プログラムソースコードを修正しプ
ログラム仕様を満足するプログラムソースコードを生成
する。
Next, while there are program specifications for the existing program source code extracted in step 25, the program specifications are extracted. This time, the number of the differential program component is shown, and based on this, in step 26, the source code generation section 11 issues a request to the component management section 14 to extract the differential program component. Furthermore, in step 27, the source code generator 1111 modifies the existing program source code based on the description of the extracted differential program component and generates a program source code that satisfies the program specifications.

また 差分プログラム部品を作成する方法は次の通りで
ある。差分プログラム部品作成部17バ新たに必要にな
ったプログラムソースコードを生成する元になる既存プ
ログラムソースコードを部品管理部14に要求する。次
に 取り出した既存プログラムソースコードを修正し 
新しいプログラムソースコードを作威すも そして、既
存プログラムソースコードと新しいプログラムソースコ
ードの差分を取り、差分プログラム部品として差分プロ
グラム部品データベース16に登録すん第3図は従来の
方法によム プログラム生成の例であも 第3図32は
生成されるプログラムソースコード、第3図31は第3
図32のプログラムソースコードを生成するために必要
なプログラム部品である。
The method for creating differential program parts is as follows. The differential program component creation section 17 requests the component management section 14 for existing program source code from which newly required program source code is to be generated. Next, modify the extracted existing program source code.
Create a new program source code. Then, take the difference between the existing program source code and the new program source code and register it as a differential program component in the differential program component database 16. Figure 3 shows how to generate a program using the conventional method. As an example, Fig. 3 32 shows the generated program source code, and Fig. 3 31 shows the third
These are program parts necessary to generate the program source code of FIG. 32.

第3図31のプログラムソースコードに対して、プログ
ラム仕様によって[2]が選ばれたとすると、第3図3
2のようなプログラムソースコードが生成されも もし 第3図34のようなプログラムソースコードが新
たに必要になったとき、従来の方法で(よ第3図31の
部品を第3図33の部品のように修正する必要がある。
Assuming that [2] is selected according to the program specifications for the program source code in Fig. 31, Fig. 3
If a program source code like that shown in Figure 3 is generated and a new program source code like that shown in Figure 3 is required, use the conventional method (by replacing the parts in Figure 3 31 with the parts in Figure 3 33). It is necessary to modify it as follows.

第4図はプログラム生成の例である。第4図42ば生成
されるプログラムソースコード、第4図41は第4図4
2のプログラムソースコードを生成する基になる既存プ
ログラムソースコーK  第4図43〜45はプログラ
ム自動生成のために必要な差分プログラム部品であも 第4図41のような既存プログラムソースコードに対し
て、プログラム仕様によって差分プログラム部品第4図
43が遺ばれたとすると第4図42が生成されも ま7
−、第4図44が選ばれると第3図34が生成されも 
第4図45が選ばれると第4図41の既存プログラムソ
ースコードの3行目が削除されたプログラムソースコー
ドが生成される。
FIG. 4 is an example of program generation. FIG. 442 shows the generated program source code, and FIG. 441 shows the generated program source code.
Existing program source code K that is the basis for generating the program source code of 2. Figures 43 to 45 are differential program parts necessary for automatic program generation. , if the differential program part 43 in Figure 4 is left behind due to the program specifications, then Figure 4 42 will be generated.
-, if Figure 4 44 is selected, Figure 3 34 will be generated.
When FIG. 445 is selected, a program source code in which the third line of the existing program source code of FIG. 41 is deleted is generated.

第4図の実施例によれば 既存プログラムソースコード
にマークが一切ないため把握し易1.%発明の詳細 な説明したように 本発明によれば 既存プログラムソ
ースコードと差分プログラム部品とを分けることによっ
てプログラム部品を把握し易くすることが可能である。
According to the embodiment shown in FIG. 4, there are no marks in the existing program source code, making it easy to understand.1. As described above in detail, according to the present invention, program parts can be easily understood by separating existing program source code and differential program parts.

ま、?、、差分プログラム作成部が差分をとるので、差
分プログラム部品の記述が既存ソースコードの何行目に
関係するか颯既存ソースコードと差分プログラム部品の
対応を意識することなく、差分プログラム部品の作成も
簡単に行える。
Ma,? Since the difference program creation section takes the differences, you can create difference program parts without having to worry about which line of the existing source code the description of the difference program part relates to. It's also easy to do.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の一実施例におけるプログラム自動生成
装置及び方法を示す樋底諷 第2図は本発明の一実施例
におけるプログラム自動生成の手順を示す流れ& 第3
図は従来のプログラム自動生成装置及び方法で用いられ
るプログラム部品と生成されるプログラムソースコード
の例の説明阻第4図は本発明の一実施例において用いら
れる既存プログラムソースフ−1’ 部品と生成されるプログラムソースコードの例の説明図
であも 11・・・ソースコード生成餓 12・・・仕様管理訊 13・・・プログラム仕様データベース14・・・部品
管理部 15・・・既存プログラムソースコードデータベース、 16・・・差分プログラム部品データベーム17・・・
差分プログラム部品作成凰
Fig. 1 shows a program automatic generation device and method according to an embodiment of the present invention. Fig. 2 shows a flowchart showing a procedure for automatic program generation according to an embodiment of the present invention.
The figure shows an example of program parts and generated program source code used in a conventional automatic program generation device and method. This is an explanatory diagram of an example of a program source code to be generated. Database, 16...Difference program parts database 17...
Difference program parts creation screen

Claims (2)

【特許請求の範囲】[Claims] (1)生成されるプログラムのプログラム仕様を記憶す
る手段と、前記プログラム仕様を管理する手段と、既存
プログラムソースコードを記憶する手段と、前記プログ
ラム仕様によって前記既存プログラムソースコードを変
更する場合にその変更内容を記述した差分プログラム部
品を記憶する手段と、前記既存プログラムソースコード
と前記差分プログラム部品を管理する手段と、前記差分
プログラム部品を作成する手段と、前記プログラム仕様
、前記既存プログラムソースコード、及び前記差分プロ
グラム部品から新たにプログラムソースコードを自動生
成する手段とを具備し、前記プログラム仕様から前記差
分プログラム部品を選択し、前記既存プログラムソース
コード中の一部分を前記差分プログラム部品中の一部分
に置き換えることによって前記プログラム仕様を満足す
るプログラムソースコードを自動生成することを特徴と
するプログラム自動生成装置。
(1) means for storing program specifications of a program to be generated; means for managing said program specifications; means for storing existing program source code; means for storing a differential program component that describes changes, means for managing the existing program source code and the differential program component, means for creating the differential program component, the program specification, the existing program source code, and means for automatically generating a new program source code from the differential program component, selecting the differential program component from the program specifications and replacing a portion of the existing program source code with a portion of the differential program component. An automatic program generation device characterized in that a program source code that satisfies the program specifications is automatically generated by replacing the program source code.
(2)生成されるプログラムのプログラム仕様を記憶す
るプログラム仕様データベースと、前記プログラム仕様
を管理する仕様管理部と、既存プログラムソースコード
を記憶する既存プログラムソースコードデータベースと
、前記プログラム仕様によって前記既存プログラムソー
スコードを変更する場合にその変更内容を記述した差分
プログラム部品を記憶する差分プログラム部品データベ
ースと、前記既存プログラムソースコードと前記差分プ
ログラム部品を管理する部品管理部と、前記差分プログ
ラムを作成する差分プログラム部品作成部と、前記プロ
グラム仕様、前記既存プログラムソースコード、及び、
前記差分プログラム部品から新たにプログラムソースコ
ードを自動生成するソースコード生成部からなり、前記
プログラム仕様から前記差分プログラム部品を選択し、
前記既存プログラムソースコード中の一部分を前記差分
プログラム部品中の一部分に置き換えることによって前
記プログラム仕様を満足するプログラムソースコードを
自動生成することを特徴とするプログラム自動生成方法
(2) a program specification database that stores program specifications of programs to be generated; a specification management unit that manages the program specifications; an existing program source code database that stores existing program source codes; a difference program parts database that stores difference program parts that describe the changes when changing the source code; a parts management section that manages the existing program source code and the difference program parts; and a difference program part that creates the difference program. a program component creation unit, the program specifications, the existing program source code, and
comprising a source code generation unit that automatically generates a new program source code from the differential program component, and selects the differential program component from the program specification;
An automatic program generation method, characterized in that a program source code that satisfies the program specifications is automatically generated by replacing a portion of the existing program source code with a portion of the differential program component.
JP28326989A 1989-10-30 1989-10-30 Device and method for automatic program formation Pending JPH03144728A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP28326989A JPH03144728A (en) 1989-10-30 1989-10-30 Device and method for automatic program formation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP28326989A JPH03144728A (en) 1989-10-30 1989-10-30 Device and method for automatic program formation

Publications (1)

Publication Number Publication Date
JPH03144728A true JPH03144728A (en) 1991-06-20

Family

ID=17663270

Family Applications (1)

Application Number Title Priority Date Filing Date
JP28326989A Pending JPH03144728A (en) 1989-10-30 1989-10-30 Device and method for automatic program formation

Country Status (1)

Country Link
JP (1) JPH03144728A (en)

Similar Documents

Publication Publication Date Title
JPH0855019A (en) Visual programming method
KR19980702170A (en) Communication network database construction method and device
CN111679827B (en) H5 page generation method, device, equipment and storage medium
CN103984554B (en) The generation method and device of Software for Design document
JPH05204859A (en) Command storing system for os
JPH07219754A (en) Request definition support device using screen transition diagram
CN104794179A (en) Video quick indexing method and device based on knowledge tree
JPH02123459A (en) Marker entity management
JP2001236215A (en) System control method and information processing system applying the same method and recording medium with its processing program stored
JPH03144728A (en) Device and method for automatic program formation
CN105094845A (en) Process modeling device and method
JPS62197826A (en) Production of system flow specifications
JPS6027941A (en) Identifier generation system
JPS60128530A (en) User menu display processing system
JPS6024637A (en) System flow generating system
JPH10222356A (en) Application generating device and application generating method
JP2000066889A (en) Method and device for supplying difference between source code and design information
CN116009841A (en) File submission conflict management method, system and equipment
JPH0490026A (en) Processing flow chart editing device
JPS60247706A (en) Tracking system for system state of facility group controller
JP2724241B2 (en) Automatic program generator with block diagram parts processing function
JPH04220721A (en) Prograom specification generation device
JPH02148136A (en) System for automatically determining program parts
JPH0498533A (en) Automatic program generating device with macroblock diagram processing function
JPH0210430A (en) Online program generating system