JP2013058065A - Control method of control device, and program - Google Patents

Control method of control device, and program Download PDF

Info

Publication number
JP2013058065A
JP2013058065A JP2011195746A JP2011195746A JP2013058065A JP 2013058065 A JP2013058065 A JP 2013058065A JP 2011195746 A JP2011195746 A JP 2011195746A JP 2011195746 A JP2011195746 A JP 2011195746A JP 2013058065 A JP2013058065 A JP 2013058065A
Authority
JP
Japan
Prior art keywords
printer
control
interface
application program
called
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
JP2011195746A
Other languages
Japanese (ja)
Other versions
JP2013058065A5 (en
JP5906620B2 (en
Inventor
Masatoshi Nakazawa
雅俊 中澤
Hiroshi Jintsugawa
啓 神通川
Kyoji Hirayama
恭士 平山
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.)
Seiko Epson Corp
Original Assignee
Seiko Epson Corp
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 Seiko Epson Corp filed Critical Seiko Epson Corp
Priority to JP2011195746A priority Critical patent/JP5906620B2/en
Priority to CN201210250667.8A priority patent/CN102915215B/en
Priority to US13/561,605 priority patent/US9110615B2/en
Publication of JP2013058065A publication Critical patent/JP2013058065A/en
Publication of JP2013058065A5 publication Critical patent/JP2013058065A5/en
Application granted granted Critical
Publication of JP5906620B2 publication Critical patent/JP5906620B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To achieve a reduction in effort related to development of objects that depend on a device in a device control program.SOLUTION: A host computer 10 in which objects operate under an operating system 12 includes: a printer CO21 that provides a POS application program 11 with an interface for each type of device; a printer SO22 that executes a process by a device unit while providing the printer CO21 with the interface for each type of device; and a wrapper SO30 that executes the process of at least a part of a method called by the printer CO21 instead of the printer SO22 and, when the printer CO21 calls other method, calls a method of the printer SO22 while calling the method of the printer SO22 on the basis of a result of the process having been executed.

Description

本発明は、プリンター等のデバイスを制御する制御装置の制御方法、及び、プログラムに関する。   The present invention relates to a control method for a control device that controls a device such as a printer, and a program.

オブジェクト指向プログラミングによるコンポーネントベースのプログラムあるいはソフトウェア(以降においてはオブジェクト)は、オペレーティングシステム上で稼動する再利用可能なソフトウェアであり、オブジェクトを用いて多種多様なシステムが開発されている。例えば、マイクロソフト(登録商標)社が提供する.NET Frameworkを基盤としたオペレーティングシステム(OS)では、クライアントであるアプリケーションプログラム(コンテナアプリケーション)がオブジェクトを使用可能とする環境を提供する広範囲な機能を有するオペレーティングシステムである。
例えば、POSシステムは多種多様な周辺装置により組み立てられるシステムの1つであり、パーソナルコンピューターなどの中心となるホストコンピューターにディスプレイ、プリンター、スキャナー、ドロワー、カードリーダーなど様々な入デバイスが接続されることによりシステムが構築される(例えば、特許文献1参照)。特許文献1には、オブジェクトを用い構築されたPOSシステムであってパーソナルコンピューターベースのフレキシブルな構成のPOSシステムが開示されている。
Component-based programs or software (hereinafter referred to as objects) based on object-oriented programming are reusable software that runs on an operating system, and various systems have been developed using objects. For example, provided by Microsoft (registered trademark). An operating system (OS) based on the NET Framework is an operating system having a wide range of functions for providing an environment in which an application program (container application) as a client can use an object.
For example, the POS system is one of the systems assembled by a wide variety of peripheral devices, and various input devices such as displays, printers, scanners, drawers, card readers are connected to a central host computer such as a personal computer. Thus, a system is constructed (see, for example, Patent Document 1). Patent Document 1 discloses a POS system constructed using an object and having a flexible configuration based on a personal computer.

オブジェクト分散型のPOSシステムでは、様々なメーカーにより提供されるPOSアプリケーションプログラムと、プリンター、スキャナー、ドロワーなどの周辺装置(デバイス)の種類単位(デバイスクラス単位)に供給されるコントロールオブジェクトと、周辺装置毎、すなわち、デバイス毎に供給されるサービスオブジェクトとを備えている。例えばPOSアプリケーションプログラムがプリンターから出力するときは、データがプリンターのコントロールオブジェクト(CO)に渡され、さらに、出力するプリンターのメーカーおよび機種に対応したサービスオブジェクト(SO)に渡され、OSを介してプリンターに供給される。   In an object distributed POS system, a POS application program provided by various manufacturers, a control object supplied to a type unit (device class unit) of peripheral devices (devices) such as a printer, a scanner, and a drawer, and a peripheral device Service objects supplied for each device, that is, for each device. For example, when the POS application program outputs from the printer, the data is passed to the printer control object (CO), and further passed to the service object (SO) corresponding to the manufacturer and model of the printer to be output, via the OS. Supplied to the printer.

OPOS(OLE for Retail POS)システムでは、POSアプリケーションプログラムに対して、OPOS標準仕様に準拠したデバイスクラス毎のコントロールオブジェクトおよびサービスオブジェクトを備えたオブジェクト制御システムが、アプリケーションプログラムに対して標準化されたインターフェースを提供するとともに、プリンターなどの周辺機器に対して機種依存性のないインターフェースを提供する。アプリケーションプログラムがデバイスクラス毎に定義されたメソッドを呼び出すと、コントロールオブジェクトがサービスオブジェクトのメソッドを、デバイスの機種に依存しないインターフェース(例えば、マイクロソフト社のIDispatchインターフェース)を介して呼び出す。サービスオブジェクトはOSが提供するデバイス毎のデバイスドライバーを利用してリクエストを実行し、実行結果をイベントとしてコントロールオブジェクトを通じてアプリケーションプログラムに通知する。
コントロールオブジェクトは、周辺機器のデバイスクラス毎に詳細な仕様が規定されていて、実質的にOPOS仕様により標準化されているが、一方のサービスオブジェクトは個々のデバイスの仕様に合わせて開発される。
In the OPOS (OLE for Retail POS) system, an object control system including a control object and a service object for each device class that conforms to the OPOS standard specifications provides a standardized interface for an application program. In addition to providing an interface that does not depend on the model for peripheral devices such as printers. When the application program calls a method defined for each device class, the control object calls a service object method via an interface independent of the device model (for example, Microsoft IDispatch interface). The service object executes a request by using a device driver for each device provided by the OS, and notifies the execution result as an event to the application program through the control object.
The control object has a detailed specification for each device class of the peripheral device and is substantially standardized by the OPOS specification, but one service object is developed in accordance with the specification of each device.

特開平9−106355号公報JP-A-9-106355

ところで、デバイスの仕様変更や新機種開発にあたっては、当然のことながら変更後のデバイスに適合したサービスオブジェクトを開発する必要があるが、デバイスの多機能化によってコントロールオブジェクトが呼び出すメソッドはきわめて多く、その全てに対応するようにサービスオブジェクトを新規に開発することは大きな労力を要する。
本発明は、上述した事情に鑑みてなされたものであり、デバイス制御プログラムにおいてデバイスに依存するオブジェクトの開発に係る労力の軽減を図ることを目的とする。
By the way, when changing device specifications or developing new models, it is natural to develop service objects that are compatible with the device after the change. Developing a new service object to deal with everything requires a lot of effort.
The present invention has been made in view of the above-described circumstances, and an object thereof is to reduce the labor involved in developing a device-dependent object in a device control program.

上記目的を達成するために、本発明は、複数種類のデバイスを制御可能なアプリケーションプログラムに対し前記デバイスの種類毎のインターフェースを提供する第1のオブジェクトと、前記第1のオブジェクトに対し前記デバイスの種類毎のインターフェースを提供するとともに前記デバイス単位の処理を実行する第2のオブジェクトとを有し、これらのオブジェクトがオペレーティングシステムの下で動作する制御装置の制御方法であって、第3のオブジェクトが、前記第1のオブジェクトが呼び出す少なくとも一部のメソッドについては前記第2のオブジェクトに代わって処理を実行し、実行後の結果に基づき前記第2のオブジェクトのメソッドを呼び出す一方、前記第1のオブジェクトが他のメソッドを呼び出した場合は前記第2のオブジェクトのメソッドを呼び出すことを特徴とする。
本発明によれば、アプリケーションプログラムが出力するデータに基づいてデバイスを制御する制御装置が、第2のオブジェクトが対応していない一部のメソッドが呼び出された場合に第3のオブジェクトにより処理を実行できる。これにより、第2のオブジェクトが有する全てのメソッドがデバイスに適合していない場合であっても、この第2のオブジェクトを利用してデバイスを制御できる。従って、第2のオブジェクトの機能の一部について変更や拡張が容易になるため、例えばデバイスの仕様変更や新機種開発等にあたって第2のオブジェクトの全体を新規に作成しなくても、旧来の第2のオブジェクトの資産を利用して必要なシステムを構築できる。
In order to achieve the above object, the present invention provides a first object that provides an interface for each type of device to an application program capable of controlling a plurality of types of devices, and a device of the device for the first object. A second object that provides an interface for each type and executes the device-based processing, and these objects operate under the operating system. , At least a part of the methods called by the first object is processed instead of the second object, and the method of the second object is called based on the result after execution, while the first object When the other method calls another method And it said to call the method of the object.
According to the present invention, the control device that controls the device based on the data output from the application program executes processing by the third object when a part of the method that is not supported by the second object is called. it can. As a result, even if all methods of the second object are not compatible with the device, the device can be controlled using the second object. Accordingly, it is easy to change or extend a part of the function of the second object. For example, when the entire second object is not newly created for changing the device specifications or developing a new model, for example, A necessary system can be constructed using the assets of the two objects.

また、本発明は、上記制御装置の制御方法において、前記第3のオブジェクトは、前記第2のオブジェクトが前記第1のオブジェクトに対し提供する前記インターフェースに介在して、前記第1のオブジェクトにより呼び出されたメソッドを実行し、前記インターフェースを介して前記第2のオブジェクトのメソッドを呼び出すことを特徴とする。
本発明によれば、第2のオブジェクト及び第1のオブジェクトの構成に影響を与えないように、第2のオブジェクトを補完できる。
In the control method of the control device according to the present invention, the third object is called by the first object via the interface provided by the second object to the first object. The second method is executed, and the method of the second object is called through the interface.
According to the present invention, the second object can be complemented so as not to affect the configuration of the second object and the first object.

また、本発明は、上記制御装置の制御方法において、前記第1のオブジェクトはパーソナルコンピューターのデバイスの種類毎に提供されるコントロールオブジェクトであり、前記第2のオブジェクトは前記デバイス毎に提供されるサービスオブジェクトであることを特徴とする。
本発明によれば、例えばデバイスの仕様変更や新機種のデバイスの開発にあたって、当該デバイスの種類に対応するコントロールオブジェクトに対する互換性を確保した上で、デバイス毎に用意されるサービスオブジェクトの機能を補完することで、旧来のサービスオブジェクトの資産を利用できる。
In the control method of the control device according to the present invention, the first object is a control object provided for each type of device of the personal computer, and the second object is a service provided for each device. It is an object.
According to the present invention, for example, when changing the specifications of a device or developing a new model device, the compatibility of the control object corresponding to the type of the device is ensured, and the function of the service object prepared for each device is complemented. By doing so, the assets of the old service object can be used.

また、本発明は、上記制御装置の制御方法において、前記アプリケーションプログラムはPOSアプリケーションプログラムであり、前記第1のオブジェクト及び前記第2のオブジェクトは、前記POSアプリケーションプログラムの要求に応じてプリンターを制御するオブジェクトとして構成され、前記第3のオブジェクトは、前記第1のオブジェクトが所定の文字コードセットのプリントメソッドを呼び出した場合に、前記所定の文字コードセットから他の文字コードセットへの変換を行い、変換後の文字コードセットに基づき前記第2のオブジェクトのプリントメソッドを呼び出すことを特徴とする。
本発明によれば、第2のオブジェクトが文字コードの変換機能を持たない場合であっても、この変換機能を第3のオブジェクトが補完することで、第2のオブジェクトが対応していない文字コードセットのデータを処理できる。
また、本発明は、上記制御装置の制御方法において、前記所定の文字コードセットはUnicodeで示されるものであり、前記他の文字コードセットはバイトコードで示されるものであることを特徴とする。
アプリケーションからUnicodeで指定された文字が送られて来たとき、デバイスであるプリンターがUnicodeに対応していない場合、第3のオブジェクトがバイトコードに変換して印刷することができる。
In the control method of the control device according to the present invention, the application program is a POS application program, and the first object and the second object control a printer in response to a request of the POS application program. Configured as an object, the third object performs conversion from the predetermined character code set to another character code set when the first object calls a print method of the predetermined character code set; The print method of the second object is called based on the character code set after conversion.
According to the present invention, even if the second object does not have a character code conversion function, the third object complements this conversion function, so that the character code that the second object does not support. Can process set data.
In the control method of the control device according to the present invention, the predetermined character code set is indicated by Unicode, and the other character code set is indicated by byte code.
When a character designated by Unicode is sent from an application, if the printer as a device does not support Unicode, the third object can be converted into byte code and printed.

また、本発明は、上記制御装置の制御方法において、前記第1のオブジェクトはOPOS準拠のコントロールオブジェクトとして構成され、前記第2のオブジェクトが前記第1のオブジェクトに対し提供する前記インターフェースはIDispatchインターフェースとして構成され、前記第3のオブジェクトは、前記第1のオブジェクトに対しIDispatchインターフェースを提供する一方、前記第2のオブジェクトのIDispatchインターフェースを介して前記第2のオブジェクトのメソッドを呼び出すことを特徴とする。
本発明によれば、OPOSに準拠したサービスオブジェクトの機能を、OPOS準拠のコントロールオブジェクトに影響を与えることなく補完できる。
According to the present invention, in the control method of the control device, the first object is configured as an OPOS-compliant control object, and the interface provided by the second object to the first object is an IDispatch interface. And the third object provides an IDispatch interface to the first object, while calling a method of the second object via the IDispatch interface of the second object.
According to the present invention, the function of a service object compliant with OPOS can be complemented without affecting the control object compliant with OPOS.

また、上記目的を達成するために、本発明は、複数種類のデバイスを制御可能なアプリケーションプログラムに対し前記デバイスの種類毎のインターフェースを提供する第1のオブジェクトと、前記第1のオブジェクトに対し前記デバイスの種類毎のインターフェースを提供するとともに前記デバイス単位の処理を実行する第2のオブジェクトとを、オペレーティングシステムの下で動作させ、前記第1のオブジェクトが呼び出す少なくとも一部のメソッドについては前記第2のオブジェクトに代わって第3のオブジェクトにより処理を実行し、実行後の結果に基づき前記第2のオブジェクトのメソッドを呼び出す一方、前記第1のオブジェクトが他のメソッドを呼び出した場合は前記第2のオブジェクトのメソッドを呼び出すことを特徴とする。
本発明の制御方法を実行することにより、アプリケーションプログラムが出力するデータに基づいてデバイスを制御する制御装置が、第2のオブジェクトが対応していない一部のメソッドが呼び出された場合に第3のオブジェクトにより処理を実行できる。これにより、第2のオブジェクトが有する全てのメソッドがデバイスに適合していない場合であっても、この第2のオブジェクトを利用してデバイスを制御できる。従って、第2のオブジェクトの機能の一部について変更や拡張が容易になるため、例えばデバイスの仕様変更や新機種開発等にあたって第2のオブジェクトの全体を新規に作成しなくても、旧来の第2のオブジェクトの資産を利用して必要なシステムを構築できる。
In order to achieve the above object, the present invention provides a first object that provides an interface for each device type to an application program capable of controlling a plurality of types of devices, and the first object includes the first object. The second object that provides an interface for each type of device and that executes the process for each device is operated under an operating system, and at least some of the methods that the first object calls are the second object. When a process is executed by the third object in place of the object, and the method of the second object is called based on the result after execution, the second object is called when the first object calls another method. Characterized by calling object methods That.
By executing the control method of the present invention, the control device that controls the device based on the data output from the application program causes the third method to be executed when a part of the method that is not supported by the second object is called. Processing can be executed by object. As a result, even if all methods of the second object are not compatible with the device, the device can be controlled using the second object. Accordingly, it is easy to change or extend a part of the function of the second object. For example, when the entire second object is not newly created for changing the device specifications or developing a new model, for example, A necessary system can be constructed using the assets of the two objects.

また、上記目的を達成するために、本発明は、複数種類のデバイスを制御可能なアプリケーションプログラムと、前記アプリケーションプログラムに対してインターフェースを提供するオブジェクトを、オペレーティングシステムの下で実行するコンピューターを、複数種類のデバイスを制御可能なアプリケーションプログラムに対し前記デバイスの種類毎のインターフェースを提供する第1のオブジェクトと、前記第1のオブジェクトに対し前記デバイスの種類毎のインターフェースを提供するとともに前記デバイス単位の処理を実行する第2のオブジェクトと、前記第1のオブジェクトが呼び出す少なくとも一部のメソッドについては前記第2のオブジェクトに代わって処理を実行し、実行後の結果に基づき前記第2のオブジェクトのメソッドを呼び出す一方、前記第1のオブジェクトが他のメソッドを呼び出した場合は前記第2のオブジェクトのメソッドを呼び出す第3のオブジェクトとして機能させることを特徴とする。
本発明のプログラムを実行することにより、アプリケーションプログラムが出力するデータに基づいてデバイスを制御する制御装置が、第2のオブジェクトが対応していない一部のメソッドが呼び出された場合に第3のオブジェクトにより処理を実行できる。これにより、第2のオブジェクトが有する全てのメソッドがデバイスに適合していない場合であっても、この第2のオブジェクトを利用してデバイスを制御できる。従って、第2のオブジェクトの機能の一部について変更や拡張が容易になるため、例えばデバイスの仕様変更や新機種開発等にあたって第2のオブジェクトの全体を新規に作成しなくても、旧来の第2のオブジェクトの資産を利用して必要なシステムを構築できる。
また、本発明は、上記プログラムを記憶した記憶媒体として実現してもよい。
In order to achieve the above object, the present invention provides a plurality of computers that execute, under an operating system, an application program that can control a plurality of types of devices and an object that provides an interface for the application program. A first object that provides an interface for each type of device to an application program that can control a type of device, an interface for each type of device for the first object, and processing for each device The second object that executes the process and at least some of the methods that the first object invokes execute processing on behalf of the second object, and based on the result after execution, execute the second object method. While calling the head, when the first object calls the other method is characterized in that to function as a third object to invoke a method of the second object.
By executing the program of the present invention, the control device that controls the device based on the data output from the application program causes the third object to be called when a part of the method that is not supported by the second object is called. The process can be executed. As a result, even if all methods of the second object are not compatible with the device, the device can be controlled using the second object. Accordingly, it is easy to change or extend a part of the function of the second object. For example, when the entire second object is not newly created for changing the device specifications or developing a new model, for example, A necessary system can be constructed using the assets of the two objects.
Further, the present invention may be realized as a storage medium storing the above program.

本発明によれば、アプリケーションプログラムが出力するデータに基づいてデバイスを制御する制御装置において、例えばデバイスの仕様変更や新機種開発等にあたってオブジェクトの全体を新規に作成しなくても、旧来の資産を利用して必要なシステムを構築できる。   According to the present invention, in a control device that controls a device based on data output from an application program, for example, a legacy object can be stored without newly creating an entire object for device specification change, new model development, etc. Use it to build the necessary system.

実施形態に係るPOSシステムの機能的構成を示すブロック図である。It is a block diagram which shows the functional structure of the POS system which concerns on embodiment. OPOSドライバーの構成を示す図である。It is a figure which shows the structure of an OPOS driver. OPOSドライバーの具体的な動作例を示す図である。It is a figure which shows the specific operation example of an OPOS driver. POSシステムの動作を示すフローチャートである。It is a flowchart which shows operation | movement of a POS system.

以下、図面を参照して本発明の実施形態について説明する。
図1は、本発明を適用した実施形態に係るPOSシステム1の概要構成を示すブロック図である。
POSシステム1は、図示しないPOSサーバーに通信回線を介して接続されたホストコンピューター10(制御装置)を備え、このホストコンピューター10には、ディスプレイ51、キーボード52、プリンター53、スキャナー54、及びドロワー55の各種デバイスが接続されている。
ホストコンピューター10は、プリンター53とともにスーパーやコンビニエンス・ストア等の店舗において、ユーザーが会計処理をする近くに設置され、オペレーターによって入力された商品販売に関する入力情報に基づいてレシートを発行する。プリンター53は、直接ホストコンピューター10に接続されるローカルプリンターであり、プリンター53とインターフェースを介して有線又は無線で接続され、図1にはコネクターを介して有線接続された例を示す。ホストコンピューター10は、顧客に渡すクーポンやキッチンでの調理指示用の伝票などを印刷するための1または複数のプリンター53を制御し、ホストコンピューター10が生成した印刷データに基づいて、レシートや伝票を印刷出力させる。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing a schematic configuration of a POS system 1 according to an embodiment to which the present invention is applied.
The POS system 1 includes a host computer 10 (control device) connected to a POS server (not shown) via a communication line. The host computer 10 includes a display 51, a keyboard 52, a printer 53, a scanner 54, and a drawer 55. Various devices are connected.
The host computer 10 is installed near the printer 53 in a store such as a supermarket or a convenience store, where a user performs accounting processing, and issues a receipt based on input information related to product sales input by an operator. The printer 53 is a local printer that is directly connected to the host computer 10 and is connected to the printer 53 by wire or wirelessly through an interface, and FIG. 1 shows an example in which the printer 53 is wire-connected via a connector. The host computer 10 controls one or a plurality of printers 53 for printing coupons to be handed over to customers, vouchers for cooking instructions in the kitchen, and the like, based on the print data generated by the host computer 10, receipts and vouchers. Print out.

ホストコンピューター10は、商品情報を入力する入力デバイスとしてキーボード52及びスキャナー54を備え、キーボード52による入力またはスキャナー54による商品のバーコードの読み取り結果によって商品に関する入力情報を取得する。POSサーバー(図示略)は、ホストコンピューター10が送信する入力情報に基づいて、商品マスタから商品コード、商品名、金額に関する情報を抽出して返信する。
ホストコンピューター10は、POSサーバーから受信した情報に基づき、レシートや伝票の印刷を実行する。また、ホストコンピューター10は、POSサーバーから送信された商品データを元に生成した商品情報を表示するディスプレイ51を有し、このディスプレイ51における表示によって、顧客に対して購入商品の金額等を掲示する。ドロワー55は、商品販売に伴い授受される金銭を収容し、ホストコンピューター10により会計処理がされる毎に開閉される。
The host computer 10 includes a keyboard 52 and a scanner 54 as input devices for inputting merchandise information, and acquires input information related to merchandise based on an input from the keyboard 52 or a barcode reading result of the merchandise from the scanner 54. A POS server (not shown) extracts and returns information on a product code, a product name, and a price from the product master based on input information transmitted by the host computer 10.
The host computer 10 executes printing of receipts and slips based on information received from the POS server. Further, the host computer 10 has a display 51 for displaying product information generated based on product data transmitted from the POS server, and displays the price of the purchased product to the customer by the display on the display 51. . The drawer 55 accommodates money exchanged with the sale of merchandise and is opened and closed each time an accounting process is performed by the host computer 10.

ホストコンピューター10は、例えば、マイクロソフト社が提供する.NET Frameworkを基盤とした、ウィンドウズ(登録商標)等のオペレーティングシステム12を実行し、このオペレーティングシステム12上でPOSアプリケーションプログラム11、及びOPOSドライバー20を稼働させる。OPOSドライバー20は、オペレーティングシステム12上で稼動するプリンタードライバーOLE for Retail POS(以下OPOSドライバーという)であって、オペレーティングシステム12上で各種デバイスを制御する。   The host computer 10 is provided by, for example, Microsoft Corporation. An operating system 12 such as Windows (registered trademark) based on the NET Framework is executed, and the POS application program 11 and the OPOS driver 20 are operated on the operating system 12. The OPOS driver 20 is a printer driver OLE for Retail POS (hereinafter referred to as “OPOS driver”) that runs on the operating system 12, and controls various devices on the operating system 12.

OPOSドライバー20は、オペレーティングシステム12上で稼動するPOSアプリケーションプログラム11に対して、プリンター53、スキャナー54、及びドロワー55の各デバイスとの機種依存性のないインターフェースを提供するものであり、プリンターなどデバイスのカテゴリー毎に対応したコントロールオブジェクト(CO)とデバイスの機種毎の仕様に対応したサービスオブジェクト(SO)とによって構成されている。コントロールオブジェクトは、OPOSにより規格化された仕様に準拠して作成されたもので、通常、オペレーティングシステム12とともにPOSシステムのプラットホームの一部として提供される。   The OPOS driver 20 provides a POS application program 11 running on the operating system 12 with a model-independent interface with each device of the printer 53, the scanner 54, and the drawer 55, and is a device such as a printer. The control object (CO) corresponding to each category and the service object (SO) corresponding to the specification for each device model. The control object is created in conformity with the specification standardized by OPOS, and is usually provided as a part of the POS system platform together with the operating system 12.

これに対し、サービスオブジェクトはプリンター53、スキャナー54及びドロワー55の機種毎に開発、作成されるもので、各デバイスのメーカー等により提供される。サービスオブジェクトは各デバイスの機種間で異なる機能や仕様に合わせて異なった機能を有しており、デバイスの機種毎の特性に合わせた制御を行う。例えば、プリンターCO21は、オペレーティングシステム12による分類に従って、POSアプリケーションプログラム11に対してプリンターのデバイスカテゴリーに属するデバイスに共通のインターフェースを提供する。プリンターCO21(第1のオブジェクト)は、OPOS仕様に準拠した方法により、POSアプリケーションプログラム11が出力したデータに基づいて、プリンターSO22のメソッドを呼び出す。プリンターSO22(第1のオブジェクト)は、プリンター53の機種に適合するように作成され、プリンターCO21によりメソッドが呼び出されると処理を実行し、プリンター53を制御し、処理結果をイベントとしてプリンターCO21に通知する。   On the other hand, the service object is developed and created for each model of the printer 53, the scanner 54, and the drawer 55, and is provided by the manufacturer of each device. The service object has different functions and specifications depending on the model of each device, and performs control according to the characteristics of each device model. For example, the printer CO 21 provides a common interface to devices belonging to the device category of the printer to the POS application program 11 according to the classification by the operating system 12. The printer CO21 (first object) calls a method of the printer SO22 based on the data output from the POS application program 11 by a method compliant with the OPOS specification. The printer SO22 (first object) is created so as to be compatible with the model of the printer 53, executes a process when a method is called by the printer CO21, controls the printer 53, and notifies the printer CO21 of the processing result as an event. To do.

また、OPOSドライバー20は、スキャナー54のデバイスカテゴリーに対応したスキャナーCO41と、スキャナー54の機種に対応して用意されたスキャナーSO42とを備え、これらによりスキャナー54の制御とバーコードの読み取りを可能としている。OPOSドライバー20は、ドロワー55のデバイスカテゴリーに対応したドロワーCO43と、ドロワー55の機種に対応して用意されたドロワーSO44とを備え、これらによりドロワーSO44の開閉制御を可能としている。ディスプレイ51及びキーボード52は、オペレーティングシステム12が提供するデバイスドライバーにより、POSアプリケーションプログラム11から制御可能となっている。
なお、ホストコンピューター10は、入力デバイスとして、カード型記録媒体に記録された磁気情報を読み取るカードリーダーを備えていてもよく、この場合、OPOSドライバー20は、カードリーダーのデバイスカテゴリーに対応するコントロールオブジェクト及びカードリーダーの機種に対応するサービスオブジェクトを備えた構成とすればよい。
The OPOS driver 20 includes a scanner CO41 corresponding to the device category of the scanner 54 and a scanner SO42 prepared corresponding to the model of the scanner 54, thereby enabling control of the scanner 54 and reading of a barcode. Yes. The OPOS driver 20 includes a drawer CO43 corresponding to the device category of the drawer 55 and a drawer SO44 prepared corresponding to the model of the drawer 55, and enables opening / closing control of the drawer SO44. The display 51 and the keyboard 52 can be controlled from the POS application program 11 by a device driver provided by the operating system 12.
The host computer 10 may include a card reader that reads magnetic information recorded on a card-type recording medium as an input device. In this case, the OPOS driver 20 controls the control object corresponding to the device category of the card reader. And a service object corresponding to the model of the card reader.

図2は、OPOSドライバー20の概念的な構成を詳細に示す図である。
この図2に示すように、プリンターSO22は、プリンターCO21からのメソッドの呼び出しやデータを受け取るためのインターフェースとして、IDispatchインターフェース23を提供する。プリンターSO22が実現するプリンター53の制御に係る様々な処理は、処理の種類(機能)毎に区分され、各機能に対応するメソッド24がある。また、それらに対応するIDispatchインターフェース23が設けられている。IDispatchインターフェースは、マイクロソフト社がオブジェクト間の通信のために提供するインターフェースである。例えば、プリンターCO21が、プリンターSO22の機能Bを実行させる場合、この機能Bを含むメソッド24が、そのメソッド24に対応するIDispatchインターフェース23を介して呼び出されて起動する。
FIG. 2 is a diagram showing in detail the conceptual configuration of the OPOS driver 20.
As shown in FIG. 2, the printer SO22 provides an IDispatch interface 23 as an interface for receiving method calls and data from the printer CO21. Various processes related to the control of the printer 53 realized by the printer SO22 are classified according to processing types (functions), and there are methods 24 corresponding to the respective functions. In addition, an IDispatch interface 23 corresponding to them is provided. The IDispatch interface is an interface provided by Microsoft for communication between objects. For example, when the printer CO21 executes the function B of the printer SO22, the method 24 including the function B is called and activated via the IDispatch interface 23 corresponding to the method 24.

ところで、プリンターSO22はプリンター53の様々な機能に対応してメソッド24を備えているため、プリンター53の機能や設定項目が複雑であるほどプリンターSO22の構成も複雑化する。例えば、一般的なサーマルプリンターに対応するサービスオブジェクトが、100を超えるメソッドに対応していることも珍しくない。
プリンターの新機種の開発、或いは従来機種の仕様変更を行う場合、プリンターSO22の開発も必要になるが、例えば従来使用していたプリンターSO22に対して一部の機能のみを変更あるいは追加すれば済む場合がある。しかしながら、プリンターSO22においては、各々の機能を備える必要があり、また、IDispatchインターフェース23の構成とプリンターSO22の機能との整合が保たれることが必要である。上述したようにプリンターCO21はデバイスカテゴリー毎に共通のものを使用することになっている。
そこで、本実施形態のOPOSドライバー20は、プリンターCO21とプリンターSO22に加え、ラッパーSO30(第3のオブジェクト)を備え、このラッパーSO30によりプリンターSO22の機能を補完する構成となっている。
Incidentally, since the printer SO22 includes the method 24 corresponding to various functions of the printer 53, the configuration of the printer SO22 becomes more complicated as the functions and setting items of the printer 53 become more complicated. For example, it is not uncommon for a service object corresponding to a general thermal printer to correspond to more than 100 methods.
When developing a new printer model or changing the specifications of a conventional model, it is also necessary to develop a printer SO22. For example, only a part of the functions may be changed or added to the printer SO22 used conventionally. There is a case. However, the printer SO22 needs to have each function, and the configuration of the IDispatch interface 23 needs to be consistent with the function of the printer SO22. As described above, the printer CO21 uses a common printer for each device category.
Therefore, the OPOS driver 20 of this embodiment includes a wrapper SO30 (third object) in addition to the printer CO21 and the printer SO22, and is configured to complement the function of the printer SO22 by this wrapper SO30.

ラッパーSO30は、プリンターCO21とプリンターSO22との間に介在し、プリンターSO22がプリンターCO21に対して提供するIDispatchインターフェース23への呼び出しを検出する。ここで、ラッパーSO30は、プリンターCO21に対してIDispatchインターフェース23と同様に識別されるIDispatchインターフェース31を備えており、プリンターCO21がプリンターSO22のメソッドを呼び出すと、IDispatchインターフェース31を介してラッパーSO30が呼び出される。
ラッパーSO30は、特定の機能に関するメソッド32を有している。このメソッド32は、プリンターSO22が有していない機能や、プリンターSO22の機能を改良、拡張、変更した機能に対応している。ラッパーSO30は、プリンターCO21からの呼び出しに対し、ラッパーSO30自身が有するメソッド32が制御を行うか、或いは、プリンターSO22のメソッド24を呼び出すかを判別する。そして、プリンターSO22のメソッド24で処理すればよい場合には、プリンターCO21からの呼び出しを、IDispatchインターフェース23に対して行う。プリンターSO22のメソッドからイベントが通知された場合、ラッパーSO30はIDispatchインターフェース31を介して、プリンターCO21に対してイベントを通知する。また、ラッパーSO30は、ラッパーSO30のメソッド32を実行した場合には、その結果をイベントとしてプリンターCO21に通知する機能を有する。
The wrapper SO30 is interposed between the printer CO21 and the printer SO22, and detects a call to the IDispatch interface 23 provided by the printer SO22 to the printer CO21. Here, the wrapper SO30 includes an IDispatch interface 31 that is identified to the printer CO21 in the same manner as the IDispatch interface 23. When the printer CO21 calls a method of the printer SO22, the wrapper SO30 is called via the IDispatch interface 31. It is.
The wrapper SO30 has a method 32 related to a specific function. This method 32 corresponds to a function that the printer SO22 does not have or a function that is an improvement, extension, or change of the function of the printer SO22. The wrapper SO30 determines whether the method 32 of the wrapper SO30 itself controls the call from the printer CO21 or the method 24 of the printer SO22. Then, if the processing should be performed by the method 24 of the printer SO 22, a call from the printer CO 21 is made to the IDispatch interface 23. When an event is notified from the method of the printer SO22, the wrapper SO30 notifies the printer CO21 of the event via the IDispatch interface 31. Further, the wrapper SO30 has a function of notifying the result to the printer CO21 as an event when the method 32 of the wrapper SO30 is executed.

このように、ラッパーSO30は、プリンターSO22で実行すべきで無いメソッドが呼び出された場合に、プリンターSO22に代わって当該メソッドを実行するものであり、ラッパーSO30を用いることでプリンターSO22の機能の追加、拡張、改変等を実現できる。また、ラッパーSO30はIDispatchインターフェース31を備え、プリンターCO21からはプリンターSO22の一部のように振る舞うため、プリンターCO21の仕様変更や改変等を伴わずに適用できるという利点がある。   As described above, the wrapper SO30 executes the method instead of the printer SO22 when a method that should not be executed by the printer SO22 is called. By using the wrapper SO30, the function of the printer SO22 is added. , Expansion, modification, etc. can be realized. Further, since the wrapper SO30 includes an IDispatch interface 31 and behaves like a part of the printer SO22 from the printer CO21, there is an advantage that the wrapper SO30 can be applied without changing or modifying the specifications of the printer CO21.

図3は、OPOSドライバー20の具体的な動作例を示す図であり、(A)はラッパーSO30がプリンターSO22のメソッドを呼び出す場合を示し、(B)はラッパーSO30のメソッドが呼び出される場合を示す。
図3(A)に示すように、POSアプリケーションプログラム11が、コードページを指定するデータで構成される文字データとともに、「PrintNormal」メソッドを呼び出すと、プリンターCO21は、プリンターSO22に対して「PrintNormal」メソッドの呼び出しを行う。POSアプリケーションプログラム11が出力したデータはプリンター53が内蔵するフォントデータの中から文字を指定する情報であり、このデータの形態がコードページを指定する情報となっているため、プリンター53は当該データに基づいて一つのフォントを取得して印刷できる。この場合、ラッパーSO30は、この呼び出しをプリンターSO22が実行可能であると判別して、プリンターSO22の「PrintNormal」メソッドを呼び出し、プリンター53を制御させる。
3A and 3B are diagrams illustrating a specific operation example of the OPOS driver 20, in which FIG. 3A illustrates a case where the wrapper SO30 calls a method of the printer SO22, and FIG. 3B illustrates a case where the method of the wrapper SO30 is called. .
As shown in FIG. 3A, when the POS application program 11 calls the “PrintNormal” method together with the character data composed of the data specifying the code page, the printer CO21 sends “PrintNormal” to the printer SO22. Make a method call. The data output by the POS application program 11 is information for designating characters from the font data built in the printer 53, and the form of this data is information for designating a code page. A single font can be obtained and printed based on this. In this case, the wrapper SO30 determines that this call can be executed by the printer SO22, calls the “PrintNormal” method of the printer SO22, and controls the printer 53.

一方、図3(B)に示すように、POSアプリケーションプログラム11がUnicodeで文字を指定するデータとともに、「PrintNormal」メソッドを呼び出し、プリンターCO21がプリンターSO22の「PrintNormal」メソッドの呼び出しを行った場合、ラッパーSO30は、この呼び出しをプリンターSO22が実行できないと判別して、ラッパーSO30が備えるMBCS(Multibyte Character Set)/Unicodeの変換を行うメソッド32を呼び出す。これは、プリンター53、及びプリンターSO22がUnicodeに対応していないため、プリンターSO22のメソッドを呼び出しても印刷できないためである。ラッパーSO30は、呼び出したメソッドによりPOSアプリケーションプログラム11が出力したデータの文字コードセットを変換して、マルチバイトコードの文字データを生成し、このデータに基づきプリンターSO22の「PrintNormal」メソッドを呼び出す。これにより、プリンターSO22の制御によって印刷が実行される。   On the other hand, as shown in FIG. 3B, when the POS application program 11 calls the “PrintNormal” method together with the data specifying characters in Unicode, and the printer CO21 calls the “PrintNormal” method of the printer SO22, The wrapper SO30 determines that this call cannot be executed by the printer SO22, and calls a method 32 that performs MBCS (Multibyte Character Set) / Unicode conversion provided in the wrapper SO30. This is because the printer 53 and the printer SO22 do not support Unicode, and therefore printing cannot be performed even if the method of the printer SO22 is called. The wrapper SO30 converts the character code set of the data output from the POS application program 11 by the called method, generates multibyte code character data, and calls the “PrintNormal” method of the printer SO22 based on this data. Thus, printing is executed under the control of the printer SO22.

図4は、POSシステム1の動作を示すフローチャートである。
この図4を参照して、POSシステム1の動作の流れについてまとめると、POSアプリケーションプログラム11が印刷すべきデータと、印刷を実行させるため「PrintNormal」メソッドを呼び出すと(ステップS11)、プリンターCO21がメソッドを呼び出す(ステップS12)。
ラッパーSO30は、プリンターCO21が呼び出したメソッドをプリンターSO22に対して呼び出すか、ラッパーSO30自身が有するメソッド32で実行するかを判別し(ステップS13)、ラッパーSO30自身が実行する場合(ステップS13;Yes)、メソッド32を呼び出して処理を行い、処理後のデータに基づいてプリンターSO22のメソッド24を呼び出す(ステップS14)。また、ラッパーSO30自身が有するメソッドを実行しない場合(ステップS13;No)、プリンターSO22のメソッド24を呼び出す(ステップS16)。
その後、プリンターSO22がプリンター53を制御して印刷を実行し(ステップS15)、印刷の正常終了を示すイベントを通知して、本処理を終了する。
FIG. 4 is a flowchart showing the operation of the POS system 1.
Referring to FIG. 4, the operation flow of the POS system 1 is summarized. When the POS application program 11 calls data to be printed and the “PrintNormal” method for executing printing (step S11), the printer CO21 A method is called (step S12).
The wrapper SO30 determines whether the method called by the printer CO21 is called to the printer SO22 or is executed by the method 32 of the wrapper SO30 itself (step S13). When the wrapper SO30 itself executes (step S13; Yes) ), The method 32 is called to perform processing, and the method 24 of the printer SO22 is called based on the processed data (step S14). When the method of the wrapper SO30 itself is not executed (step S13; No), the method 24 of the printer SO22 is called (step S16).
Thereafter, the printer SO22 controls the printer 53 to execute printing (step S15), notifies an event indicating the normal end of printing, and ends this processing.

以上のように、本発明を適用した実施形態に係るPOSシステム1は、プリンター53を含む複数種類のデバイスを制御可能なPOSアプリケーションプログラム11に対しデバイスの種類毎のインターフェースを提供するプリンターCO21と、プリンターCO21に対しデバイスの種類毎のインターフェースを提供するとともにデバイス単位の処理を実行するプリンターSO22とを有し、これらのオブジェクトがオペレーティングシステム12の下で動作するホストコンピューター10は、プリンターCO21が呼び出す少なくとも一部のメソッドについてはプリンターSO22に代わって処理を実行し、実行後の結果に基づきプリンターSO22のメソッドを呼び出す一方、プリンターCO21が他のメソッドを呼び出した場合はプリンターSO22のメソッドを呼び出すラッパーSO30を有し、プリンターSO22が対応していない一部のメソッドが呼び出された場合にラッパーSO30により処理を実行する。これにより、プリンターSO22が有する全てのメソッドがデバイスに適合していない場合であっても、このプリンターSO22を利用してデバイスを制御できる。従って、プリンターSO22の機能の一部について変更や拡張が容易になるため、例えばデバイスの仕様変更や新機種開発等にあたってプリンターSO22の全体を新規に作成しなくても、旧来のプリンターSO22の資産を利用して必要なシステムを構築できる。   As described above, the POS system 1 according to the embodiment to which the present invention is applied includes the printer CO 21 that provides an interface for each device type to the POS application program 11 that can control a plurality of types of devices including the printer 53. A printer SO22 that provides an interface for each device type to the printer CO21 and executes processing for each device, and the host computer 10 in which these objects operate under the operating system 12 is at least called by the printer CO21. For some methods, processing is executed in place of the printer SO22, and the method of the printer SO22 is called based on the result after execution, while when the printer CO21 calls another method, the processing is executed. Having a wrapper SO30 invoking methods on centers SO22, performs processing by the wrapper SO30 if some methods that printer SO22 does not support is called. As a result, even if all methods of the printer SO22 are not compatible with the device, the device can be controlled using the printer SO22. Accordingly, since it is easy to change or extend a part of the functions of the printer SO22, for example, the assets of the old printer SO22 can be saved without newly creating the entire printer SO22 when changing the device specifications or developing a new model. Use it to build the necessary system.

また、ラッパーSO30は、プリンターSO22がプリンターCO21に対し提供するインターフェースに介在して、プリンターCO21により呼び出されたメソッドを実行し、インターフェースを介してプリンターSO22のメソッドを呼び出すので、プリンターSO22及びプリンターCO21の構成に影響を与えないように、プリンターSO22を補完できる。ここで、プリンターCO21はパーソナルコンピューターのデバイスの種類毎に提供されるコントロールオブジェクトであり、プリンターSO22はデバイス毎に提供されるサービスオブジェクトであるため、例えばデバイスの仕様変更や新機種のデバイスの開発にあたって、当該デバイスの種類に対応するコントロールオブジェクトに対する互換性を確保した上で、デバイス毎に用意されるサービスオブジェクトの機能を補完することで、旧来のサービスオブジェクトの資産を利用できる。   Further, since the wrapper SO30 intervenes in the interface provided by the printer SO22 to the printer CO21 and executes the method called by the printer CO21 and calls the method of the printer SO22 via the interface, the wrapper SO22 and the printer CO21 The printer SO22 can be complemented so as not to affect the configuration. Here, since the printer CO21 is a control object provided for each type of device of the personal computer, and the printer SO22 is a service object provided for each device, for example, when changing the specifications of the device or developing a new model device. The asset of the old service object can be used by ensuring the compatibility with the control object corresponding to the type of the device and complementing the function of the service object prepared for each device.

また、プリンターCO21及びプリンターSO22は、POSアプリケーションプログラム11の要求に応じてプリンターを制御するオブジェクトとして構成され、ラッパーSO30は、プリンターCO21が所定の文字コードセットのプリントメソッドを呼び出した場合に、所定の文字コードセットから他の文字コードセットへの変換を行い、変換後の文字コードセットに基づきプリンターSO22のプリントメソッドを呼び出すので、プリンターSO22が文字コードの変換機能を持たない場合であっても、この変換機能をラッパーSO30が補完することで、プリンターSO22が対応していない文字コードセットのデータを処理できる。
さらに、プリンターCO21はOPOS準拠のコントロールオブジェクトとして構成され、プリンターSO22がプリンターCO21に対し提供するインターフェースはIDispatchインターフェースとして構成され、ラッパーSO30は、プリンターCO21に対しIDispatchインターフェースを提供する一方、プリンターSO22のIDispatchインターフェースを介してプリンターSO22のメソッドを呼び出すので、OPOSに準拠したサービスオブジェクトの機能を、OPOS準拠のコントロールオブジェクトに影響を与えることなく補完できる。
Also, the printer CO21 and the printer SO22 are configured as objects that control the printer in response to a request from the POS application program 11, and the wrapper SO30 is a predetermined object when the printer CO21 calls a print method of a predetermined character code set. Since conversion from a character code set to another character code set is performed and the print method of the printer SO22 is called based on the converted character code set, even if the printer SO22 does not have a character code conversion function, By supplementing the conversion function by the wrapper SO30, it is possible to process data of a character code set not supported by the printer SO22.
Further, the printer CO21 is configured as an OPOS-compliant control object, the interface provided by the printer SO22 to the printer CO21 is configured as an IDispatch interface, and the wrapper SO30 provides an IDispatch interface to the printer CO21, while the printer SO22 has an IDispatch interface. Since the method of the printer SO22 is called through the interface, the function of the service object compliant with OPOS can be complemented without affecting the control object compliant with OPOS.

なお、上記各実施形態は本発明を適用した一具体例を示すものであり、本発明はこれに限定されるものではない。例えば、POSシステム1が備えるデバイスはディスプレイ51、キーボード52、プリンター53、スキャナー54及びドロワー55に限定されず、他のデバイスを使用することが可能であるし、例えばホストコンピューター10が複数台のプリンター53を制御して印刷を実行させる場合に本発明を適用することも可能である。また、上記実施形態ではプリンター53を制御するプリンターSO22の機能を補完するためラッパーSO30を設けた構成を例に挙げて説明したが、例えばスキャナーSO42やドロワーSO44の機能の拡張、変更等を行うために、スキャナー54やドロワー55に対応するラッパーSOを設けることも可能である。
さらに、本発明はオペレーティングシステム12上で実行される全てのアプリケーションプログラムに対してインターフェースを提供するオブジェクトを対象として、適用することが可能であり、アプリケーションプログラムはPOSアプリケーションプログラムに限定されないし、制御対象のデバイスも上述したように特に限定されない。
Each of the above embodiments shows a specific example to which the present invention is applied, and the present invention is not limited to this. For example, the devices included in the POS system 1 are not limited to the display 51, the keyboard 52, the printer 53, the scanner 54, and the drawer 55, and other devices can be used. For example, the host computer 10 includes a plurality of printers. It is also possible to apply the present invention to execute printing by controlling 53. In the above-described embodiment, the configuration in which the wrapper SO30 is provided to supplement the function of the printer SO22 that controls the printer 53 has been described as an example. However, for example, the functions of the scanner SO42 and the drawer SO44 are expanded and changed. It is also possible to provide a wrapper SO corresponding to the scanner 54 and the drawer 55.
Furthermore, the present invention can be applied to an object that provides an interface for all application programs executed on the operating system 12, and the application program is not limited to a POS application program, and is a control target. This device is not particularly limited as described above.

また、図1〜図3に示した各機能部は機能的構成を示すものであって、各機能部を独立したハードウェアにより構成する必要はなく、ソフトウェアとハードウェアとの協働により、複数の機能部の機能を1つのハードウェアに集約して実現することも、一つの機能部を複数のハードウェアにより実現することも勿論可能である。また、上述の動作を行うホストコンピューター10が実行するプログラムは、ホストコンピューター10を構成するROM等の不揮発性記憶装置が記憶する構成に限らず、可搬型の記録媒体に記憶されている構成であってもよいし、或いは、通信回線を介して接続された他の装置にダウンロード可能に記憶され、これらの装置からホストコンピューター10が上記プログラムをダウンロードして実行してもよく、その他の構成についても任意に変更可能である。   Moreover, each function part shown in FIGS. 1-3 shows a functional structure, Comprising: It is not necessary to comprise each function part with the independent hardware, and several by cooperation with software and hardware. It is of course possible to realize the functions of these functional units in a single piece of hardware, or to implement a single functional unit with a plurality of hardware. In addition, the program executed by the host computer 10 that performs the above-described operation is not limited to the configuration stored in the nonvolatile storage device such as the ROM that configures the host computer 10, and is a configuration stored in a portable recording medium. Alternatively, the program may be stored in a downloadable manner in other devices connected via a communication line, and the host computer 10 may download and execute the program from these devices. It can be changed arbitrarily.

1…POSシステム、10…ホストコンピューター(制御装置)、11…POSアプリケーションプログラム、12…オペレーティングシステム、20…OPOSドライバー、21…プリンターCO(第1のオブジェクト)、22…プリンターSO(第2のオブジェクト)、23…IDispatchインターフェース23、24…メソッド、30…ラッパーSO(第3のオブジェクト)、31…IDispatchインターフェース、32…メソッド、41…スキャナーCO、42…スキャナーSO、43…ドロワーCO、44…ドロワーSO、53…プリンター(デバイス)、54…スキャナー(デバイス)、55…ドロワー(デバイス)。   DESCRIPTION OF SYMBOLS 1 ... POS system, 10 ... Host computer (control apparatus), 11 ... POS application program, 12 ... Operating system, 20 ... OPOS driver, 21 ... Printer CO (first object), 22 ... Printer SO (second object) ), 23 ... IDispatch interface 23, 24 ... method, 30 ... wrapper SO (third object), 31 ... IDispatch interface, 32 ... method, 41 ... scanner CO, 42 ... scanner SO, 43 ... drawer CO, 44 ... drawer SO, 53 ... printer (device), 54 ... scanner (device), 55 ... drawer (device).

Claims (7)

複数種類のデバイスを制御可能なアプリケーションプログラムに対し前記デバイスの種類毎のインターフェースを提供する第1のオブジェクトと、前記第1のオブジェクトに対し前記デバイスの種類毎のインターフェースを提供するとともに前記デバイス単位の処理を実行する第2のオブジェクトとを有し、これらのオブジェクトがオペレーティングシステムの下で動作する制御装置の制御方法であって、
第3のオブジェクトが、前記第1のオブジェクトが呼び出す少なくとも一部のメソッドについては前記第2のオブジェクトに代わって処理を実行し、実行後の結果に基づき前記第2のオブジェクトのメソッドを呼び出す一方、前記第1のオブジェクトが他のメソッドを呼び出した場合は前記第2のオブジェクトのメソッドを呼び出すこと、
を特徴とする制御装置の制御方法。
A first object that provides an interface for each type of device to an application program that can control a plurality of types of devices, an interface for each type of device to the first object, and a device unit And a second object that executes processing, and these objects operate under the operating system.
While the third object executes processing on behalf of the second object for at least some of the methods that the first object calls, and calls the method of the second object based on the result after execution, Calling a method of the second object when the first object calls another method;
A control method for a control device.
前記第3のオブジェクトは、前記第2のオブジェクトが前記第1のオブジェクトに対し提供する前記インターフェースに介在して、前記第1のオブジェクトにより呼び出されたメソッドを実行し、前記インターフェースを介して前記第2のオブジェクトのメソッドを呼び出すことを特徴とする請求項1記載の制御装置の制御方法。   The third object executes a method called by the first object via the interface provided by the second object to the first object, and executes the method called by the first object. The control method of the control apparatus according to claim 1, wherein the method of the second object is called. 前記第1のオブジェクトはパーソナルコンピューターのデバイスの種類毎に提供されるコントロールオブジェクトであり、前記第2のオブジェクトは前記デバイス毎に提供されるサービスオブジェクトであることを特徴とする請求項1または2記載の制御装置の制御方法。   3. The first object is a control object provided for each device type of a personal computer, and the second object is a service object provided for each device. Control method of the control device. 前記アプリケーションプログラムはPOSアプリケーションプログラムであり、
前記第1のオブジェクト及び前記第2のオブジェクトは、前記POSアプリケーションプログラムの要求に応じてプリンターを制御するオブジェクトとして構成され、
前記第3のオブジェクトは、前記第1のオブジェクトが所定の文字コードセットのプリントメソッドを呼び出した場合に、前記所定の文字コードセットから他の文字コードセットへの変換を行い、変換後の文字コードセットに基づき前記第2のオブジェクトのプリントメソッドを呼び出すことを特徴とする請求項1から3のいずれかに記載の制御装置の制御方法。
The application program is a POS application program,
The first object and the second object are configured as objects that control a printer in response to a request from the POS application program,
The third object performs conversion from the predetermined character code set to another character code set when the first object calls a print method of a predetermined character code set, and converts the converted character code. The control method of the control device according to claim 1, wherein a print method of the second object is called based on the set.
前記所定の文字コードセットはUnicodeで示されるものであり、前記他の文字コードセットはバイトコードで示されるものであることを特徴とする請求項1から4のいずれかに記載の制御装置の制御方法。   5. The control by the control device according to claim 1, wherein the predetermined character code set is represented by Unicode, and the other character code set is represented by a byte code. Method. 前記第1のオブジェクトはOPOS準拠のコントロールオブジェクトとして構成され、 前記第2のオブジェクトが前記第1のオブジェクトに対し提供する前記インターフェースはIDispatchインターフェースとして構成され、
前記第3のオブジェクトは、前記第1のオブジェクトに対しIDispatchインターフェースを提供する一方、前記第2のオブジェクトのIDispatchインターフェースを介して前記第2のオブジェクトのメソッドを呼び出すことを特徴とする請求項1から5のいずれかに記載の制御装置の制御方法。
The first object is configured as an OPOS compliant control object, and the interface provided by the second object to the first object is configured as an IDispatch interface;
The third object provides an IDispatch interface to the first object, and calls a method of the second object through the IDispatch interface of the second object. 6. A control method for a control device according to claim 5.
複数種類のデバイスを制御可能なアプリケーションプログラムと、前記アプリケーションプログラムに対してインターフェースを提供するオブジェクトを、オペレーティングシステムの下で実行するコンピューターを、
複数種類のデバイスを制御可能なアプリケーションプログラムに対し前記デバイスの種類毎のインターフェースを提供する第1のオブジェクトと、
前記第1のオブジェクトに対し前記デバイスの種類毎のインターフェースを提供するとともに前記デバイス単位の処理を実行する第2のオブジェクトと、
前記第1のオブジェクトが呼び出す少なくとも一部のメソッドについては前記第2のオブジェクトに代わって処理を実行し、実行後の結果に基づき前記第2のオブジェクトのメソッドを呼び出す一方、前記第1のオブジェクトが他のメソッドを呼び出した場合は前記第2のオブジェクトのメソッドを呼び出す第3のオブジェクトと、
して機能させることを特徴とするプログラム。
A computer that executes, under an operating system, an application program that can control a plurality of types of devices and an object that provides an interface to the application program;
A first object that provides an interface for each device type to an application program capable of controlling a plurality of types of devices;
A second object that provides an interface for each type of device to the first object, and executes the process in units of devices;
For at least some of the methods called by the first object, processing is executed on behalf of the second object, and the method of the second object is called based on the result after execution, while the first object A third object that calls a method of the second object if another method is called;
A program characterized by making it function.
JP2011195746A 2011-08-03 2011-09-08 Control device control method Active JP5906620B2 (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP2011195746A JP5906620B2 (en) 2011-09-08 2011-09-08 Control device control method
CN201210250667.8A CN102915215B (en) 2011-08-03 2012-07-19 Control device and control method
US13/561,605 US9110615B2 (en) 2011-08-03 2012-07-30 Point of sale control device, control method, and storage medium storing a program for a point of sale device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011195746A JP5906620B2 (en) 2011-09-08 2011-09-08 Control device control method

Publications (3)

Publication Number Publication Date
JP2013058065A true JP2013058065A (en) 2013-03-28
JP2013058065A5 JP2013058065A5 (en) 2014-09-11
JP5906620B2 JP5906620B2 (en) 2016-04-20

Family

ID=48133911

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011195746A Active JP5906620B2 (en) 2011-08-03 2011-09-08 Control device control method

Country Status (1)

Country Link
JP (1) JP5906620B2 (en)

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07325808A (en) * 1994-05-31 1995-12-12 Canon Inc Document processor and processing method therefor
JPH08106390A (en) * 1994-09-22 1996-04-23 Internatl Business Mach Corp <Ibm> Data-processing system
US5940845A (en) * 1997-12-05 1999-08-17 International Business Machines Corporation System for accessing databases with different character sets
JP2000293375A (en) * 1999-04-05 2000-10-20 Toshiba Information Systems (Japan) Corp Object oriented computer system and computer readable storage medium with program stored therein
JP2001067325A (en) * 1998-09-30 2001-03-16 Hitachi Software Eng Co Ltd Method and system for managing distributed object
JP2002202892A (en) * 2000-12-28 2002-07-19 Seiko Epson Corp Method for processing character string data and device for the same
JP2002207602A (en) * 2001-01-05 2002-07-26 Seiko Epson Corp System and method for control
JP2002215477A (en) * 2001-01-16 2002-08-02 Seiko Epson Corp System and processing method for monitoring device state, and information recording medium
JP2002264424A (en) * 2001-03-12 2002-09-18 Seiko Epson Corp Symbol printer, its printing method, driver for symbol printer and information storage medium
JP2002312301A (en) * 2001-04-17 2002-10-25 Seiko Epson Corp Control system
JP2002318703A (en) * 2001-04-20 2002-10-31 Seiko Epson Corp Control system
US20090037940A1 (en) * 2007-07-31 2009-02-05 Microsoft Corporation POS hardware abstraction
JP2009140063A (en) * 2007-12-04 2009-06-25 Seiko Epson Corp File management module, printing device, file management method, file management program
US20110255108A1 (en) * 2006-01-24 2011-10-20 ZHI Corp. Global printing system and method of using same

Patent Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07325808A (en) * 1994-05-31 1995-12-12 Canon Inc Document processor and processing method therefor
JPH08106390A (en) * 1994-09-22 1996-04-23 Internatl Business Mach Corp <Ibm> Data-processing system
US5940845A (en) * 1997-12-05 1999-08-17 International Business Machines Corporation System for accessing databases with different character sets
JP2001067325A (en) * 1998-09-30 2001-03-16 Hitachi Software Eng Co Ltd Method and system for managing distributed object
JP2000293375A (en) * 1999-04-05 2000-10-20 Toshiba Information Systems (Japan) Corp Object oriented computer system and computer readable storage medium with program stored therein
JP2002202892A (en) * 2000-12-28 2002-07-19 Seiko Epson Corp Method for processing character string data and device for the same
JP2002207602A (en) * 2001-01-05 2002-07-26 Seiko Epson Corp System and method for control
JP2002215477A (en) * 2001-01-16 2002-08-02 Seiko Epson Corp System and processing method for monitoring device state, and information recording medium
JP2002264424A (en) * 2001-03-12 2002-09-18 Seiko Epson Corp Symbol printer, its printing method, driver for symbol printer and information storage medium
JP2002312301A (en) * 2001-04-17 2002-10-25 Seiko Epson Corp Control system
US20030061021A1 (en) * 2001-04-17 2003-03-27 Atsushi Sakai Control system
JP2002318703A (en) * 2001-04-20 2002-10-31 Seiko Epson Corp Control system
US20110255108A1 (en) * 2006-01-24 2011-10-20 ZHI Corp. Global printing system and method of using same
US20090037940A1 (en) * 2007-07-31 2009-02-05 Microsoft Corporation POS hardware abstraction
JP2009140063A (en) * 2007-12-04 2009-06-25 Seiko Epson Corp File management module, printing device, file management method, file management program

Also Published As

Publication number Publication date
JP5906620B2 (en) 2016-04-20

Similar Documents

Publication Publication Date Title
US9262106B2 (en) Method of adding value to print data, a value-adding device, and a recording medium
US9030704B2 (en) Function expansion method using print data for a point-of-sale terminal
US9110615B2 (en) Point of sale control device, control method, and storage medium storing a program for a point of sale device
JP4289067B2 (en) Electronic receipt issuing method, program, electronic receipt issuing apparatus, printing apparatus, and POS system
US20130229352A1 (en) POS System, Control System, and Control Method of a Control System
JP5810609B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
EP2942706B1 (en) Data conversion system, data conversion device, and data conversion method
US9058139B2 (en) Function expansion method using print data, and function expansion device
US8755081B2 (en) Devices, methods, and media for using compatible commands to control recording devices
JP2015114687A (en) Printer, and control method
JP5906620B2 (en) Control device control method
JP5867563B2 (en) Function expansion program, function expansion device, and function expansion method using print data
JP2012198613A (en) Output device, journal generation system, journal generation method and program
JP5790267B2 (en) Output control system and control method
US8693036B2 (en) Distribution processing method, distribution processing device, print data processing method, print data processing device, and recording medium
JP2012058846A (en) Print data processing program for distributing output destination, print data processing device, and print data processing method
US10552104B2 (en) Print data processing device, print data processing method, program, and printing system for executing printing process according to user needs
JP2013041440A (en) Output control device, control method of control device, and program
JP6929402B2 (en) Electronic receipt system and processing method
US9720788B2 (en) Recording device and control method of a recording device
JP2015201025A (en) Pos system and control method of the same
JP6075427B2 (en) Print control method and printer driver
JP6511859B2 (en) INFORMATION PROCESSING SYSTEM, ITS CONTROL METHOD, AND PROGRAM, AND INFORMATION PROCESSING APPARATUS, ITS CONTROL METHOD, AND PROGRAM
JP2018060555A (en) Electronic receipt management server, electronic receipt system and program

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140728

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140728

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20150107

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150427

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20150602

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20150722

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20160307

R150 Certificate of patent or registration of utility model

Ref document number: 5906620

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150