Close - Maple Help

FileTools[Compressed]

 Close
 close a previously opened compressed file

 Calling Sequence Close(file)

Parameters

 file - string, string in string, or integer file descriptor

Description

 • The Close command closes a file that has been opened with FileTools[Compressed][Open].

Examples

 > $\mathrm{file}≔\mathrm{FileTools}\left[\mathrm{TemporaryFilename}\right]\left(\mathrm{cat}\left(\mathrm{FileTools}\left[\mathrm{TemporaryDirectory}\right]\left(\right),\mathrm{kernelopts}\left(\mathrm{dirsep}\right),"GZtest-"\right)\right)$
 ${\mathrm{file}}{≔}{"/tmp/mpldoc17/GZtest-yYoYxV9R"}$ (1)
 > $\mathrm{fd}≔\mathrm{FileTools}\left[\mathrm{Compressed}\right]\left[\mathrm{Open}\right]\left(\mathrm{file}\right)$
 ${\mathrm{fd}}{≔}{8294608}$ (2)
 > $\mathrm{FileTools}\left[\mathrm{Compressed}\right]\left[\mathrm{Close}\right]\left(\mathrm{fd}\right)$
 ${0}$ (3)
 > $\mathrm{FileTools}\left[\mathrm{Compressed}\right]\left[\mathrm{Open}\right]\left(\mathrm{file}\right)$
 ${8294608}$ (4)
 > $\mathrm{FileTools}\left[\mathrm{Compressed}\right]\left[\mathrm{Close}\right]\left(\mathrm{file}\right)$
 ${0}$ (5)
 > $\mathrm{FileTools}\left[\mathrm{Compressed}\right]\left[\mathrm{Close}\right]\left(\mathrm{file}\right)$

Compatibility

 • The FileTools[Compressed][Close] command was introduced in Maple 16.