Overview of the FileTools Package
Calling Sequence
Description
List of FileTools Subpackages
List of FileTools Package Commands
List of FileTools:-Text Module Commands
List of FileTools:-Binary Module Commands
List of FileTools:-Compressed Module Commands
FileTools:-command(arguments)
command(arguments)
The FileTools package is a collection of file manipulation utilities.
The FileTools package contains three subpackages: Text, Binary, and Compressed, as well as other commands that can be applied to files.
Text files contain certain formatting concepts that do not apply to binary data (for example, lines and newline characters). Also, the data in a text file is represented using characters. In Maple, the internal representation is converted to a string and then written. For more information, see the Text subpackage help page.
The data in a binary file is written to disk using a binary representation. Currently, this means that only hardware data types, integers, and floats can be written using the Binary module. For more information, see the Binary subpackage help page.
For working with compressed files, see the Compressed subpackage help page.
Each command in the FileTools package can be accessed by using either the long form or the short form of the command name in the command calling sequence.
The long form, FileTools:-command, is always available. The short form can be used after loading the package.
The Text subpackage contains commands specific for manipulating text files.
The Binary subpackage contains commands for working with files of binary data.
The Compressed subpackage contains commands for the creation, reading, and writing of compressed files.
AbsolutePath
return absolute filepath
AtEndOfFile
determine if the current position of a file is at the end
Basename
return base name of file
CanonicalPath
return the canonical filepath
Copy
copy a file
Exists
determine if a file exists in file system or in a Workbook
Extension
return file extension
Filename
return filename
Flush
flush output for a buffered file
Hash
compute a hash value for a file
IsDirectory
determine if a filename is a directory
IsExecutable
determine if the user has execute permission for a file
IsLink
determine if a file is a symbolic link
IsLockable
determine if a file lock is obtainable
IsOpen
determine if a filename is an open file
IsReadable
determine if the user has read permission for a file
IsWritable
determine if the user has write permission for a file
JoinPath
join components into filepath
ListDirectory
display the contents of a directory
Lock
obtain a file lock
MakeDirectory
make a directory
ModificationTime
obtain the modification time of a file
ParentDirectory
return parent directory
Position
set or return the current position within a file
Remove
remove a file
RemoveDirectory
remove a directory
Rename
rename a file
Size
obtain size of a file in bytes
SplitPath
split filepath into components
Status
obtain status information about a file
TemporaryDirectory
return a directory for storing temporary files
TemporaryFile
return a filepath that may be used for a temporary file
TemporaryFilename
return a filename that may be used for a temporary file
Unlock
release a file lock
Walk
generate an iterator to traverse subdirectories
Close
CountCharacters
CountFloats
CountIntegers
CountLines
Open
OpenTemporaryFile
ReadCharacter
ReadFile
ReadFloat
ReadInteger
ReadLine
ReadNextFloat
ReadNextInteger
ReadString
WriteCharacter
WriteFile
WriteFloat
WriteInteger
WriteLine
WriteString
CountBytes
Read
Write
Contents
Extract
ReadWriteFile
To display the help page for a particular FileTools command, see Getting Help with a Command in a Package.
See Also
examples/FileTools
FileTools:-Binary
FileTools:-Text
help
module
symbol
UsingPackages
with
Download Help Document