Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
get rid of mode for open in Java bindings too
[simgrid.git] / src / bindings / java / org / simgrid / msg / File.java
index 032a6bb..426ea07 100644 (file)
@@ -18,24 +18,22 @@ public class File {
        private long bind = 0;
        /**
         * Constructor, opens the file.
-        * @param storage is the name where you can find the stream 
+        * @param storage is the name where you can find the file descriptor 
         * @param path is the file location on the storage 
-        * @param mode points to a string beginning with one of the following sequences (Additional characters may follow these sequences.): r Open text file for reading. The stream is positioned at the beginning of the file. r+ Open for reading and writing. The stream is positioned at the beginning of the file. w Truncate file to zero length or create text file for writing. The stream is positioned at the beginning of the file. w+ Open for reading and writing. The file is created if it does not exist, otherwise it is truncated. The stream is positioned at the beginning of the file. a Open for appending (writing at end of file). The file is created if it does not exist. The stream is positioned at the end of the file. a+ Open for reading and appending (writing at end of file). The file is created if it does not exist. The initial file position for reading is at the beginning of the file, but output is always appended to the end of the file.
         */
-       public File(String storage, String path, String mode) {
+       public File(String storage, String path) {
                this.storage = storage;
-               open(storage, path, mode);
+               open(storage, path);
        }
        protected void finalize() {
 
        }
        /**
         * Opens the file whose name is the string pointed to by path. 
-        * @param storage is the name where you can find the stream 
+        * @param storage is the name where you can find the file descriptor 
         * @param path is the file location on the storage
-        * @param mode points to a string beginning with one of the following sequences (Additional characters may follow these sequences.): r Open text file for reading. The stream is positioned at the beginning of the file. r+ Open for reading and writing. The stream is positioned at the beginning of the file. w Truncate file to zero length or create text file for writing. The stream is positioned at the beginning of the file. w+ Open for reading and writing. The file is created if it does not exist, otherwise it is truncated. The stream is positioned at the beginning of the file. a Open for appending (writing at end of file). The file is created if it does not exist. The stream is positioned at the end of the file. a+ Open for reading and appending (writing at end of file). The file is created if it does not exist. The initial file position for reading is at the beginning of the file, but output is always appended to the end of the file.
         */
-       protected native void open(String storage, String path, String mode);
+       protected native void open(String storage, String path);
        /**
         * Read elements of a file. 
         * @param size of each element