cat()
Definition
cat
(filename, useBinaryMode)- Returns the contents of the specified file. The method returns withoutput relative to the current shell session and does not impact theserver.
ParameterTypeDescriptionfilename
stringThe filepath to open. The filepath must be on the local file system.useBinaryMode
booleanOptional. Flag to determine whether to openfile in binary mode or text mode.
Applicable for Windows.
- Specify
true
to open the file in binary mode.
On Windows, opening the file in binary mode leaves thecharacter ‘\n’ as is.
- Specify
false
to open the file in text mode.
On Windows, opening the file in text mode converts thecharacter ‘\n’ to ‘\r\n’.
The default value is false
.
New in version 4.0.5.