Interface between programming languages and method therefor
First Claim
1. In a device that uses a Java programming language and a second programming language, a method of emulating more simultaneously open files in the device than is permitted by an operating system of the device comprising:
- while running a predetermined program in the Java programming language, attempting to access a file stored within the device;
determining whether the file is already open from prior execution;
if the file is open, access to the file proceeds;
if the file is not open, a determination is made by the device of a number of files the device permits to be simultaneously open;
if the number is not exceeded by opening the file, the file is opened;
if the number is exceeded by opening the file, the device emulates having more files open than the number allowed by;
(1) saving a file position for at least one open file, the file position designating where a next byte in the at least one open file would be accessed;
(2) closing the at least one open file; and
(3) opening the file;
wherein subsequent accesses to the at least one open file that has been closed are made transparently to the predetermined program in the Java programming language by closing at least one currently open file, retrieving the file position previously saved, and opening and restoring the file position for that file.
22 Assignments
0 Petitions
Accused Products
Abstract
An interface (20) implements a file system for supporting Java record and resource management between an operating system (28) using a first programming language other than Java and a suite (22) of Java applications. The interface provides a method for maintaining any number of files to be open in a manner transparent to the Java applications. Location information of a file is put in storage allocated for usage by Java code when a maximum number of open files is exceeded. A table (506) is used to translate between file names of differing length and to identify directories in a manner to provide a hierarchical file system. An identifier is associated with a shortened Java file name in the table to quickly identify an operating system file with a shortened file name.
17 Citations
20 Claims
-
1. In a device that uses a Java programming language and a second programming language, a method of emulating more simultaneously open files in the device than is permitted by an operating system of the device comprising:
-
while running a predetermined program in the Java programming language, attempting to access a file stored within the device;
determining whether the file is already open from prior execution;
if the file is open, access to the file proceeds;
if the file is not open, a determination is made by the device of a number of files the device permits to be simultaneously open;
if the number is not exceeded by opening the file, the file is opened;
if the number is exceeded by opening the file, the device emulates having more files open than the number allowed by;
(1) saving a file position for at least one open file, the file position designating where a next byte in the at least one open file would be accessed;
(2) closing the at least one open file; and
(3) opening the file;
wherein subsequent accesses to the at least one open file that has been closed are made transparently to the predetermined program in the Java programming language by closing at least one currently open file, retrieving the file position previously saved, and opening and restoring the file position for that file. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
-
-
14. A method of interfacing a file system in a device that uses both a Java programming language and another programming language, comprising:
-
selecting a predetermined operating system;
overlying a Java virtual machine for executing programs within the operating system in the another programming language;
overlying the operating system with a file system interface layer;
overlying libraries to the Java virtual machine and the file system interface layer, the libraries running in the Java programming language;
using the file system interface to determine if a maximum number of open Java files has been exceeded, and if so, storing position information of at least one open Java file in a currently open Java application prior to closing the at least one open Java file; and
subsequently reopening the at least one open Java file by restoring the position information transparent to any Java application. - View Dependent Claims (15, 16, 17, 18, 19, 20)
-
Specification