JP2006268121A - Web application system and program for the same - Google Patents

Web application system and program for the same Download PDF

Info

Publication number
JP2006268121A
JP2006268121A JP2005081757A JP2005081757A JP2006268121A JP 2006268121 A JP2006268121 A JP 2006268121A JP 2005081757 A JP2005081757 A JP 2005081757A JP 2005081757 A JP2005081757 A JP 2005081757A JP 2006268121 A JP2006268121 A JP 2006268121A
Authority
JP
Japan
Prior art keywords
data
virtual machine
business
layer
mapping class
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.)
Granted
Application number
JP2005081757A
Other languages
Japanese (ja)
Other versions
JP4695903B2 (en
Inventor
Yoshikuni Sato
好邦 佐藤
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.)
Fuji Electric Co Ltd
FFC Ltd
Original Assignee
Fuji Electric Systems Co Ltd
FFC 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 Fuji Electric Systems Co Ltd, FFC Ltd filed Critical Fuji Electric Systems Co Ltd
Priority to JP2005081757A priority Critical patent/JP4695903B2/en
Publication of JP2006268121A publication Critical patent/JP2006268121A/en
Application granted granted Critical
Publication of JP4695903B2 publication Critical patent/JP4695903B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To dispense with the coding of the processing of extracting data necessary for each business object in a business layer. <P>SOLUTION: When receiving form data 26, a call data transfer object creation processing part 22 of a presentation layer 20 extracts only data necessary for a business object 31 to be called from data included in the form data 26 by reference to a business object definition file 24, and copies it into a data transfer object 28 to transfer it to the business layer 30. <P>COPYRIGHT: (C)2007,JPO&INPIT

Description

本発明は、Webアプリケーションシステムに係り、特にWebアプリケーションを複数の層に分離したものに関する。   The present invention relates to a web application system, and more particularly to a web application separated into a plurality of layers.

Webアプリケーションは、インターネットやイントラネットのように、情報源となるサーバからユーザ端末に画面情報を配信する通信ネットワーク上で使用されるソフトウェアである(例えば、下記特許文献1を参照)。   The Web application is software used on a communication network that distributes screen information from a server serving as an information source to a user terminal, such as the Internet or an intranet (see, for example, Patent Document 1 below).

また、例えば特許文献2は、従来では業務アプリケーションがクライアントとの入出力制御機能、業務処理機能、及びデータベース操作機能を有していたのに対して、I/O層、業務アプリケーション層、データベース層の3つの層に分離したことで、仕様変更の起こり易いクライアントに対する表示様式やデータの入出力の部分(すなわち、I/O層が処理する部分)、及びデータベース操作の部分(すなわち、データベース層が処理する部分)が、業務アプリケーション層から切り離されるので、業務アプリケーション層の生産性が向上する発明を提案している。   Further, for example, in Patent Document 2, a business application conventionally has an input / output control function with a client, a business processing function, and a database operation function, whereas an I / O layer, a business application layer, and a database layer In this way, the display format and data input / output part (that is, the part that the I / O layer processes) and the database operation part (that is, the database layer) Since the processing part) is separated from the business application layer, an invention is proposed in which the productivity of the business application layer is improved.

図8は、このようなWebアプリケーションの構成例を示している。この例では、Webアプリケーション200は、クライアントレイヤ210、プレゼンテーションレイヤ220、ビジネスレイヤ230、および永続化レイヤ240の4つのレイヤからなる。クライアントレイヤ210はクライアント端末上で動作する。プレゼンテーションレイヤ220、ビジネスレイヤ230、および永続化レイヤ240はサーバ上で動作し、Java(登録商標)と呼ばれるオブジェクト指向プログラミング言語で作成される。   FIG. 8 shows a configuration example of such a Web application. In this example, the web application 200 includes four layers: a client layer 210, a presentation layer 220, a business layer 230, and a persistence layer 240. The client layer 210 operates on the client terminal. The presentation layer 220, the business layer 230, and the persistence layer 240 operate on a server and are created in an object-oriented programming language called Java (registered trademark).

クライアントレイヤ210は、Webブラウザに対応し、プレゼンテーションレイヤ220に対して要求を送信する。
プレゼンテーションレイヤ220は、クライアントレイヤ210からの要求に応じて、Web画面を表示するための画面情報をクライアントレイヤ210に送信する。また、プレゼンテーションレイヤ220は、表示されたWeb画面上でユーザによる任意のデータ入力やコマンド指示が行われると、これに応じたフォームデータが送られてくると、ビジネスレイヤ230のビジネスロジックを呼び出す。その際このフォームデータをビジネスレイヤ230に渡す。また、プレゼンテーションレイヤ220は、ログイン時のクライアント認証等の処理も行う。
The client layer 210 corresponds to a Web browser and transmits a request to the presentation layer 220.
The presentation layer 220 transmits screen information for displaying the Web screen to the client layer 210 in response to a request from the client layer 210. The presentation layer 220 calls the business logic of the business layer 230 when any data input or command instruction is given by the user on the displayed Web screen and form data corresponding to the data is sent. At this time, the form data is passed to the business layer 230. The presentation layer 220 also performs processing such as client authentication at the time of login.

ビジネスレイヤ230は、プレゼンテーションレイヤ220からの要求に応じて、Webアプリケーションの業務処理(ビジネスロジック)を実行し、処理結果をプレゼンテーションレイヤ220に転送する。永続化レイヤ240は、ビジネスレイヤ230が処理に用いるデータを、データベース250に格納して永続化する。   The business layer 230 executes a business process (business logic) of the Web application in response to a request from the presentation layer 220 and transfers the processing result to the presentation layer 220. The persistence layer 240 stores data used by the business layer 230 for processing in the database 250 and persists it.

このようにWebアプリケーションでは、サーバ上で動作するソフトウェアを、Webブラウザに画面を表示し入力を受け付ける機能と、画面表示から独立したビジネスロジックを実行する機能と、データベースアクセスに特化した機能とに分割することで、各機能の独立性と汎用性を高めている。   As described above, in the Web application, the software operating on the server is divided into a function for displaying a screen on a Web browser and receiving an input, a function for executing business logic independent of the screen display, and a function specialized for database access. By dividing, the independence and versatility of each function is enhanced.

各機能の独立性を高めれば、アプリケーション開発や修正を機能毎に行うことが可能となり、作業が効率化される。例えば、プレゼンテーションレイヤとビジネスレイヤを分離することで、これらのレイヤのプログラムを効率よく開発することができ、開発コストの削減と品質の確保が期待できる。特に、現実上、ビジネスロジック自体は殆ど変更されることがないのに対して、ユーザインタフェースとしての画面の変更等は、比較的頻繁に行われるが、上記レイヤの分離を行うことで、画面の変更等によってはビジネスレイヤを修正する必要がなくなることが期待できる。
特開2003−15870号公報 特開2002−373148号公報
If the independence of each function is increased, application development and modification can be performed for each function, and the work becomes more efficient. For example, by separating the presentation layer and the business layer, programs of these layers can be efficiently developed, and reduction of development costs and securing of quality can be expected. In particular, in reality, the business logic itself is hardly changed. On the other hand, the change of the screen as the user interface is performed relatively frequently. It can be expected that there will be no need to modify the business layer depending on changes.
JP 2003-15870 A JP 2002-373148 A

ここで、上記の通り、プレゼンテーションレイヤ220は、ビジネスレイヤ230のビジネスロジックを呼び出す際に、フォームデータを渡すが、ビジネスロジックがこのフォームデータの情報全てを必要としているわけではない。この為、ビジネスレイヤ230において、フォームデータからビジネスロジックが必要とするデータのみを抽出する処理の為のコーディング作業を行わなければならなかった。これは非常に手間が掛かるものであった。また、通常、ビジネスレイヤ230は、各システムに特化した処理を行う為、各システム毎にコーディング作業を必要とした。更に、上記画面の変更等によってフォームデータの内容が変更されれば、その都度、コーティングを行わなければならない。この為、上記の期待に反することになるという問題があった。   Here, as described above, the presentation layer 220 passes form data when calling the business logic of the business layer 230, but the business logic does not require all the information of the form data. For this reason, the business layer 230 has to perform a coding operation for processing to extract only the data required by the business logic from the form data. This was very time consuming. In addition, since the business layer 230 normally performs processing specialized for each system, coding work is required for each system. Furthermore, if the content of the form data is changed due to the change of the screen or the like, coating must be performed each time. For this reason, there was a problem that it would be against the above expectations.

また、少なくともプレゼンテーションレイヤ220とビジネスレイヤ230とを別々のJava仮想マシンで実行する構成とし、このJava仮想マシン間のデータ転送を、RMI(Remote Method Invocation)を用いて行うようにした場合、上記ビジネスレイヤ230が、処理結果をプレゼンテーションレイヤ220に返信するのに、RMIの通信上の制約から、転送できないデータが存在するという問題があった。これは、特に、ビジネスレイヤ230からの応答の中にマッピングクラスのインスタンスがある場合に、その中に転送できないデータが存在する場合、そのままではプレゼンテーションレイヤ220側に転送できないものである。従来では、この様なマッピングクラスのインスタンスをプレゼンテーションレイヤ220側に転送できるようにすることは、行われていなかった。   If at least the presentation layer 220 and the business layer 230 are configured to be executed by separate Java virtual machines, and data transfer between the Java virtual machines is performed using RMI (Remote Method Invocation), the above business When the layer 230 returns the processing result to the presentation layer 220, there is a problem that there is data that cannot be transferred due to restrictions on RMI communication. In particular, when there is an instance of the mapping class in the response from the business layer 230, if there is data that cannot be transferred, it cannot be transferred to the presentation layer 220 as it is. Conventionally, it has not been possible to transfer such an instance of the mapping class to the presentation layer 220 side.

本発明の課題は、少なくともクライアントとのインタフェース層とビジネスロジックを実行する層とに分離されたWebアプリケーションシステムにおいて、プレゼンテーションレイヤがビジネスロジックを呼び出す際に、このビジネスロジックが必要とするデータのみを抽出して渡すようにし、あるいはビジネスレイヤによる応答の中にマッピングクラスのインスタンスが含まれている場合でも、プレゼンテーションレイヤ側に渡すことを可能とするWebアプリケーションシステム、そのプログラム等を提供することである。   The object of the present invention is to extract only the data required by the business logic when the presentation layer calls the business logic in the Web application system separated into at least the interface layer with the client and the layer that executes the business logic. Or providing a Web application system, its program, etc. that can be passed to the presentation layer side even when a mapping class instance is included in the response by the business layer.

本発明のアプリケーションサーバは、クライアントとのインタフェースを行う第1の仮想マシンと、各種ビジネスオブジェクトを実行する第2の仮想マシンとを有するアプリケーションサーバにおいて、前記第1の仮想マシンは、予め、前記各ビジネスオブジェクト毎に対応付けて、そのビジネスオブジェクトの処理に必要なデータの識別名を格納しておく定義格納手段と、前記クライアントに任意の画面を表示させて任意のデータ入力を行わせて、これに応じたフォームデータを含むリクエストを受取る画面入出力制御手段と、前記リクエストに応じたビジネスオブジェクトを呼出す際に、前記定義格納手段から該呼出すビジネスオブジェクトが必要とする各データの識別名を取得し、前記フォームデータに含まれる各データのうち、その識別名が前記取得した識別名の何れかと一致するデータのみを前記第2の仮想マシンに転送する呼出用データ転送制御手段とを有するように構成する。   The application server according to the present invention includes an application server including a first virtual machine that interfaces with a client and a second virtual machine that executes various business objects. Definition storage means for storing the identification name of the data necessary for processing the business object in association with each business object, and allowing the client to display an arbitrary screen and inputting arbitrary data. Screen input / output control means for receiving a request including form data corresponding to the request, and when calling the business object corresponding to the request, the identification name of each data required by the calling business object is acquired from the definition storage means. Of the data included in the form data, Alias is configured to have a call data transfer control means for transferring only the data that matches one of the acquired identification name to said second virtual machine.

上記アプリケーションサーバでは、フォームデータの中にビジネスオブジェクトで必要としないデータがある場合でも、第1の仮想マシンにおいて必要なデータのみを抽出して第2の仮想マシン側に渡すようにする。よって、第2の仮想マシン側で必要なデータを抽出する処理の為のコーディング等を行う必要等はない。   The application server extracts only necessary data in the first virtual machine and passes it to the second virtual machine even if there is data that is not required in the business object in the form data. Therefore, there is no need to perform coding for the process of extracting necessary data on the second virtual machine side.

あるいは、本発明のアプリケーションサーバは、クライアントとのインタフェースを行う第1の仮想マシンと、ビジネスオブジェクトを実行する第2の仮想マシンとを有するアプリケーションサーバにおいて、前記第2の仮想マシンは、前記ビジネスオブジェクトから処理結果として各種応答パラメータを渡されると、その中にマッピングクラスのオブジェクトがある場合には、該オブジェクトから転送可能なデータのみを抽出して前記第1の仮想マシンに転送する応答用データ転送手段を有し、前記第1の仮想マシンは、前記応答用データ転送手段により転送された前記転送可能なデータを、マッピングクラスのオブジェクトの形を復元するマッピングクラス復元処理手段を有するように構成する。   Alternatively, the application server of the present invention is an application server having a first virtual machine that interfaces with a client and a second virtual machine that executes a business object, wherein the second virtual machine is the business object When various response parameters are passed from as a processing result, if there is an object of the mapping class in it, only the transferable data is extracted from the object and transferred to the first virtual machine And the first virtual machine is configured to have mapping class restoration processing means for restoring the transferable data transferred by the response data transfer means to restore the shape of the mapping class object. .

上記アプリケーションサーバでは、第2の仮想マシンは例えばORマッピング技術を用いており、処理結果としてマッピングクラスのオブジェクトを第1の仮想マシン側に返す構成である。しかし、第1の仮想マシン−第2の仮想マシン間のデータ転送が、例えばRMI等のように直列化(シリアライズ)するものである場合には、マッピングクラスには直列化できない(すなわち転送できない)データが含まれている為、そのままではマッピングクラスを転送できない。これより、まず、第2の仮想マシン側では、マッピングクラスのオブジェクトから、転送可能なデータのみを抽出して第1の仮想マシンに転送する。第1の仮想マシンは、この転送可能なデータを、マッピングクラスとして利用可能な状態に復元する。転送できないデータは、基本的に、第1の仮想マシン側では必要としないデータである。   In the application server, the second virtual machine uses, for example, an OR mapping technique, and a mapping class object is returned to the first virtual machine as a processing result. However, when the data transfer between the first virtual machine and the second virtual machine is serialized, such as RMI, for example, it cannot be serialized (that is, cannot be transferred) to the mapping class. Since the data is included, the mapping class cannot be transferred as it is. Thus, first, on the second virtual machine side, only transferable data is extracted from the mapping class object and transferred to the first virtual machine. The first virtual machine restores this transferable data to a usable state as a mapping class. Data that cannot be transferred is basically data that is not necessary on the first virtual machine side.

本発明のWebアプリケーションシステム、そのプログラム等によれば、少なくともプレゼンテーションレイヤとビジネスレイヤとが分離されたWebアプリケーションシステムにおいて、プレゼンテーションレイヤがビジネスロジックを呼び出す際に、このビジネスロジックが必要とするデータのみを抽出して渡すようにすることができ、ビジネスレイヤにおいてコーディング作業を行う必要がなくなる。   According to the web application system, the program thereof, and the like of the present invention, in a web application system in which at least the presentation layer and the business layer are separated, when the presentation layer calls the business logic, only the data required by the business logic is obtained. It can be extracted and passed, eliminating the need for coding work in the business layer.

あるいは、ビジネスレイヤによる応答の中にマッピングクラスのインスタンスが含まれている場合でも、プレゼンテーションレイヤ側に転送可能とすることができ、更に、プレゼンテーションレイヤにおいて転送されてきたデータからマッピングクラスのインスタンスを復元することで、プレゼンテーションレイヤにおいて処理結果として実質的にマッピングクラスを取得することができ、これを用いて処理結果表示等を行えるようになる。   Alternatively, even if a mapping class instance is included in the response by the business layer, it can be transferred to the presentation layer, and the mapping class instance is restored from the data transferred in the presentation layer. Thus, the mapping class can be substantially acquired as the processing result in the presentation layer, and the processing result can be displayed using this.

以下、図面を参照しながら、本発明の実施の形態について説明する。
図1は、本例のWebアプリケーションシステムの機能ブロック図である。
本発明の第1の特徴は、図1に示すプレゼンテーションレイヤ20からビジネスレイヤ30のビジネスロジック(ビジネスオブジェクト)の呼出しに係るものである。第2の特徴は、ビジネスレイヤ30からプレゼンテーションレイヤ20に対する処理結果の返信に係るものである。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a functional block diagram of the Web application system of this example.
The first feature of the present invention relates to a call of business logic (business object) of the business layer 30 from the presentation layer 20 shown in FIG. The second feature relates to the return of the processing result from the business layer 30 to the presentation layer 20.

プレゼンテーションレイヤ20、ビジネスレイヤ30は、それぞれ別のJava仮想マシン上にある。プレゼンテーションレイヤ20、ビジネスレイヤ30は、アプリケーションサーバ2上に実装される。これは、図1では1つのサーバ2上に2つのレイヤ20,30が実装されているが、各レイヤ20,30がそれぞれ別々のサーバ上に実装されてもよい。クライアントレイヤ10は、クライアントマシン1上に実装される。また、データベース40は不図示のデータベースサーバにある。これらクライアントマシン1、アプリケーションサーバ2、データベースサーバは、何らかのネットワーク(例えばLAN等)に接続されており、相互に通信可能となっている。   The presentation layer 20 and the business layer 30 are on different Java virtual machines. The presentation layer 20 and the business layer 30 are mounted on the application server 2. In FIG. 1, two layers 20 and 30 are implemented on one server 2, but each layer 20 and 30 may be implemented on a separate server. The client layer 10 is mounted on the client machine 1. The database 40 is in a database server (not shown). The client machine 1, the application server 2, and the database server are connected to some network (for example, a LAN) and can communicate with each other.

図1において、プレゼンテーションレイヤ20における画面入出力コントロールオブジェクト21は、基本的には、クライアントレイヤ10のWebブラウザ11上に表示させる画面の入出力制御を行うものである。画面入出力コントロールオブジェクト21は、クライアントレイヤ10のWebブラウザ11上に何らかの入力画面を表示させて、クライアントマシン1のユーザに、この入力画面に従って任意のデータを入力させる。また、例えば更新、検索等のコマンドを入力させる。これに応じてクライアントマシン1からリクエスト(フォームデータ26やコマンド)が送られてくると、画面入出力コントロールオブジェクト21は、このフォームデータ26等を呼出用データ転送オブジェクト作成処理部22に渡す。   In FIG. 1, a screen input / output control object 21 in the presentation layer 20 basically performs input / output control of a screen displayed on the Web browser 11 of the client layer 10. The screen input / output control object 21 displays some input screen on the Web browser 11 of the client layer 10 and allows the user of the client machine 1 to input arbitrary data according to the input screen. Also, for example, commands such as update and search are input. In response to this, when a request (form data 26 or command) is sent from the client machine 1, the screen input / output control object 21 passes the form data 26 and the like to the calling data transfer object creation processing unit 22.

呼出用データ転送オブジェクト作成処理部22は、上記フォームデータ26を受け取ると、記憶装置23(ハードディスク、メモリ等)に記憶されているビジネスオブジェクト定義ファイル24を参照することで、クライアントからのリクエストに対応して呼び出すべきビジネスオブジェクト31が必要とするデータのみを、データ転送オブジェクト28にコピーしてビジネスレイヤ30側に渡すようにする。これが第1の特徴である。   When the call data transfer object creation processing unit 22 receives the form data 26, the call data transfer object creation processing unit 22 responds to a request from the client by referring to the business object definition file 24 stored in the storage device 23 (hard disk, memory, etc.). Only the data required by the business object 31 to be called is copied to the data transfer object 28 and passed to the business layer 30 side. This is the first feature.

尚、上記レイヤ20−30間の通信、すなわちJava仮想マシン間の通信には、RMI(Remote Method Invocation)を用いる。良く知られているように、RMI を使うと、別の Java仮想マシン上で実行されるオブジェクトのメソッドを呼び出したり、パラメータや返り値の受け渡しができる。特にJavaRMIを用いれば、例えば基本クラスの引数に派生クラスを渡したり、オブジェクト自身をバイトストリームにできるためオブジェクトの受け渡しが非常に手軽にできるという利点がある。   Note that RMI (Remote Method Invocation) is used for communication between the layers 20-30, that is, communication between Java virtual machines. As is well known, RMI allows you to call methods on objects that run on other Java virtual machines and pass parameters and return values. In particular, using Java RMI has an advantage that, for example, a derived class can be passed as an argument of a base class or an object itself can be converted into a byte stream, so that the object can be passed very easily.

ビジネスレイヤ30側では、呼び出されたビジネスオブジェクト31が、所定の処理を実行し、データベース40のマッピングクラス33を獲得する。尚、実際には“マッピングクラスのインスタンス(オブジェクト)”であるが、本説明では省略して“マッピングクラス”と記す場合もある。尚、図1では省略してあるが、実際には図2に示すように、永続化レイヤ214がデータベース202へアクセスして、処理結果としてデータベースマッピングクラス33(244)を作成している。   On the business layer 30 side, the called business object 31 executes a predetermined process and acquires the mapping class 33 of the database 40. Note that although it is actually an “instance (object) of a mapping class”, it may be abbreviated as “mapping class” in this description. Although omitted in FIG. 1, actually, as shown in FIG. 2, the persistence layer 214 accesses the database 202 and creates a database mapping class 33 (244) as a processing result.

第2の特徴は、このマッピングクラス33をプレゼンテーションレイヤ20に返信して、処理結果をクライアントのWebブラウザ11に表示させる処理に係る。すなわち、まず、マッピングクラス33は、通信の制約上、そのままではプレゼンテーションレイヤ20側に転送できないものである。つまり、マッピングクラス33には、転送可能なデータと転送できないデータとがある。すなわち、ビジネスレイヤ30−プレゼンテーションレイヤ20間のデータ転送オブジェクトの受け渡しは、上記の通りRMIによる通信の為、所謂“オブジェクト直列化”(シリアライズ)して行う。オブジェクト直列化は、オブジェクトとそこから参照されているオブジェクトを、バイトストリームにコード化するものである。そして、マッピングクラス33には、オブジェクト直列化できないデータが含まれている場合があり、これが上記転送できないデータである。そして、マッピングクラス33においてオブジェクト直列化できるデータ、すなわち転送可能なデータは、プロパティ名と値であることが分かっている。   The second feature relates to processing for returning the mapping class 33 to the presentation layer 20 and displaying the processing result on the Web browser 11 of the client. That is, first, the mapping class 33 cannot be transferred to the presentation layer 20 as it is because of communication restrictions. That is, the mapping class 33 includes data that can be transferred and data that cannot be transferred. That is, the transfer of the data transfer object between the business layer 30 and the presentation layer 20 is performed by so-called “object serialization” (serialization) for communication by RMI as described above. Object serialization is to encode an object and the object referenced from it into a byte stream. The mapping class 33 may include data that cannot be serialized, which is the data that cannot be transferred. The data that can be object-serialized in the mapping class 33, that is, the data that can be transferred is known to be the property name and value.

そこで、まず、上記マッピングクラス33を獲得したビジネスオブジェクト31は、このマッピングクラス33を含む所定の応答パラメータを、応答用データ転送オブジェクト作成処理部32に渡す。応答用データ転送オブジェクト作成処理部32は、この応答パラメータをRMI等によりプレゼンテーションレイヤ20に転送するが、応答パラメータの中にマッピングクラス33が含まれている場合には、このマッピングクラス33の中で転送可能なデータのみを抽出してプレゼンテーションレイヤ20に転送する。   Therefore, first, the business object 31 that has acquired the mapping class 33 passes a predetermined response parameter including the mapping class 33 to the response data transfer object creation processing unit 32. The response data transfer object creation processing unit 32 transfers the response parameter to the presentation layer 20 by RMI or the like. When the mapping class 33 is included in the response parameter, Only the transferable data is extracted and transferred to the presentation layer 20.

プレゼンテーションレイヤ20では、マッピングクラス復元処理部25が、上記転送可能なデータを、マッピングクラスとして利用可能な状態に復元して(マッピングクラス27を生成(復元)して)、これを画面入出力コントロールオブジェクト21に渡す。これによって、画面入出力コントロールオブジェクト21から見ると、処理結果としてマッピングクラスが返ってきたことになる。そして、クライアントのWebブラウザ上に処理結果を表示させる。但し、マッピングクラス27は、マッピングクラス33の内容を完全に復元したものではない。   In the presentation layer 20, the mapping class restoration processing unit 25 restores the transferable data to a usable state as a mapping class (generates (restores) the mapping class 27), and performs this on the screen input / output control. Pass to object 21. Thus, when viewed from the screen input / output control object 21, the mapping class is returned as the processing result. Then, the processing result is displayed on the Web browser of the client. However, the mapping class 27 is not a complete restoration of the contents of the mapping class 33.

尚、上記呼出用データ転送オブジェクト作成処理部22、マッピングクラス復元処理部25、応答用データ転送オブジェクト作成処理部32による処理は、アプリケーションサーバ2の記憶装置23に記憶されている所定のアプリケーションプログラムを、不図示のCPU等が読出し・実行することにより実現させる。   The calling data transfer object creation processing unit 22, the mapping class restoration processing unit 25, and the response data transfer object creation processing unit 32 execute a predetermined application program stored in the storage device 23 of the application server 2. This is realized by reading and executing a CPU (not shown) or the like.

図2は、図1の特徴に係るWebアプリケーション全体の基本的な構成例を示している。
図1に示す構成は、図2に示す基本構成に基づいて、呼出用データ転送オブジェクト作成処理部22、ビジネスオブジェクト定義ファイル24、応答用データ転送オブジェクト作成処理部32、マッピングクラス復元処理部25等の各種機能部が備えられている。
FIG. 2 shows a basic configuration example of the entire Web application according to the features of FIG.
The configuration shown in FIG. 1 is based on the basic configuration shown in FIG. The various functional parts are provided.

図2のWebアプリケーション101は、クライアントレイヤ111、プレゼンテーションレイヤ112、ビジネスレイヤ113、および永続化レイヤ114からなる。クライアントレイヤ111は、クライアントマシン1上で動作するWebブラウザ121を有する。プレゼンテーションレイヤ112、ビジネスレイヤ113、および永続化レイヤ114は、通信ネットワーク(LAN等)を介してクライアントマシン1と接続されたアプリケーションサーバ2で動作する。クライアントレイヤ111、プレゼンテーションレイヤ112、ビジネスレイヤ113が、上記クライアントレイヤ10、プレゼンテーションレイヤ20、ビジネスレイヤ30に相当する。   2 includes a client layer 111, a presentation layer 112, a business layer 113, and a persistence layer 114. The client layer 111 has a Web browser 121 that operates on the client machine 1. The presentation layer 112, the business layer 113, and the persistence layer 114 operate on the application server 2 connected to the client machine 1 via a communication network (LAN or the like). The client layer 111, the presentation layer 112, and the business layer 113 correspond to the client layer 10, the presentation layer 20, and the business layer 30.

プレゼンテーションレイヤ112は、単独のJava仮想マシンで実行され、ビジネスレイヤ113と永続化レイヤ114は、同一のJava仮想マシンで実行される。プレゼンテーションレイヤ112のJava仮想マシンとビジネスレイヤ113および永続化レイヤ114のJava仮想マシンは、同一のアプリケーションサーバ上にあってもよく、別々のアプリケーションサーバ上にあってもよい。また、データベース102は図1のデータベース40に相当し、不図示のデータベースサーバ上にある。このデータベースサーバは、通信ネットワークを介してアプリケーションサーバ等と接続される。   The presentation layer 112 is executed by a single Java virtual machine, and the business layer 113 and the persistence layer 114 are executed by the same Java virtual machine. The Java virtual machine of the presentation layer 112 and the Java virtual machine of the business layer 113 and the persistence layer 114 may be on the same application server or on different application servers. The database 102 corresponds to the database 40 in FIG. 1 and is on a database server (not shown). This database server is connected to an application server or the like via a communication network.

プレゼンテーションレイヤ112は、プレゼンテーションの基盤技術としてJSF(Java Server Faces )132を用いたアプリケーションサーバ131を有する。JSF132は、ビジネスロジックとプレゼンテーションデザインの分離を目的とした、Webアプリケーションのインタフェースのためのフレームワークである。   The presentation layer 112 includes an application server 131 that uses a Java Server Faces (JSF) 132 as a basic technology for presentation. The JSF 132 is a web application interface framework for the purpose of separating business logic and presentation design.

JSF132は、グラフィカルユーザインタフェース(GUI)でWebアプリケーションを開発できるツールであり、Webアプリケーションを構成する画面コンポーネントをマウスでドラッグ&ドロップすることにより、画面フォーム上に配置できる。また、コンポーネント毎に、イベントハンドラに相当するManaged Bean133を記述することができる。   The JSF 132 is a tool capable of developing a Web application with a graphical user interface (GUI), and can be arranged on a screen form by dragging and dropping screen components constituting the Web application with a mouse. In addition, a managed bean 133 corresponding to an event handler can be described for each component.

ビジネスレイヤ113は、システムの業務要件に関する処理(ビジネスロジック)を実行する。ビジネスレイヤ113は、プレゼンテーションレイヤ112からの処理要求を、ビジネスロジックの実装クラス(ビジネスオブジェクト142)にマッピングする。ビジネスレイヤ113は、ビジネスオブジェクト142を生成するビジネスロジックコンテナ141を有し、ビジネスオブジェクト142は、所定のビジネスロジックを実行する。ビジネスオブジェクト142としては、例えば、POJO(Plain Old Java Object )が用いられる。これにより、ビジネスオブジェクト142の開発・試験時に特別な試験環境を必要とせず、また再利用性が高まる。   The business layer 113 executes processing (business logic) related to business requirements of the system. The business layer 113 maps the processing request from the presentation layer 112 to a business logic implementation class (business object 142). The business layer 113 includes a business logic container 141 that generates a business object 142, and the business object 142 executes predetermined business logic. For example, POJO (Plain Old Java Object) is used as the business object 142. This eliminates the need for a special test environment when developing and testing the business object 142, and improves reusability.

ビジネスロジックコンテナ141は、プレゼンテーションレイヤ112から処理要求が届くと、この処理要求に対応するビジネスオブジェクト142を生成して業務処理を依頼する。そして、業務処理が完了すると、そのビジネスオブジェクト142は廃棄される。同時に複数の処理要求が届いた場合は、複数のビジネスオブジェクト142が同時に生成される。   When receiving a processing request from the presentation layer 112, the business logic container 141 generates a business object 142 corresponding to the processing request and requests a business process. When the business process is completed, the business object 142 is discarded. When a plurality of processing requests arrive at the same time, a plurality of business objects 142 are generated simultaneously.

永続化レイヤ114は、データベース102にアクセスするためにORマッピング145を有する。ORマッピング145は、Javaオブジェクトモデルのデータ表現を、SQL(Structured Query Language )ベースのスキーマを持つリレーショナルデータモデルにマッピングする。また、ORマッピング145は、データベース102のスキーマからデータアクセスオブジェクト(DAO)143を生成する。   The persistence layer 114 has an OR mapping 145 for accessing the database 102. The OR mapping 145 maps the data representation of the Java object model to a relational data model having a SQL (Structured Query Language) based schema. The OR mapping 145 generates a data access object (DAO) 143 from the schema of the database 102.

アプリケーションサーバ131は、Webブラウザ121から要求を受信すると、その要求をManaged Bean133に通知し、Managed Bean133は、ビジネスロジックコンテナ141を呼び出す。これを受けて、ビジネスロジックコンテナ141は、ビジネスオブジェクト142を生成する。   When the application server 131 receives a request from the Web browser 121, the application server 131 notifies the managed bean 133 of the request, and the managed bean 133 calls the business logic container 141. In response to this, the business logic container 141 generates a business object 142.

生成されたビジネスオブジェクト142は、データベースアクセスを行うためにDAO143を獲得し、DAO143を用いて、データベース102の表に相当するマッピングクラス144を獲得する。   The generated business object 142 acquires a DAO 143 for performing database access, and acquires a mapping class 144 corresponding to the table of the database 102 using the DAO 143.

ビジネスオブジェクト142は、処理結果として、上記獲得したマッピングクラス144を含む所定の応答パラメータを、プレゼンテーションレイヤ20に返す。プレゼンテーションレイヤ20におけるManaged Bean133が、受信した処理結果に基づいて、Webブラウザ121に処理結果を通知して表示させる。尚、Managed Bean133が、図1の画面入出力コントロールオブジェクト21に相当する。   The business object 142 returns a predetermined response parameter including the acquired mapping class 144 to the presentation layer 20 as a processing result. Based on the received processing result, the managed bean 133 in the presentation layer 20 notifies the Web browser 121 of the processing result and displays it. The managed bean 133 corresponds to the screen input / output control object 21 in FIG.

このようなWebアプリケーション101とは別に、プレゼンテーションレイヤを持たないアプリケーション103、104も設けられる。アプリケーション103、104は、Webアプリケーション101とは異なり、設定時刻に処理を起動したり、常に処理を実行し続けるタイプのものが多い。   Apart from such a Web application 101, applications 103 and 104 having no presentation layer are also provided. Unlike the Web application 101, the applications 103 and 104 are often of a type that starts processing at a set time or always executes processing.

アプリケーション103は、ビジネスレイヤ151および永続化レイヤ152からなり、ビジネスレイヤ151はバッチプロセス153を有し、永続化レイヤ152はORマッピング154を有する。アプリケーション104は、ビジネスレイヤ161および永続化レイヤ162からなり、ビジネスレイヤ161はバッチプロセス163を有し、永続化レイヤ162はORマッピング164を有する。   The application 103 includes a business layer 151 and a persistence layer 152. The business layer 151 has a batch process 153, and the persistence layer 152 has an OR mapping 154. The application 104 includes a business layer 161 and a persistence layer 162. The business layer 161 has a batch process 163, and the persistence layer 162 has an OR mapping 164.

バッチプロセス153、163は、例えば、他サーバとの連携処理、夜間に実行されるデータ処理、ハードウェアとの通信処理等を行う。また、ビジネスオブジェクト142や他のバッチプロセスからイベントの通知を受け取ったり、他のバッチプロセスにイベントを通知したりすることができる。   The batch processes 153 and 163 perform, for example, cooperation processing with other servers, data processing executed at night, communication processing with hardware, and the like. It is also possible to receive event notifications from the business object 142 and other batch processes, and to notify events to other batch processes.

以下、上記図1に示す第1、第2の特徴について、図1及び図3以降を参照しつつ、具体例を挙げながら、更に詳細に説明する。
まず、第1の特徴について説明する。特に図示しないが、ここでは一例として、ブラウザ11には社員情報管理画面が表示されているものとし、この画面には社員番号、名前、住所、年齢、部署名、及び特記事項の6つの項目があるものとする。これら各項目に対しては、例えばUser_id、Name、Address、Age、Section、及びCommentという識別名が割り当てられており、上記フォームデータ26は、例えば図3(a)に示すように、これら各識別名に、ユーザが入力したデータ又は画面に表示されたデータが対応付けられた形式となっている。尚、上記6つの項目は、全てが入力項目とは限らず、単に表示されている項目も有り得る。よって、例えば「検索」を実行させる場合であって上記6つの項目の一部を検索キーとして入力させた場合には、検索を実行するビジネスオブジェクト31は、この検索キーとしてのデータのみ必要であり、他の項目は必要ないことになる。
Hereinafter, the first and second features shown in FIG. 1 will be described in more detail with reference to FIG. 1 and FIG.
First, the first feature will be described. Although not shown in particular, here, as an example, it is assumed that the employee information management screen is displayed on the browser 11, and this screen includes six items of employee number, name, address, age, department name, and special notes. It shall be. For example, identification names User_id, Name, Address, Age, Section, and Comment are assigned to each of these items. The form data 26 includes, for example, as shown in FIG. The name is associated with the data input by the user or the data displayed on the screen. Note that all of the above six items are not necessarily input items, and there may be items that are simply displayed. Therefore, for example, when “search” is executed and a part of the above six items is input as a search key, the business object 31 that executes the search only needs data as the search key. Other items will not be necessary.

また、ビジネスオブジェクト定義ファイル24には、各ビジネスオブジェクト毎に対応付けて、そのビジネスオブジェクトの実行に必要なデータの識別名が格納される。図3(b)には、図3(a)に示す例に対して、User_id、Name、及びSectionのみを必要とするビジネスオブジェクトに関する定義例を示してある。これらは、例えば上記検索キーに相当するものである。   Further, the business object definition file 24 stores an identification name of data necessary for executing the business object in association with each business object. FIG. 3B shows a definition example related to a business object that requires only User_id, Name, and Section, compared to the example shown in FIG. These correspond to, for example, the search key.

図4に、呼出用データ転送オブジェクト作成処理部22によって実行される処理のフローチャート図を示す。以下、上記図3(a)、(b)に示す例を用いつつ、このフローチャート処理について説明する。   FIG. 4 shows a flowchart of processing executed by the call data transfer object creation processing unit 22. Hereinafter, this flowchart process will be described using the example shown in FIGS. 3 (a) and 3 (b).

呼出用データ転送オブジェクト作成処理部22は、画面入出力コントロールオブジェクト21が上記図3(a)の様なフォームデータを受取ってメモリ等に格納した後、この記憶されたフォームデータから、任意の1つのデータの識別名を取得する(ステップS11)。また、ビジネスオブジェクト定義ファイル24から、呼び出すビジネスオブジェクトが必要とするデータの識別名一覧(例えば上記図3(b))を取得して(ステップS12)、この識別名一覧の中に上記ステップS11で取得した識別名があるか否かを判定し(ステップS13)、ある場合には(ステップS13,YES)、ステップS11で取得した識別名に対応するデータをフォームデータ26から取得してデータ転送オブジェクト28にコピーする(ステップS14)。無い場合には(ステップS13,NO)、コピーは行わない。   After the screen input / output control object 21 receives the form data as shown in FIG. 3A and stores it in a memory or the like, the call data transfer object creation processing unit 22 receives an arbitrary one from the stored form data. The identification name of one data is acquired (step S11). Further, a list of identification names of data required by the business object to be called (for example, FIG. 3B) is acquired from the business object definition file 24 (step S12). It is determined whether or not there is an acquired identification name (step S13). If there is (step S13, YES), data corresponding to the identification name acquired in step S11 is acquired from the form data 26 to obtain a data transfer object. 28 is copied (step S14). If there is no copy (step S13, NO), copying is not performed.

以上の処理を、フォームデータ26にある全てのデータについて実行するまで、繰返し行う。
上記処理について、図3(a)、(b)に示す例を用いて説明するならば、まず最初は、ステップS11において識別名‘User_id’が取得され、図3(b)に示す識別名一覧は‘User_id’、‘Name’、‘Section’であり、‘User_id’があるので、ステップS13の判定はYESとなり、識別名‘User_id’とそのデータ‘1234’がデータ転送オブジェクト28にコピーされる。次の識別名‘Name’も同様に、図3(b)に示す識別名一覧中に存在するので、識別名‘Name’とそのデータ‘山田太郎’が、データ転送オブジェクト28にコピーされる。識別名‘Section’についても同様である。
The above process is repeated until all the data in the form data 26 is executed.
If the above process is described using the examples shown in FIGS. 3A and 3B, first, the identification name “User_id” is acquired in step S11, and the identification name list shown in FIG. Are “User_id”, “Name”, and “Section”, and since there is “User_id”, the determination in step S13 is YES, and the identification name “User_id” and its data “1234” are copied to the data transfer object 28. . Similarly, since the next identification name “Name” exists in the list of identification names shown in FIG. 3B, the identification name “Name” and its data “Taro Yamada” are copied to the data transfer object 28. The same applies to the identifier “Section”.

一方、識別名‘Address’、‘Age’、‘Comment’については、識別名一覧中に存在しないので、そのデータのデータ転送オブジェクト28へのコピーは行われない。
そして、データ転送オブジェクト28をRMI等によってビジネスレイヤ30側に転送する。
On the other hand, since the identification names “Address”, “Age”, and “Comment” do not exist in the list of identification names, the data is not copied to the data transfer object 28.
Then, the data transfer object 28 is transferred to the business layer 30 side by RMI or the like.

以上、第1の特徴によれば、プレゼンテーションレイヤにおいて、ビジネスレイヤ30のビジネスオブジェクト31を呼び出す際に、このビジネスオブジェクト31が必要とするデータのみを抽出して渡すことができ、従来のようにビジネスレイヤ30で手間が掛かるコーディング作業を行う必要がない。ビジネスレイヤ30は、通常、各システム毎に特化したものが構築されるので、各システム毎にビジネスレイヤ30のコーディング作業が必要となる。また、ビジネスレイヤ30のビジネスロジックは、通常、あまり変更されないので、ビジネスレイヤ30のコーディング作業は、レイヤ構築後は、あまり行われないで済むはずである。しかし、画面の変更等によってフォームデータが変われば、必要なデータを抽出する処理の為のコーディング作業をやり直す必要があった。これに対して、第1の特徴によれば、プレゼンテーションレイヤ20の修正で対応できるようになる。また、プレゼンテーションレイヤ20は各システムに特化したものではないので、汎用性の高いものとなる。   As described above, according to the first feature, when the business object 31 of the business layer 30 is called in the presentation layer, only the data required by the business object 31 can be extracted and passed. There is no need to perform coding work that takes time and labor at the layer 30. Since the business layer 30 is usually specialized for each system, the business layer 30 needs to be coded for each system. In addition, since the business logic of the business layer 30 is usually not changed much, the coding work of the business layer 30 should not be performed much after the layer construction. However, if the form data changes due to changes in the screen, etc., it is necessary to redo the coding work for the process of extracting the necessary data. On the other hand, according to the first feature, the presentation layer 20 can be corrected. Further, since the presentation layer 20 is not specialized for each system, it is highly versatile.

次に、以下、第2の特徴に係る応答用データ転送オブジェクト作成処理部32とマッピングクラス復元処理部25について説明する。
図5は、応答用データ転送オブジェクト作成処理部32の処理フローチャート図である。
Next, the response data transfer object creation processing unit 32 and the mapping class restoration processing unit 25 according to the second feature will be described below.
FIG. 5 is a processing flowchart of the response data transfer object creation processing unit 32.

図6は、マッピングクラス復元処理部25の処理フローチャート図である。
まず、応答用データ転送オブジェクト作成処理部32は、上記呼び出されたビジネスオブジェクト31が処理を実行した結果として応答パラメータを返してくると、これら各応答パラメータ毎に、図5に示す処理を実行する。すなわち、まず、処理対象の応答パラメータからそのタイプ(型)を取得する(ステップS21)。そして、当該応答パラメータがマッピングクラスのタイプ(型)を継承しているオブジェクトであるか否かを判定する(ステップS22)。これは、具体的な一例としては、例えば永続化レイヤ214において“hibernate” (http://www.hibernate.org/)を使用している場合には、“net.sf.hibernate.Lifecycle”を継承(extends)しているオブジェクトであるか否かを判定するものである。そして、マッピングクラスのタイプを継承しているオブジェクトである場合には(ステップS22,YES)、このオブジェクトから、転送可能なデータであるプロパティ名と値を全て取得して、これらをマッピングクラス送信用オブジェクトにコピーし、このマッピングクラス送信用オブジェクトをデータ転送オブジェクト34に格納する(ステップS23)。マッピングクラスのオブジェクトではない場合には(ステップS22,NO)、この応答パラメータをデータ転送オブジェクト34にコピーする(ステップS24)。尚、マッピングクラス送信用オブジェクトには、これがマッピングクラス送信用オブジェクトであることを示すタイプ(型)が与えられている。また尚、転送可能なデータはプロパティ名と値のみであり、これら以外のデータは全て転送できないデータであるので、転送できないデータの具体例は特に示さない。
FIG. 6 is a processing flowchart of the mapping class restoration processing unit 25.
First, when the called business object 31 returns a response parameter as a result of executing the process, the response data transfer object creation processing unit 32 executes the process shown in FIG. 5 for each response parameter. . That is, first, the type is acquired from the response parameter to be processed (step S21). Then, it is determined whether or not the response parameter is an object inheriting the mapping class type (step S22). As a specific example, for example, if “hibernate” (http://www.hibernate.org/) is used in the persistence layer 214, “net.sf.hibernate.Lifecycle” This is to determine whether the object is inherited (extends). If the object inherits the mapping class type (step S22, YES), all the property names and values that can be transferred are acquired from this object, and these are used for mapping class transmission. The object is copied to the object, and this mapping class transmission object is stored in the data transfer object 34 (step S23). If it is not an object of the mapping class (step S22, NO), this response parameter is copied to the data transfer object 34 (step S24). The mapping class transmission object is given a type indicating that this is a mapping class transmission object. In addition, since the data that can be transferred is only the property name and value, and all other data cannot be transferred, a specific example of data that cannot be transferred is not particularly shown.

そして、データ転送オブジェクト34を、RMIにより、プレゼンテーションレイヤ20側に転送する。
上記データ転送オブジェクト34を受取ったマッピングクラス復元処理部25は、データ転送オブジェクト34に格納された各応答パラメータ毎に、図6に示す処理を実行する。すなわち、データ転送オブジェクト34から処理対象の応答パラメータのタイプ(型)を取得する(ステップS31)。そして、このタイプ(型)により、上記マッピングクラス送信用オブジェクトであるか否かを判定する(ステップS32)。処理対象の応答パラメータが上記マッピングクラス送信用オブジェクトである場合には(ステップS32,YES)、マッピングクラス送信用オブジェクトに格納されたデータ(すなわちプロパティ名と値)を全て取得し、これを用いて新しくマッピングクラスを生成(復元)する(ステップS33)。
Then, the data transfer object 34 is transferred to the presentation layer 20 side by RMI.
The mapping class restoration processing unit 25 that has received the data transfer object 34 executes the process shown in FIG. 6 for each response parameter stored in the data transfer object 34. That is, the type of response parameter to be processed is acquired from the data transfer object 34 (step S31). Then, based on this type, it is determined whether or not the object is a mapping class transmission object (step S32). When the response parameter to be processed is the mapping class transmission object (step S32, YES), all the data (that is, the property name and value) stored in the mapping class transmission object are acquired and used. A new mapping class is generated (restored) (step S33).

但し、復元するといっても、上記転送できないデータまでもが復元されるわけではない。生成されたマッピングクラスは、上記転送可能なデータであるプロパティ名と値のみを含み、他のデータは空であるという、形式的にマッピングクラスの形となっているものとなる。つまり、上記の通り、マッピングクラスとして利用可能な状態に復元しているものである。しかし、画面入出力コントロールオブジェクト21が必要とするデータ(Webブラウザ11に処理結果を表示させる為の必要なデータ)は、通常、上記プロパティ名と値のみであるので、特に問題はない。また、絶対にマッピングクラスの形に復元させなければならないというものでもない。しかし、本システムでは、図2に示すように、永続化レイヤ114にORマッピング技術を採用しているので、応答はマッピングクラスの形で渡されるのが自然である。また、マッピングクラスは、例えばデータベース102の表に相当するものであり、マッピングクラスを用いれば表を表示させる処理が行い易い。よって、マッピングクラスとして利用可能な状態に復元することが望ましい。   However, even if the data is restored, the data that cannot be transferred is not restored. The generated mapping class includes only the property name and value, which are the transferable data, and is formally in the form of a mapping class in which other data is empty. That is, as described above, it is restored to a state where it can be used as a mapping class. However, since the data necessary for the screen input / output control object 21 (data necessary for displaying the processing result on the Web browser 11) is usually only the property name and value, there is no particular problem. Nor does it have to be restored to the mapping class. However, in this system, as shown in FIG. 2, since the OR mapping technique is adopted for the persistence layer 114, it is natural that the response is passed in the form of a mapping class. Further, the mapping class corresponds to, for example, a table in the database 102. If the mapping class is used, a process for displaying the table can be easily performed. Therefore, it is desirable to restore to a state that can be used as a mapping class.

そして、生成したマッピングクラスを、画面入出力コントロールオブジェクト21に渡す。また、処理対象の応答パラメータがマッピングクラス送信用オブジェクトではない場合には(ステップS32,NO)、この応答パラメータをそのまま画面入出力コントロールオブジェクト21に渡す。   Then, the generated mapping class is passed to the screen input / output control object 21. If the response parameter to be processed is not a mapping class transmission object (NO in step S32), the response parameter is passed to the screen input / output control object 21 as it is.

これによって、画面入出力コントロールオブジェクト21は、処理結果をWebブラウザ11に表示させる。
以上説明したように、第2の特徴によれば、ビジネスレイヤ30からの応答の中にマッピングクラスがあり、そのままではプレゼンテーションレイヤ20側に転送できない場合でも、転送可能とできる。更に、これをマッピングクラスの形に復元して画面入出力コントロールオブジェクト21に渡すことで、ORマッピング技術を活かす形で処理結果の表示等を行わせることができる。
As a result, the screen input / output control object 21 displays the processing result on the Web browser 11.
As described above, according to the second feature, even when there is a mapping class in the response from the business layer 30 and it cannot be transferred to the presentation layer 20 side as it is, it can be transferred. Furthermore, by restoring this to the form of the mapping class and passing it to the screen input / output control object 21, it is possible to display the processing result in a form that makes use of the OR mapping technique.

尚、最後に、図7に、図1のビジネスレイヤ30におけるビジネスオブジェクト定義ファイル34の具体的な記述例を示す。このビジネスオブジェクト定義ファイル34自体は、上記特徴とは直接関係しないものであり、従来より、ビジネスレイヤ30において、各ビジネスオブジェクト毎に、そのビジネスオブジェクトが扱えるパラメータの型を定義しておくことは、行われていた。   Finally, FIG. 7 shows a specific description example of the business object definition file 34 in the business layer 30 of FIG. The business object definition file 34 itself is not directly related to the above-described characteristics. Conventionally, in the business layer 30, for each business object, the parameter type that can be handled by the business object has been defined. It was done.

図7に示すように、全てのビジネスオブジェクト31に共通する記述部分と、各ビジネスオブジェクト31毎の定義記述部分とがある。各ビジネスオブジェクト31毎の定義記述部分には、そのビジネスオブジェクト31が扱えるパラメータ(応答パラメータ)の型(タイプ)が定義されている。図示の例では、例えばInteger型、String型、配列型等が定義されている。応答パラメータとしてマッピングクラスを扱えるビジネスオブジェクト31の場合には、当然、マッピングクラスの型(タイプ)が定義されており、上記図5の処理は、基本的にはこの様なビジネスオブジェクト31を対象としている。また、Java等では、マッピングクラスのインスタンス(オブジェクト)はマッピングクラスの型(タイプ)を継承しているものである。   As shown in FIG. 7, there are a description part common to all business objects 31 and a definition description part for each business object 31. In the definition description part for each business object 31, the type (type) of the parameter (response parameter) that can be handled by the business object 31 is defined. In the illustrated example, for example, an Integer type, a String type, an array type, and the like are defined. In the case of a business object 31 that can handle a mapping class as a response parameter, naturally, the type (type) of the mapping class is defined, and the processing of FIG. 5 basically targets such a business object 31. Yes. In Java and the like, an instance (object) of a mapping class inherits the type (type) of the mapping class.

これより、上記の通り、図5のステップS21、S22の処理では、処理対象の応答パラメータの型(タイプ)がマッピングクラスの型(タイプ)である場合には、判定YESとなり、ステップS23の処理が行われることになる。   Thus, as described above, in the processing of steps S21 and S22 in FIG. 5, if the response parameter type to be processed is the mapping class type, the determination is YES, and the processing of step S23 is performed. Will be done.

尚、図1のビジネスオブジェクト定義ファイル24とビジネスオブジェクト定義ファイル34は、同一の内容を示している(入力パラメータ、応答パラメータを併せて定義している)。もし、プレゼンテーションレイヤ20とビジネスレイヤ30とが別々のサーバマシン上に実装される構成である場合には、定義ファイル34をコピーして定義ファイル24を作成するが、内容は同一である。   The business object definition file 24 and the business object definition file 34 in FIG. 1 show the same contents (input parameters and response parameters are defined together). If the presentation layer 20 and the business layer 30 are configured to be mounted on different server machines, the definition file 34 is created by copying the definition file 34, but the contents are the same.

本例のWebアプリケーションシステムの機能ブロック図である。It is a functional block diagram of the Web application system of this example. 図1の特徴に係るWebアプリケーション全体の具体的な構成例を示している。A specific configuration example of the entire Web application according to the feature of FIG. 1 is shown. (a)はフォームデータ、(b)はビジネスオブジェクト定義ファイルの具体例を示す図である。(A) is a form data, (b) is a figure which shows the specific example of a business object definition file. 呼出用データ転送オブジェクト作成処理部による処理フローチャート図である。It is a process flowchart figure by the data transfer object creation process part for a call. 応答用データ転送オブジェクト作成処理部の処理フローチャート図である。It is a process flowchart figure of the data transfer object creation process part for a response. マッピングクラス復元処理部の処理フローチャート図である。It is a process flowchart figure of a mapping class restoration process part. ビジネスオブジェクト定義ファイルに記述される内容の具体例である。It is a specific example of contents described in a business object definition file. 従来のWebアプリケーションの構成例である。It is a structural example of the conventional web application.

符号の説明Explanation of symbols

1 クライアントマシン
2 アプリケーションサーバ
10 クライアントレイヤ
11 Webブラウザ
20 プレゼンテーションレイヤ
21 画面入出力コントロールオブジェクト
22 呼出用データ転送オブジェクト作成処理部
23 記憶装置
24 ビジネスオブジェクト定義ファイル
25 マッピングクラス復元処理部
26 フォームデータ
27 マッピングクラス
28 データ転送オブジェクト
30 ビジネスレイヤ
31 ビジネスオブジェクト
32 応答用データ転送オブジェクト作成処理部
33 マッピングクラス
34 データ転送オブジェクト
40 データベース
101 Webアプリケーション
102 データベース
103,104 アプリケーション
111 クライアントレイヤ
112 プレゼンテーションレイヤ
113 ビジネスレイヤ
114 永続化レイヤ
121 Webブラウザ
131 アプリケーションサーバ
132 JSF(Java Server Faces )
133 Managed Bean
141 ビジネスロジックコンテナ
142 ビジネスオブジェクト
143 データアクセスオブジェクト(DAO)
144 マッピングクラス
145 ORマッピング
151 ビジネスレイヤ
152 永続化レイヤ
153 バッチプロセス
154 ORマッピング
161 ビジネスレイヤ
162 永続化レイヤ
163 バッチプロセス
164 ORマッピング
DESCRIPTION OF SYMBOLS 1 Client machine 2 Application server 10 Client layer 11 Web browser 20 Presentation layer 21 Screen input / output control object 22 Calling data transfer object creation processing unit 23 Storage device 24 Business object definition file 25 Mapping class restoration processing unit 26 Form data 27 Mapping class 28 Data Transfer Object 30 Business Layer 31 Business Object 32 Response Data Transfer Object Creation Processing Unit 33 Mapping Class 34 Data Transfer Object 40 Database 101 Web Application 102 Database 103, 104 Application 111 Client Layer 112 Presentation Layer 113 Business Layer 114 Zokuka layer 121 Web browser 131 application server 132 JSF (Java Server Faces)
133 Managed Bean
141 Business Logic Container 142 Business Object 143 Data Access Object (DAO)
144 Mapping class 145 OR mapping 151 Business layer 152 Persistence layer 153 Batch process 154 OR mapping 161 Business layer 162 Persistence layer 163 Batch process 164 OR mapping

Claims (6)

クライアントとのインタフェースを行う第1の仮想マシンと、各種ビジネスオブジェクトを実行する第2の仮想マシンとを有するアプリケーションサーバにおいて、
前記第1の仮想マシンは、
予め、前記各ビジネスオブジェクト毎に対応付けて、そのビジネスオブジェクトの処理に必要なデータの識別名を格納しておく定義格納手段と、
前記クライアントに任意の画面を表示させて任意のデータ入力を行わせて、これに応じたフォームデータを含むリクエストを受取る画面入出力制御手段と、
前記リクエストに応じたビジネスオブジェクトを呼出す際に、前記定義格納手段から該呼出すビジネスオブジェクトが必要とする各データの識別名を取得し、前記フォームデータに含まれる各データのうち、その識別名が前記取得した識別名の何れかと一致するデータのみを前記第2の仮想マシンに転送する呼出用データ転送制御手段と、
を有することを特徴とするアプリケーションサーバ。
In an application server having a first virtual machine that interfaces with a client and a second virtual machine that executes various business objects,
The first virtual machine is
Definition storage means for storing in advance an identification name of data necessary for processing the business object in association with each business object;
Screen input / output control means for displaying an arbitrary screen on the client and performing arbitrary data input, and receiving a request including form data according to the data;
When calling a business object in response to the request, an identification name of each data required by the calling business object is acquired from the definition storage unit, and among the data included in the form data, the identification name is the Call data transfer control means for transferring only data that matches any of the acquired identification names to the second virtual machine;
An application server comprising:
クライアントとのインタフェースを行う第1の仮想マシンと、ビジネスオブジェクトを実行する第2の仮想マシンとを有するアプリケーションサーバにおいて、
前記第2の仮想マシンは、前記ビジネスオブジェクトから処理結果として各種応答パラメータを渡されると、その中にマッピングクラスのオブジェクトがある場合には、該オブジェクトから転送可能なデータのみを抽出して前記第1の仮想マシンに転送する応答用データ転送手段を有し、
前記第1の仮想マシンは、前記応答用データ転送手段により転送された前記転送可能なデータを、マッピングクラスのオブジェクトの形を復元するマッピングクラス復元処理手段を有することを特徴とするアプリケーションサーバ。
In an application server having a first virtual machine that interfaces with a client and a second virtual machine that executes a business object,
When various response parameters are passed as processing results from the business object, the second virtual machine extracts only data that can be transferred from the object if there is an object of the mapping class in the second virtual machine. Response data transfer means for transferring to one virtual machine,
The application server, wherein the first virtual machine has mapping class restoration processing means for restoring the transferable data transferred by the response data transfer means to restore the shape of a mapping class object.
前記マッピングクラスのオブジェクトにおいて転送できないデータは、直列化できないデータであることを特徴とする請求項2記載のアプリケーションサーバ。   3. The application server according to claim 2, wherein the data that cannot be transferred in the mapping class object is data that cannot be serialized. 前記第2の仮想マシンは、ORマッピング技術によってデータベースへのアクセスを行いマッピングクラスを生成する永続化レイヤを有しており、前記ビジネスオブジェクトは該マッピングクラスを獲得するものであることを特徴とする請求項2記載のアプリケーションサーバ。   The second virtual machine has a persistence layer that generates a mapping class by accessing a database by an OR mapping technique, and the business object acquires the mapping class. The application server according to claim 2. コンピュータに、
クライアントとのインタフェースを行う第1の仮想マシンと、各種ビジネスオブジェクトを実行する第2の仮想マシンとを有するWebアプリケーションにおける該第1の仮想マシンにおいて、
予め、前記各ビジネスオブジェクト毎に対応付けて、そのビジネスオブジェクトの処理に必要なデータの識別名を格納しておく定義格納機能と、
前記クライアントに任意の画面を表示させて任意のデータ入力を行わせて、これに応じたフォームデータを含むリクエストを受取る画面入出力制御機能と、
前記リクエストに応じたビジネスオブジェクトを呼出す際に、前記定義格納機能から該呼出すビジネスオブジェクトが必要とする各データの識別名を取得し、前記フォームデータに含まれる各データのうち、その識別名が前記取得した識別名の何れかと一致するデータのみを前記第2の仮想マシンに転送する呼出用データ転送制御機能と
を実現させる為のプログラム。
On the computer,
In the first virtual machine in a web application having a first virtual machine that interfaces with a client and a second virtual machine that executes various business objects,
A definition storage function that stores in advance an identification name of data necessary for processing the business object in association with each business object,
A screen input / output control function for displaying an arbitrary screen on the client and performing arbitrary data input, and receiving a request including form data corresponding thereto; and
When a business object corresponding to the request is called, an identification name of each data required by the calling business object is acquired from the definition storage function, and among the data included in the form data, the identification name is the A call data transfer control function for transferring only data that matches one of the acquired identification names to the second virtual machine.
コンピュータに、
クライアントとのインタフェースを行う第1の仮想マシンと、各種ビジネスオブジェクトを実行する第2の仮想マシンとを有するWebアプリケーションにおいて、
前記第2の仮想マシンに、前記ビジネスオブジェクトから処理結果として各種応答パラメータを渡されると、その中にマッピングクラスのオブジェクトがある場合には、該オブジェクトから転送可能なデータのみを抽出して前記第1の仮想マシンに転送する応答用データ転送機能を実現させ、
前記第1の仮想マシンに、前記応答用データ転送機能により転送された前記転送可能なデータを、マッピングクラスのオブジェクトの形を復元するマッピングクラス復元処理機能を実現させる為のプログラム。
On the computer,
In a web application having a first virtual machine that interfaces with a client and a second virtual machine that executes various business objects,
When various response parameters are passed as processing results from the business object to the second virtual machine, if there is an object of the mapping class in it, only the transferable data is extracted from the object and the second virtual machine is extracted. Realize response data transfer function to transfer to one virtual machine,
A program for causing the first virtual machine to realize a mapping class restoration processing function for restoring the transferable data transferred by the response data transfer function to restore the shape of a mapping class object.
JP2005081757A 2005-03-22 2005-03-22 Web application system and program thereof Expired - Fee Related JP4695903B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005081757A JP4695903B2 (en) 2005-03-22 2005-03-22 Web application system and program thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005081757A JP4695903B2 (en) 2005-03-22 2005-03-22 Web application system and program thereof

Publications (2)

Publication Number Publication Date
JP2006268121A true JP2006268121A (en) 2006-10-05
JP4695903B2 JP4695903B2 (en) 2011-06-08

Family

ID=37204072

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005081757A Expired - Fee Related JP4695903B2 (en) 2005-03-22 2005-03-22 Web application system and program thereof

Country Status (1)

Country Link
JP (1) JP4695903B2 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009087093A (en) * 2007-09-28 2009-04-23 Bank Of Tokyo-Mitsubishi Ufj Ltd Application development support device and program
WO2009096045A1 (en) 2008-01-30 2009-08-06 The Bank Of Tokyo-Mitsubishi Ufj, Ltd. Application development support device, program, and recording medium
JP2011019130A (en) * 2009-07-09 2011-01-27 Ricoh Co Ltd Image processing apparatus, display control method, and display control program
JP2012064250A (en) * 2012-01-04 2012-03-29 Bank Of Tokyo-Mitsubishi Ufj Ltd Online system, program generation device and screen control program generation device
JP5128673B2 (en) * 2009-09-17 2013-01-23 株式会社三菱東京Ufj銀行 Application development support apparatus, program, and recording medium
CN111290808A (en) * 2020-01-13 2020-06-16 中国平安财产保险股份有限公司 Product module display method and device based on data transmission object and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004110362A (en) * 2002-09-18 2004-04-08 Ntt Comware Corp Application development supporting system and application development supporting method and computer program
JP2004110361A (en) * 2002-09-18 2004-04-08 Ntt Comware Corp Application providing system, method therefore, and computer program for application providing system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004110362A (en) * 2002-09-18 2004-04-08 Ntt Comware Corp Application development supporting system and application development supporting method and computer program
JP2004110361A (en) * 2002-09-18 2004-04-08 Ntt Comware Corp Application providing system, method therefore, and computer program for application providing system

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009087093A (en) * 2007-09-28 2009-04-23 Bank Of Tokyo-Mitsubishi Ufj Ltd Application development support device and program
WO2009096045A1 (en) 2008-01-30 2009-08-06 The Bank Of Tokyo-Mitsubishi Ufj, Ltd. Application development support device, program, and recording medium
US8504981B2 (en) 2008-01-30 2013-08-06 The Bank Of Tokyo-Mitsubishi Ufj, Ltd. Application development support device, program, and recording medium
JP2011019130A (en) * 2009-07-09 2011-01-27 Ricoh Co Ltd Image processing apparatus, display control method, and display control program
JP5128673B2 (en) * 2009-09-17 2013-01-23 株式会社三菱東京Ufj銀行 Application development support apparatus, program, and recording medium
JPWO2011033644A1 (en) * 2009-09-17 2013-02-07 株式会社三菱東京Ufj銀行 Application development support apparatus, program, and recording medium
JP2012064250A (en) * 2012-01-04 2012-03-29 Bank Of Tokyo-Mitsubishi Ufj Ltd Online system, program generation device and screen control program generation device
CN111290808A (en) * 2020-01-13 2020-06-16 中国平安财产保险股份有限公司 Product module display method and device based on data transmission object and storage medium
CN111290808B (en) * 2020-01-13 2023-10-20 中国平安财产保险股份有限公司 Product module display method and device based on data transmission object and storage medium

Also Published As

Publication number Publication date
JP4695903B2 (en) 2011-06-08

Similar Documents

Publication Publication Date Title
US7684964B2 (en) Model and system state synchronization
US7814459B2 (en) System and method for automated on demand replication setup
US8849987B2 (en) Automated discovery of a topology of a distributed computing environment
US7363628B2 (en) Data centric and protocol agnostic workflows for exchanging data between a workflow instance and a workflow host
US7725907B2 (en) Default value initialization of business objects
US7886035B2 (en) Profile service based deployment configuration
US20040205179A1 (en) Integrating design, deployment, and management phases for systems
JP2005516272A (en) Computing system and method for implicitly committing non-saved data for world wide web applications
JP2005528667A (en) Method, apparatus and system for implementing a framework for supporting web-based applications
CA2627270A1 (en) System and method for displaying data on a thin client
JP2005505050A (en) Method, apparatus and system for performing view caching in a framework for supporting web-based applications
US20120130906A1 (en) Deployment mechanism for non-versioning business process artifacts
US20150089408A1 (en) Method and framework for content viewer integrations
JP4695903B2 (en) Web application system and program thereof
US20120167016A1 (en) Dynamic Determination Of Navigation Targets In A Flexible User Interface Environment
US11397569B2 (en) Deploying micro frontends to different clusters from a single repository
CN111104103A (en) Visualization method and system for software editing microservice
US20100250568A1 (en) Method for Installing a Web Package Within a Manufacturing Executing System
US20180032329A1 (en) Customized runtime environment
US7509341B2 (en) Stateless-object software environment
US8161055B2 (en) Filter extraction in a service registry environment
JP2008269515A (en) Method for dynamically generating image layout by parameter
US8041722B2 (en) Refining collections of entities in a service registry environment
JP2006268125A (en) Application server and its program
JP2006268123A (en) Information sharing device

Legal Events

Date Code Title Description
A625 Written request for application examination (by other person)

Free format text: JAPANESE INTERMEDIATE CODE: A625

Effective date: 20080215

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: 20110222

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20110228

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140304

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 4695903

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140304

Year of fee payment: 3

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313115

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140304

Year of fee payment: 3

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313115

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees