WO2017169631A1 - プログラム - Google Patents

プログラム Download PDF

Info

Publication number
WO2017169631A1
WO2017169631A1 PCT/JP2017/009503 JP2017009503W WO2017169631A1 WO 2017169631 A1 WO2017169631 A1 WO 2017169631A1 JP 2017009503 W JP2017009503 W JP 2017009503W WO 2017169631 A1 WO2017169631 A1 WO 2017169631A1
Authority
WO
WIPO (PCT)
Prior art keywords
program
type
function
target
bit
Prior art date
Application number
PCT/JP2017/009503
Other languages
English (en)
French (fr)
Inventor
渉 外谷
Original Assignee
株式会社ラック
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 株式会社ラック filed Critical 株式会社ラック
Priority to SG11201808130RA priority Critical patent/SG11201808130RA/en
Publication of WO2017169631A1 publication Critical patent/WO2017169631A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating

Definitions

  • the present invention relates to a program.
  • This application claims priority based on Japanese Patent Application No. 2016-06496 for which it applied to Japan on March 28, 2016, and uses the content here.
  • Patent Document 1 a technique for associating project versions is unnecessary in an application development environment.
  • a library that is commonly required for all the platforms is extracted, and a file corresponding to the target platform (project version) is searched (patent) (See paragraphs 0020-0021 of document 1.)
  • the embodiment of the present invention provides a program capable of switching an execution program in accordance with a target platform.
  • a program according to an embodiment of the present invention includes a first function for identifying a process type of the target program according to a platform on which the target program that is another program to be operated by the program operates, A second function for determining whether or not the process type of the target program identified by the first function is consistent with the first type of the process of the own program; and When it is determined that the process type is not consistent with the first type of the process of the own program, the process of the second type of the own program that matches the process type of the target program is started, A program for causing a computer to realize a third function of terminating the first type of process It is.
  • a program according to an embodiment of the present invention includes a first function for identifying a process type of the target program according to a platform on which the target program that is another program to be operated by the program operates, A second function for determining whether or not the process type of the target program identified by the first function is consistent with the first type of the process of the own program; and When it is determined that the process type is not consistent with the first type of the process of the own program, a program file of the own program that matches the process type of the target program is generated, and the generated program file A third function for starting the second type of process is realized in the computer. Which is the program.
  • the third function uses a configuration that activates the second type process of the own program and ends the first type process of the own program. May be.
  • a configuration may be used in which the own program includes the resources of the program related to the first type process and the second type process.
  • FIG. 1 is a diagram illustrating a schematic configuration example of an information processing system 11 according to an embodiment of the present invention.
  • the information processing system 11 includes a plurality of terminal devices 21 to 25 and a network 31.
  • Each terminal device 21 to 25 is connected to a network 31.
  • Each of the terminal devices 21 to 25 is a computer or the like.
  • the network 31 is the Internet or the like.
  • terminal devices 21 to 25 are shown as the plurality of terminal devices 21 to 25, but the number of terminal devices may be arbitrary.
  • one network 31 is shown, but the number of networks may be arbitrary.
  • the configuration of the information processing system 11 may be another configuration.
  • the terminal devices 21 to 25 are connected to the network 31.
  • the terminal devices 21 to 25 may not be connected to the network 31.
  • FIG. 2 is a diagram illustrating a schematic configuration example of the terminal device 21 according to an embodiment of the present invention.
  • the schematic configurations of the terminal devices 21 to 25 are the same.
  • a configuration example and an operation example are shown by taking the terminal device 21 as an example.
  • the terminal device 21 includes a processor 101, a memory 102, a network interface 103, an operation unit 104, a display unit 105, a storage device 106, an input / output interface 107, and a bus 111 for connecting them.
  • the processor 101 is composed of a CPU (Central Processing Unit) or the like, and executes processing specified in the program by executing the program.
  • the memory 102 is a volatile storage unit, and includes a RAM (Random Access Memory) or the like, and temporarily stores data.
  • a RAM Random Access Memory
  • the network interface 103 is an interface connected to an external network (the network 31 in this embodiment).
  • the operation unit 104 includes one or more of a keyboard, a mouse, and the like, and accepts an operation performed by a person (user).
  • the display unit 105 has a screen, and displays and outputs information on the screen.
  • the storage device 106 is a non-volatile storage unit, and is composed of, for example, a hard disk and stores data.
  • the input / output interface 107 is an interface connected to an external recording medium.
  • x86, x64, and AnyCPU are shown.
  • ⁇ X86> x86 operates as a 32-bit process in either a 32-bit OS or a 64-bit OS.
  • x86 operates on WOW64, which is an emulation layer subsystem, on a 64-bit OS.
  • ⁇ X64> x64 cannot operate on a 32-bit OS.
  • x64 operates as a 64-bit process in a 64-bit OS.
  • AnyCPU> AnyCPU operates as a 32-bit process in a 32-bit OS, and operates as a 64-bit process in a 64-bit OS.
  • a 32-bit process and a 64-bit process are mixed.
  • IE Internet Explorer
  • a program having a function of establishing communication by operating an active IE process will be described as an example. Due to the above-mentioned limitations, such a program cannot be operated on the 64-bit OS if the platform on which the program operates and the platform on which the IE operates are different. As a specific example, if the program is operating in a 64-bit process while the IE is operating in a 32-bit process, the program cannot access the IE.
  • this program A program according to the present embodiment (hereinafter also referred to as “this program”) will be described.
  • the platform of the process on which the IE and this program operate is also referred to as “operation platform”.
  • the IE it was understood that a 64-bit OS switches between a 32-bit process and a 64-bit process by changing only one setting value (for example, IE11). For this reason, whether the IE is operating as a 32-bit or 64-bit process may vary depending on the environment. Therefore, this program checks the operating IE, and if the platform on which the IE is operating (the operating platform) does not match the operating platform currently targeted by the program, the IE operates.
  • this program operates the IE regardless of the setting of the terminal device 21 that executes this program (that is, regardless of whether the IE is operating in a 32-bit process or a 64-bit process). Is possible.
  • This program dynamically switches the operating modules so that the following ⁇ first combination> to ⁇ third combination> are obtained.
  • ⁇ First combination> This is a combination of a 32-bit OS and a build for AnyCPU. In this case, this program operates as a 32-bit process.
  • ⁇ Second combination> This is a combination of a state where IE operates in a 32-bit process on a 64-bit OS and a build for x86. In this case, this program operates as a 32-bit process.
  • ⁇ Third combination> This is a combination of a state in which IE operates in a 64-bit process on a 64-bit OS and a build for AnyCPU. In this case, this program operates as a 64-bit process.
  • FIG. 3 is a diagram showing a schematic image of a program (this program 201) according to an embodiment of the present invention.
  • the program 201 includes a resource related to AnyCPU (hereinafter also referred to as “AnyCPU resource”) 221 and a resource related to x86 (hereinafter also referred to as “x86 resource”) 222.
  • the program 201 has a function of generating a program that operates in accordance with the AnyCPU (hereinafter also referred to as “AnyCPU compatible program”) and a program that operates in accordance with x86 (hereinafter referred to as “x86 compatible program”). It has a function to generate.
  • the AnyCPU compatible program operates in a 32-bit process or a 64-bit process.
  • the x86 compatible program operates in a 32-bit process.
  • FIG. 4 is a flowchart illustrating an example of a procedure of processing performed using the program (the present program 201) according to an embodiment of the present invention.
  • the processor 101 reads out and executes the program 201 stored in the storage device 106 using the memory 102 in the terminal device 21 is shown.
  • a module built for x86 is embedded as a resource (x86 resource 222) when building a module (AnyCPU resource 221) targeting AnyCPU.
  • x86 resource 222 the contents of the substantial processing are the same in the build for AnyCPU and the build for x86.
  • the source code may be shared.
  • Step S1 The terminal device 21 executes the program 201.
  • Step S2 When executed, the program 201 determines an operation platform of a target program (hereinafter also referred to as a “target program”) operating in the terminal device 21.
  • the target program is IE.
  • the program 201 acquires a list of shell windows that exist as functions in the terminal device 21.
  • the program 201 sequentially checks the file path in the acquired shell window list to search for a file path that is the IE program name.
  • the program 201 determines the operating platform of the found IE.
  • the program 201 determines that the file path includes the character string “x86” and determines that it is a 32-bit process, and otherwise determines that it is a 64-bit process.
  • the program 201 determines that the IE is not activated at that time, and the file at a certain time interval (for example, several seconds). Repeat the path check and wait until IE starts.
  • Step S3 The program 201 determines an operating platform of a program that is being executed due to the program 201 (in this embodiment, an AnyCPU compatible program or an x86 compatible program). Specifically, in this embodiment, the program names are different between the AnyCPU compatible program and the x86 compatible program. Then, the program 201 determines an operation platform based on the name of the program being executed.
  • Step S4 The program 201 determines whether or not the operation platform of the target program matches the operation platform of the program being executed. If these operating platforms match (step S4: YES), the processing of this flow ends. In this case, the running program uses the found IE as an operation target.
  • Step S5 On the other hand, when these operation platforms do not match (step S4: NO), the program 201 determines whether or not a switching destination program exists.
  • a 64-bit OS is used in the terminal device 21, and the operation platform of the target program and the operation platform of the program being executed match. May not.
  • the program 201 determines whether or not the switching destination program (AnyCPU compatible program or x86 compatible program in this embodiment) already exists as a file.
  • the AnyCPU-compatible program and the x86-compatible program are output to the same folder, and the program 201 checks the folder.
  • the switching destination program is an x86 compatible program.
  • the switching destination program is an AnyCPU compatible program when the currently executing program is an x86 compatible program.
  • Step S6 When the switching destination program does not exist (step S5: NO), the program 201 generates a switching destination program.
  • the program 201 outputs a switching destination program embedded as a resource of the program 201 to a file.
  • This program 201 outputs files with different names defined in the AnyCPU compatible program and x86 compatible program to the same folder.
  • Step S7 When there is a switching destination program in step S5 (step S5: YES), or when a switching destination program is generated in step S6, the program 201 executes the switching destination program as a new process.
  • Step S8 the program 201 ends the switching source program (the program being executed).
  • the program 201 may generate, for example, one or both of an AnyCPU compatible program and an x86 compatible program when it is first executed (in step S1).
  • IE is used as the target program.
  • various programs may be used as the target program.
  • the program according to the present embodiment (the present program 201) has a function of operating the target program.
  • the program may have another function related to the target program.
  • the program according to the present embodiment may be stored in advance in the storage device 106 of the terminal device 21 when the terminal device 21 is shipped.
  • the program according to the present embodiment (the program 201) is transmitted from another terminal device (terminal devices 22 to 25 in the example of FIG. 1) or another server device via the network 31. May be received by the terminal device 21 and stored in the storage device 106 of the terminal device 21.
  • the program according to the present embodiment (the program 201) is stored in the storage device 106 of the terminal device 21 by being input from the recording medium to the terminal device 21 via the input / output interface 107. Also good.
  • the terminal device 21 has a configuration in which the terminal device 21 executes the program according to the present embodiment (the program 201), the AnyCPU compatible program, and the x86 compatible program.
  • the program 201 the program 201
  • the AnyCPU compatible program the AnyCPU compatible program
  • the x86 compatible program the program 201
  • one or more of these programs may be executed by a device external to the terminal device 21.
  • a platform that is a target program (an IE program in the embodiment) that is a program (this program 201 in the embodiment) and that is another program to be operated by its own program.
  • the first function in the example of FIG. 4, step S1 for identifying the process type (in the embodiment, 64-bit process or 32-bit process) according to the AnyCPU or the platform corresponding to x86.
  • Step S2 function a second function for determining whether or not the process type of the target program identified by the first function is consistent with the first type of the process of the own program (FIG. 4).
  • the functions of steps S3 to S4) and the second function If it is determined that the process type is not consistent with the first type of the process of the own program, the process of the second type of the self program that matches the process type of the target program is started, A program for causing a computer (in the embodiment, a computer constituting the terminal device 21) to realize a third function (in the example of FIG. 4, the function of steps S5 to S8) for ending one type of process. It is.
  • a platform that is a target program (an IE program in the embodiment) that is a program (this program 201 in the embodiment) and that is another program to be operated by its own program.
  • the first function in the example of FIG.
  • step S1 for identifying the process type (in the embodiment, 64-bit process or 32-bit process) according to the AnyCPU or the platform corresponding to x86.
  • Step S2 function a second function for determining whether or not the process type of the target program identified by the first function is consistent with the first type of the process of the own program (FIG. 4).
  • steps S3 to S4 the functions of steps S3 to S4 and the second function If it is determined that the process type is not consistent with the first process type of the own program, a program file of the own program that matches the process type of the target program is generated, and the A program for causing a computer (in the embodiment, a computer constituting the terminal device 21) to realize a third function (in the example of FIG.
  • a first function for identifying a platform in the example of FIG. 4, a function of steps S2 to S4) and a second function for performing an operation in accordance with the platform identified by the first function
  • a program in the embodiment, the present program 201 for causing a computer (in the embodiment, a computer constituting the terminal device 21) to realize the functions of steps S5 to S8).
  • the first function identifies the platform on which the target program (in the embodiment, the IE program) runs, and the second function corresponds to the first platform (in the embodiment, AnyCPU or x86).
  • a first program in the embodiment, an AnyCPU compatible program or an x86 compatible program
  • a second program in the embodiment, an x86 compatible program or an AnyCPU compatible
  • the second function generates a file of the first program and a file of the second program (in the embodiment, the files are output as files).
  • the program (the program 201 in the embodiment) includes information on the first program and information on the second program (in the embodiment, it is included as a resource).
  • a program for realizing the functions of the devices according to the embodiments is recorded (stored) in a computer-readable recording medium (storage medium), and the recording medium is stored in the recording medium. Processing can be performed by causing the computer system to read and execute the recorded program.
  • the “computer system” here may include an operating system or hardware such as peripheral devices.
  • the “computer-readable recording medium” means a flexible disk, a magneto-optical disk, a ROM (Read Only Memory), a writable non-volatile memory such as a flash memory, a portable medium such as a DVD (Digital Versatile Disc), A storage device such as a hard disk built in a computer system.
  • the “computer-readable recording medium” is a volatile memory (for example, DRAM) in a computer system that becomes a server or a client when a program is transmitted through a network such as the Internet or a communication line such as a telephone line. ), Etc. that hold a program for a certain period of time.
  • the program may be transmitted from a computer system storing the program in a storage device or the like to another computer system via a transmission medium or by a transmission wave in the transmission medium.
  • the “transmission medium” for transmitting the program refers to a medium having a function of transmitting information, such as a network (communication network) such as the Internet or a communication line (communication line) such as a telephone line.
  • the above program may be for realizing a part of the functions described above.
  • the above program may be a so-called difference file (difference program) that can realize the above-described functions in combination with a program already recorded in the computer system.

Abstract

プログラムであって、自プログラムにより操作する対象となる他のプログラムである目標プログラムが動作するプラットフォームに応じた前記目標プログラムのプロセスの種類を識別する第1の機能と、前記第1の機能により識別された前記目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能と、前記第2の機能により前記目標プログラムのプロセスの種類が自プログラムのプロセスの前記第1の種類と整合していないと判定された場合、前記目標プログラムのプロセスの種類と整合する第2の種類の自プログラムのプロセスを起動させ、自プログラムの前記第1の種類のプロセスを終了させる第3の機能と、をコンピュータに実現させるためのプログラムである。

Description

プログラム
 本発明は、プログラムに関する。
 本願は、2016年3月28日に日本に出願された特願2016-064496号に基づき優先権を主張し、その内容をここに援用する。
 例えば、アプリケーション開発環境において、プロジェクトのバージョンを関連付けるテーブルが不要となる技術が知られている(特許文献1参照。)。この技術では、プラットフォームが複数バージョンある場合に、それらすべてのプラットフォームに共通に必要とされるライブラリを抽出し、ターゲットとなるプラットフォーム(プロジェクトのバージョン)に対応したファイルを探索することが行われる(特許文献1の段落0020~0021参照。)。
特開2015-162067号公報
 しかしながら、従来では、複数のプラットフォームのそれぞれに対応するプログラムを実行するために、それぞれのプラットフォームに対応するファイルを探索する等の煩雑な処理が必要となる場合があった。
 本発明の実施形態は、このような事情に鑑み、対象のプラットフォームに合わせて実行プログラムを切り替えることが可能なプログラムを提供する。
 本発明の実施形態に係るプログラムは、自プログラムにより操作する対象となる他のプログラムである目標プログラムが動作するプラットフォームに応じた前記目標プログラムのプロセスの種類を識別する第1の機能と、前記第1の機能により識別された前記目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能と、前記第2の機能により前記目標プログラムのプロセスの種類が自プログラムのプロセスの前記第1の種類と整合していないと判定された場合、前記目標プログラムのプロセスの種類と整合する第2の種類の自プログラムのプロセスを起動させ、自プログラムの前記第1の種類のプロセスを終了させる第3の機能と、をコンピュータに実現させるためのプログラムである。
 本発明の実施形態に係るプログラムは、自プログラムにより操作する対象となる他のプログラムである目標プログラムが動作するプラットフォームに応じた前記目標プログラムのプロセスの種類を識別する第1の機能と、前記第1の機能により識別された前記目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能と、前記第2の機能により前記目標プログラムのプロセスの種類が自プログラムのプロセスの前記第1の種類と整合していないと判定された場合、前記目標プログラムのプロセスの種類と整合する自プログラムのプログラムファイルを生成し、生成されたプログラムファイルに係る第2の種類のプロセスを起動させる第3の機能と、をコンピュータに実現させるためのプログラムである。
 本発明の一態様に係る前記のプログラムにおいて、前記第3の機能は、自プログラムの前記第2の種類のプロセスを起動させ、自プログラムの前記第1の種類のプロセスを終了させる、構成が用いられてもよい。
 本発明の一態様に係る以上のプログラムにおいて、自プログラムは、前記第1の種類のプロセスおよび前記第2の種類のプロセスに係るプログラムのリソースを有する、構成が用いられてもよい。
 上記したプログラムによれば、対象のプラットフォームに合わせて実行プログラムを切り替えることが可能である。
本発明の一実施形態に係る情報処理システムの概略的な構成例を示す図である。 本発明の一実施形態に係る端末装置の概略的な構成例を示す図である。 本発明の一実施形態に係るプログラムの概略的なイメージを示す図である。 本発明の一実施形態に係るプログラムを用いて行われる処理の手順の一例を示すフローチャートである。
 本発明の実施形態について図面を参照して詳細に説明する。
 [情報処理システムの構成例の説明]
 図1は、本発明の一実施形態に係る情報処理システム11の概略的な構成例を示す図である。
 情報処理システム11は、複数の端末装置21~25と、ネットワーク31を備える。
各端末装置21~25は、ネットワーク31に接続されている。
 各端末装置21~25は、コンピュータなどである。
 ネットワーク31は、インターネットなどである。
 ここで、図1の例では、複数の端末装置21~25として、5個の端末装置21~25を示したが、端末装置の数は任意であってもよい。
 また、図1の例では、1個のネットワーク31を示したが、ネットワークの数は任意であってもよい。
 また、情報処理システム11の構成は、他の構成であってもよい。
 また、本実施形態では、端末装置21~25がネットワーク31に接続される例を示すが、他の構成例として、端末装置21~25がネットワーク31に接続されなくてもよい。
 [端末装置の構成例の説明]
 図2は、本発明の一実施形態に係る端末装置21の概略的な構成例を示す図である。
 ここで、本実施形態では、各端末装置21~25について、概略的な構成は同様である。このため、本実施形態では、端末装置21を例として、構成例および動作例を示す。
 端末装置21は、プロセッサ101と、メモリ102と、ネットワークインターフェイス103と、操作部104と、表示部105と、記憶装置106と、入出力インターフェイス107と、これらを接続するバス111を備える。
 プロセッサ101は、CPU(Central Processing Unit)などから構成されており、プログラムを実行することで、当該プログラムに規定された処理を実行する。
 メモリ102は、揮発性の記憶部であり、RAM(Random Access Memory)などから構成されており、データを一時的に記憶する。RAMとしては、例えば、DRAM(Dynamic Random Access Memory)が用いられてもよい。
 ネットワークインターフェイス103は、外部のネットワーク(本実施形態では、ネットワーク31)と接続するインターフェイスである。
 操作部104は、キーボード、マウスなどのうちの1以上から構成されており、人(ユーザ)により行われる操作を受け付ける。
 表示部105は、画面を有しており、情報を当該画面に表示出力する。
 記憶装置106は、不揮発性の記憶部であり、例えば、ハードディスクなどから構成されており、データを記憶する。
 入出力インターフェイス107は、外部の記録媒体などと接続するインターフェイスである。
 [実施形態の背景の説明]
 まず、実施形態の背景の技術について説明する。
 例えば、アプリケーション開発および実行環境であるドットネットフレームワーク(.NET Framework)の上で動作するプログラムでは、実行対象に合ったビルドタイプを指定することが可能である。実行対象のプラットフォームとなるオペレーティングシステム(OS:Operating System)として、32ビットのオペレーティングシステム(32ビットOS)、または、64ビットのオペレーティングシステム(64ビットOS)がある。
 ビルドタイプの具体例として、x86と、x64と、AnyCPUを示す。
 <x86>
 x86は、32ビットOSまたは64ビットOSのうちのいずれにおいても、32ビットプロセスとして動作する。なお、x86は、64ビットOSでは、エミュレーションレイヤー・サブシステムであるWOW64で動作する。
 <x64>
 x64は、32ビットOSでは動作が不可能である。x64は、64ビットOSでは64ビットプロセスとして動作する。
 <AnyCPU>
 AnyCPUは、32ビットOSでは32ビットプロセスとして動作し、64ビットOSでは64ビットプロセスとして動作する。
 上記のことから、64ビットOSでは、32ビットプロセスと64ビットプロセスが混在することになる。具体例として、インターネットエクスプローラ(登録商標)(以下、「IE」ともいう。)のように、一般的に使用されているプログラムにおいても、32ビットプロセスと64ビットプロセスの両方の動作が存在する。
 ここで、32ビットプロセスと64ビットプロセスとの間での情報のやり取りあるいは操作には、OSレベルで一定の制限が行われている。このため、例えば、32ビットプロセスで動作しているプログラムから、64ビットプロセスで動作しているプログラムの情報を取得しようとするときに、あるいは、32ビットプロセスで動作しているプログラムから、64ビットプロセスで動作しているプログラムに対して何らかの操作を行おうとするときに、エラーになる場合が存在する。
 本実施形態では、起動中のIEのプロセス(IEプロセス)を操作して通信を確立する機能を有するプログラムを例として説明する。
 このようなプログラムは、上記した制限によって、64ビットOSでは、当該プログラムが動作するプラットフォームと、IEが動作しているプラットフォームとが異なると、IEを操作することができない状況が発生する。具体例として、当該プログラムが64ビットプロセスで動作している一方、IEが32ビットプロセスで動作していると、当該プログラムからIEにアクセスすることができない。
 [実施形態に係るプログラムの説明]
 本実施形態に係るプログラム(以下で、「本プログラム」ともいう。)について説明する。
 以下で、IEや本プログラムが動作するプロセスのプラットフォームを「動作プラットフォーム」ともいう。
 IEについて、64ビットOSでは、設定値を一つ変えるのみで32ビットプロセスと64ビットプロセスとが切り替わることが把握された(例えば、IE11)。このため、IEが32ビットと64ビットのいずれのプロセスとして動作しているかは、環境によって異なる可能性がある。
 そこで、本プログラムは、動作中のIEをチェックし、当該IEが動作しているプラットフォーム(動作プラットフォーム)が現在において本プログラムが対象としている動作プラットフォームと一致しない場合には、当該IEが動作しているプラットフォーム(動作プラットフォーム)に合わせて起動し直す機能を有する。これにより、本プログラムは、本プログラムを実行する端末装置21の設定にかかわらず(つまり、IEが32ビットプロセスと64ビットプロセスとのうちのいずれで動作していても)、IEを操作することが可能である。
 本プログラムは、次の<第1の組み合わせ>~<第3の組み合わせ>になるように、動作するモジュールを動的に切り替える。
 <第1の組み合わせ>
 32ビットOSと、AnyCPU向けビルドとの組み合わせである。この場合、本プログラムは、32ビットプロセスとして動作する。
 <第2の組み合わせ>
 64ビットOSでIEが32ビットプロセスで動作する状態と、x86向けビルドとの組み合わせである。この場合、本プログラムは、32ビットプロセスとして動作する。
 <第3の組み合わせ>
 64ビットOSでIEが64ビットプロセスで動作する状態と、AnyCPU向けビルドとの組み合わせである。この場合、本プログラムは、64ビットプロセスとして動作する。
 図3は、本発明の一実施形態に係るプログラム(本プログラム201)の概略的なイメージを示す図である。
 本プログラム201は、AnyCPUに関するリソース(以下、「AnyCPUリソース」ともいう。)221と、x86に関するリソース(以下、「x86リソース」ともいう。)222を含む。
 本プログラム201は、AnyCPUに対応して動作するプログラム(以下で、「AnyCPU対応プログラム」ともいう。)を生成する機能と、x86に対応して動作するプログラム(以下で、「x86対応プログラム」ともいう。)を生成する機能を有する。AnyCPU対応プログラムは、32ビットプロセスまたは64ビットプロセスで動作する。x86対応プログラムは、32ビットプロセスで動作する。
 図4は、本発明の一実施形態に係るプログラム(本プログラム201)を用いて行われる処理の手順の一例を示すフローチャートである。
 本実施形態では、端末装置21において、プロセッサ101が、メモリ102を用いて、記憶装置106に記憶された本プログラム201を読み出して実行する場合を示す。
 まず、動作プラットフォームを動的に切り替え可能とする本プログラム201について、AnyCPUを対象とするモジュール(AnyCPUリソース221)のビルド時に、x86向けにビルドしたモジュールをリソース(x86リソース222)として埋め込む。
 ここで、本実施形態では、AnyCPU向けビルドと、x86向けビルドとで、実質的な処理の中身は同等である。これら2種類のビルドにおいて、例えば、ソースコードを共有してもよい。
 (ステップS1)
 端末装置21において、本プログラム201を実行する。
 (ステップS2)
 本プログラム201は、実行されると、端末装置21において動作している目標となるプログラム(以下で、「目標プログラム」ともいう。)の動作プラットフォームを判定する。本実施形態では、目標プログラムはIEである。
 具体的には、本プログラム201は、端末装置21における機能として存在するシェルウインドウ一覧を取得する。そして、本プログラム201は、取得したシェルウインドウ一覧において、ファイルパスを順次チェックして、IEのプログラム名であるファイルパスを探索する。IEのプログラム名であるファイルパスを発見した場合、本プログラム201は、発見したIEの動作プラットフォームを判定する。本実施形態では、本プログラム201は、ファイルパスに「x86」という文字列が含まれている場合には32ビットプロセスであると判定し、他の場合には64ビットプロセスであると判定する。
 なお、IEのプログラム名であるファイルパスを発見しなかった場合、本プログラム201は、その時点ではIEが起動していないと判定して、一定の時間間隔(例えば、数秒)おきのタイミングでファイルパスのチェックを繰り返して行い、IEが起動するまで待機する。
 (ステップS3)
 本プログラム201は、本プログラム201に起因して実行中のプログラム(本実施形態では、AnyCPU対応プログラム、または、x86対応プログラム)の動作プラットフォームを判定する。
 具体的には、本実施形態では、AnyCPU対応プログラムとx86対応プログラムとで、プログラムの名称を異ならせている。そして、本プログラム201は、実行中のプログラムの名称に基づいて、動作プラットフォームを判定する。
 (ステップS4)
 本プログラム201は、目標プログラムの動作プラットフォームと実行中のプログラムの動作プラットフォームとが一致するか否かを判定する。
 これらの動作プラットフォームが一致する場合には(ステップS4:YES)、本フローの処理が終了する。この場合、実行中のプログラムが、発見されたIEを操作対象として利用する。
 (ステップS5)
 一方、これらの動作プラットフォームが一致しない場合には(ステップS4:NO)、本プログラム201は、切り替え先のプログラムが存在するか否かを判定する。
 ここで、これらの動作プラットフォームが一致しない場合としては、本実施形態では、端末装置21において64ビットOSが使用されており、且つ、目標プログラムの動作プラットフォームと実行中のプログラムの動作プラットフォームとが一致しない場合がある。
 この場合、本プログラム201は、切り替え先のプログラム(本実施形態では、AnyCPU対応プログラム、または、x86対応プログラム)が既にファイルとして存在するか否かを判定する。ここで、本実施形態では、AnyCPU対応プログラムおよびx86対応プログラムが同一のフォルダに出力される構成としてあり、本プログラム201は当該フォルダをチェックする。
 切り替え先のプログラムは、現在の実行中のプログラムがAnyCPU対応プログラムである場合には、x86対応プログラムである。同様に、切り替え先のプログラムは、現在の実行中のプログラムがx86対応プログラムである場合には、AnyCPU対応プログラムである。
 (ステップS6)
 切り替え先のプログラムが存在しない場合(ステップS5:NO)、本プログラム201は、切り替え先のプログラムを生成する。
 本実施形態では、本プログラム201は、本プログラム201のリソースとして埋め込まれている切り替え先のプログラムをファイルに出力する。本プログラム201は、AnyCPU対応プログラムとx86対応プログラムとで、それぞれに定められた別の名称のファイルを同一のフォルダに出力する。
 (ステップS7)
 ステップS5において切り替え先のプログラムが存在した場合(ステップS5:YES)、または、ステップS6において切り替え先のプログラムを生成した場合、本プログラム201は、切り替え先のプログラムを新規プロセスとして実行する。
 (ステップS8)
 そして、本プログラム201は、切り替え元のプログラム(実行中であったプログラム)を終了する。
 なお、本プログラム201は、例えば、最初に実行されたときに(ステップS1のときに)、AnyCPU対応プログラム、または、x86対応プログラムのうちの一方または両方を生成してもよい。
 [実施形態のまとめ]
 以上のように、本実施形態に係るプログラム(本プログラム201)では、対象のプラットフォームに合わせて実行プログラムを切り替えることが可能であり、複数のプラットフォームで動作を行うことが可能である。
 ここで、本実施形態では、目標プログラムとして、IEを用いたが、他の構成例として、目標プログラムとして様々なプログラムが用いられてもよい。
 また、本実施形態に係るプログラム(本プログラム201)は、目標プログラムを操作する機能を有したが、他の構成例として、目標プログラムに関する他の機能を有してもよい。
 なお、一例として、本実施形態に係るプログラム(本プログラム201)は、端末装置21の出荷時に当該端末装置21の記憶装置106にあらかじめ記憶されてもよい。
 他の例として、本実施形態に係るプログラム(本プログラム201)は、他の端末装置(図1の例では、端末装置22~25)または他のサーバ装置などからネットワーク31を介して端末装置21に送信されることで、当該端末装置21により受信されて、当該端末装置21の記憶装置106に記憶されてもよい。
 他の例として、本実施形態に係るプログラム(本プログラム201)は、記録媒体から入出力インターフェイス107を介して端末装置21に入力されることで、当該端末装置21の記憶装置106に記憶されてもよい。
 また、本実施形態では、端末装置21において、当該端末装置21が本実施形態に係るプログラム(本プログラム201)、AnyCPU対応プログラム、およびx86対応プログラムを実行する構成を示したが、他の構成例として、これらのうちの1以上のプログラムを端末装置21の外部の装置により実行させてもよい。
 一構成例として、プログラム(実施形態では、本プログラム201)であって、自プログラムにより操作する対象となる他のプログラムである目標プログラム(実施形態では、IEのプログラム)が動作するプラットフォーム(実施形態では、AnyCPUまたはx86に対応するプラットフォーム)に応じた目標プログラムのプロセスの種類(実施形態では、64ビットプロセス、あるいは、32ビットプロセス)を識別する第1の機能(図4の例では、ステップS1~ステップS2の機能)と、第1の機能により識別された目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能(図4の例では、ステップS3~ステップS4の機能)と、第2の機能により目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合していないと判定された場合、目標プログラムのプロセスの種類と整合する第2の種類の自プログラムのプロセスを起動させ、自プログラムの第1の種類のプロセスを終了させる第3の機能(図4の例では、ステップS5~ステップS8の機能)と、をコンピュータ(実施形態では、端末装置21を構成するコンピュータ)に実現させるためのプログラムである。
 一構成例として、プログラム(実施形態では、本プログラム201)であって、自プログラムにより操作する対象となる他のプログラムである目標プログラム(実施形態では、IEのプログラム)が動作するプラットフォーム(実施形態では、AnyCPUまたはx86に対応するプラットフォーム)に応じた目標プログラムのプロセスの種類(実施形態では、64ビットプロセス、あるいは、32ビットプロセス)を識別する第1の機能(図4の例では、ステップS1~ステップS2の機能)と、第1の機能により識別された目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能(図4の例では、ステップS3~ステップS4の機能)と、第2の機能により目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合していないと判定された場合、目標プログラムのプロセスの種類と整合する自プログラムのプログラムファイルを生成し、生成されたプログラムファイルに係る第2の種類のプロセスを起動させる第3の機能(図4の例では、ステップS5~ステップS7の機能)と、をコンピュータ(実施形態では、端末装置21を構成するコンピュータ)に実現させるためのプログラムである。
 一構成例として、当該プログラムでは、第3の機能は、自プログラムの第2の種類のプロセスを起動させ、自プログラムの第1の種類のプロセスを終了させる(図4の例では、ステップS8の機能)。
 一構成例として、以上のプログラムでは、自プログラムは、第1の種類のプロセスおよび第2の種類のプロセスに係るプログラムのリソースを有する。
<他の構成例>
 一構成例として、プラットフォームを識別する第1の機能(図4の例では、ステップS2~ステップS4の機能)と、第1の機能により識別されたプラットフォームに合わせて動作を行う第2の機能(図4の例では、ステップS5~ステップS8の機能)と、をコンピュータ(実施形態では、端末装置21を構成するコンピュータ)に実現させるためのプログラム(実施形態では、本プログラム201)である。
 一構成例として、第1の機能は、目標プログラム(実施形態では、IEのプログラム)が動作するプラットフォームを識別し、第2の機能は、第1のプラットフォーム(実施形態では、AnyCPUまたはx86に対応するプラットフォーム)に合った第1のプログラム(実施形態では、AnyCPU対応プログラムまたはx86対応プログラム)が実行されているときに、第1の機能により識別されたプラットフォームが第1のプラットフォームではないと判定した場合に、第1の機能により識別されたプラットフォームに対応する第2のプラットフォーム(実施形態では、x86またはAnyCPUに対応するプラットフォーム)に合った第2のプログラム(実施形態では、x86対応プログラムまたはAnyCPU対応プログラム)を実行する。
 一構成例として、第2の機能は、第1のプログラムのファイルおよび第2のプログラムのファイルを生成する(実施形態では、ファイルとして出力する)。
 一構成例として、プログラム(実施形態では、本プログラム201)は、第1のプログラムの情報および第2のプログラムの情報を含む(実施形態では、リソースとして含む)。
 以上のように、実施形態に係る装置(例えば、端末装置21~25)の機能を実現するためのプログラムをコンピュータ読み取り可能な記録媒体(記憶媒体)に記録(記憶)して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行することにより、処理を行うことができる。
 なお、ここでいう「コンピュータシステム」とは、オペレーティングシステムあるいは周辺機器等のハードウェアを含むものであってもよい。
 また、「コンピュータ読み取り可能な記録媒体」とは、フレキシブルディスク、光磁気ディスク、ROM(Read Only Memory)、フラッシュメモリ等の書き込み可能な不揮発性メモリ、DVD(Digital Versatile Disc)等の可搬媒体、コンピュータシステムに内蔵されるハードディスク等の記憶装置のことをいう。
 さらに、「コンピュータ読み取り可能な記録媒体」とは、インターネット等のネットワークあるいは電話回線等の通信回線を介してプログラムが送信された場合のサーバやクライアントとなるコンピュータシステム内部の揮発性メモリ(例えば、DRAM)のように、一定時間プログラムを保持しているものも含む。
 また、上記のプログラムは、このプログラムを記憶装置等に格納したコンピュータシステムから、伝送媒体を介して、あるいは、伝送媒体中の伝送波により他のコンピュータシステムに伝送されてもよい。ここで、プログラムを伝送する「伝送媒体」は、インターネット等のネットワーク(通信網)あるいは電話回線等の通信回線(通信線)のように情報を伝送する機能を有する媒体のことをいう。
 また、上記のプログラムは、前述した機能の一部を実現するためのものであってもよい。さらに、上記のプログラムは、前述した機能をコンピュータシステムに既に記録されているプログラムとの組み合わせで実現できるもの、いわゆる差分ファイル(差分プログラム)であってもよい。
 なお、本発明を実施の形態を用いて説明したが、本発明の技術的範囲は上記実施の形態には限定されない。本発明の精神及び範囲から逸脱することなく様々に変更したり代替態様を採用したりすることが可能なことは、当業者に明らかである。
11…情報処理システム
21~25…端末装置
31…ネットワーク
101…プロセッサ
102…メモリ
103…ネットワークインターフェイス
104…操作部
105…表示部
106…記憶装置
107…入出力インターフェイス
111…バス
201…プログラム
221…AnyCPUリソース
222…x86リソース

Claims (4)

  1.  プログラムであって、
     自プログラムにより操作する対象となる他のプログラムである目標プログラムが動作するプラットフォームに応じた前記目標プログラムのプロセスの種類を識別する第1の機能と、
     前記第1の機能により識別された前記目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能と、
     前記第2の機能により前記目標プログラムのプロセスの種類が自プログラムのプロセスの前記第1の種類と整合していないと判定された場合、前記目標プログラムのプロセスの種類と整合する第2の種類の自プログラムのプロセスを起動させ、自プログラムの前記第1の種類のプロセスを終了させる第3の機能と、
     をコンピュータに実現させるためのプログラム。
  2.  プログラムであって、
     自プログラムにより操作する対象となる他のプログラムである目標プログラムが動作するプラットフォームに応じた前記目標プログラムのプロセスの種類を識別する第1の機能と、
     前記第1の機能により識別された前記目標プログラムのプロセスの種類が自プログラムのプロセスの第1の種類と整合しているか否かを判定する第2の機能と、
     前記第2の機能により前記目標プログラムのプロセスの種類が自プログラムのプロセスの前記第1の種類と整合していないと判定された場合、前記目標プログラムのプロセスの種類と整合する自プログラムのプログラムファイルを生成し、生成されたプログラムファイルに係る第2の種類のプロセスを起動させる第3の機能と、
     をコンピュータに実現させるためのプログラム。
  3.  前記第3の機能は、自プログラムの前記第2の種類のプロセスを起動させ、自プログラムの前記第1の種類のプロセスを終了させる、
     請求項2に記載のプログラム。
  4.  自プログラムは、前記第1の種類のプロセスおよび前記第2の種類のプロセスに係るプログラムのリソースを有する、
     請求項1から請求項3のいずれか1項に記載のプログラム。
PCT/JP2017/009503 2016-03-28 2017-03-09 プログラム WO2017169631A1 (ja)

Priority Applications (1)

Application Number Priority Date Filing Date Title
SG11201808130RA SG11201808130RA (en) 2016-03-28 2017-03-09 Program

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2016064496A JP6129376B1 (ja) 2016-03-28 2016-03-28 プログラム
JP2016-064496 2016-03-28

Publications (1)

Publication Number Publication Date
WO2017169631A1 true WO2017169631A1 (ja) 2017-10-05

Family

ID=58714825

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2017/009503 WO2017169631A1 (ja) 2016-03-28 2017-03-09 プログラム

Country Status (4)

Country Link
JP (1) JP6129376B1 (ja)
SG (1) SG11201808130RA (ja)
TW (1) TWI625673B (ja)
WO (1) WO2017169631A1 (ja)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009086722A (ja) * 2007-09-27 2009-04-23 Canon Inc 情報処理装置、情報処理方法、プログラム、及び記憶媒体
JP2010257033A (ja) * 2009-04-22 2010-11-11 Hitachi Software Eng Co Ltd ユーザログ収集装置、及びユーザログ管理システム
WO2013046595A1 (ja) * 2011-09-26 2013-04-04 日本電気株式会社 情報処理システム、情報処理方法、情報処理装置およびその制御方法と制御プログラム

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5432937A (en) * 1993-08-20 1995-07-11 Next Computer, Inc. Method and apparatus for architecture independent executable files
US5857106A (en) * 1996-05-31 1999-01-05 Hewlett-Packard Company Runtime processor detection and installation of highly tuned processor specific routines
TW200723095A (en) * 2005-12-14 2007-06-16 Inventec Corp Method using 32-bit main program to intercept 64-bit messages in a 64-bit system
JP5681956B2 (ja) * 2010-06-11 2015-03-11 株式会社アドラックス Usbメモリに内蔵したプログラムをそのまま実行させる方法
JP5609333B2 (ja) * 2010-07-05 2014-10-22 富士通株式会社 起動処理方法、情報処理装置、起動処理プログラム及び同プログラムを記録したコンピュータ読取可能な記録媒体
WO2012037270A1 (en) * 2010-09-15 2012-03-22 Myspace, Inc. Dynamic native binding for managed assemblies
US10402208B2 (en) * 2012-06-18 2019-09-03 Microsoft Technology Licensing, Llc Adaptive portable libraries

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009086722A (ja) * 2007-09-27 2009-04-23 Canon Inc 情報処理装置、情報処理方法、プログラム、及び記憶媒体
JP2010257033A (ja) * 2009-04-22 2010-11-11 Hitachi Software Eng Co Ltd ユーザログ収集装置、及びユーザログ管理システム
WO2013046595A1 (ja) * 2011-09-26 2013-04-04 日本電気株式会社 情報処理システム、情報処理方法、情報処理装置およびその制御方法と制御プログラム

Also Published As

Publication number Publication date
TWI625673B (zh) 2018-06-01
JP2017182202A (ja) 2017-10-05
SG11201808130RA (en) 2018-10-30
TW201734782A (zh) 2017-10-01
JP6129376B1 (ja) 2017-05-17

Similar Documents

Publication Publication Date Title
US10812566B2 (en) Distributed steam processing
EP2021940B1 (en) Booting an operating system in discrete stages
US7962496B2 (en) Migrating personality of computing environment from source platform to target platform
US9207959B2 (en) Creating a virtual disk using set of binding information of a paravirtual network interface card and a physical network interface card
US10574724B2 (en) Automatic discovery of management nodes and generation of CLI using HA module
US9329858B2 (en) Managing access to resource versions in shared computing environments
US20070239979A1 (en) Method and apparatus to protect policy state information during the life-time of virtual machines
WO2016058488A1 (zh) 一种用于提供sdk文件的方法与设备
US20160019037A1 (en) Managing parameter types for generic functions
US10809983B1 (en) Using an abstract syntax tree for generating names in source code
CN111796860A (zh) 微前端方案实现方法及装置
JP5886450B2 (ja) ハイブリッドのエミュレーション及びカーネル関数処理のシステム及び方法
US11263297B2 (en) Dynamic insertion of variablized secrets in a pipeline integration system
US20140173263A1 (en) Booting from a trusted network image
US8914815B2 (en) Automated framework for tracking and maintaining kernel symbol list types
US10353700B1 (en) Code base sharing between standalone and web-based versions of an application via an emulated network communication channel
Bhat et al. Practical Docker with Python
JP6129376B1 (ja) プログラム
CN111800511A (zh) 同步登录态的处理方法、系统、设备及可读存储介质
CN110782040A (zh) 一种pytorch任务训练方法、装置、设备及介质
US20100037220A1 (en) System and Method for Creating and Associating a Virtual Pseudo TTY with a Running Process
JP5353891B2 (ja) 分散処理システム、分散処理方法およびプログラム
US20160019193A1 (en) Converting terminal-based legacy applications to web-based applications
CN112068814A (zh) 可执行文件的生成方法、装置、系统及介质
US20090006942A1 (en) Embedded markup resources

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 11201808130R

Country of ref document: SG

NENP Non-entry into the national phase

Ref country code: DE

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17774176

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 17774176

Country of ref document: EP

Kind code of ref document: A1