close
close();
The close method of the File class closes an open file.
As the file is automatically closed when the file object is deleted, this method is optional.
However, this applies only when you delete the file object yourself; for example, in the epilog of a method. If you leave it to JADE to delete the object when the process terminates, the file may still be held open and you will have to terminate the node that owned the process.
The following is an example of the use of the close method.
resetOutputFile1() updating; begin // If an output file has been created, it is reset by deleting the // contents and then redefining the file name. if outputFile1.isAvailable then outputFile1.close; outputFile1.purge; outputFile1.allowCreate := true; outputFile1.fileName := "c:\temp\outputFile1.txt"; endif; end;