Copies all (non-hidden) files contained in the specified source directory to the specified destination directory.
This function may be particularly useful to copy certain external files associated with the generated documentation
(e.g. images). See also GOMOutputInfo.inputFilesPath
generator property for that matter.
Parameters:
srcDir
If the pathname is not an absolute one, it is resolved against the current system directory.
The allowed name-separator character may be '/'
or '\'
.
When the specified pathname is null
or empty string or the source directory
does not exist, the function does nothing.
dstDir
If the provided pathname is not an absolute one, it is resolved against the current system directory.
The allowed name-separator character may be '/'
or '\'
.
When this parameter is null
or empty string, the function does nothing.
If the destination directory does not exist, it will be created including any necessary but nonexistent parent directories.
If the destination directory already exists, anything contained in it will remain except the files whose names are equal to the names of the copied files. Such files which will be overwritten.
recursive
true
, all subdirectories and their contents are recursively copied
to the destination directory.
When this parameter is absent, it is assumed to be false
.
excludeSubdirs
The null
parameter value (or empty array) will mean no excluded names are specified.
The generator tracks each call of the copyFiles()
function so that for each set of parameters:
{ srcDir
(as absolute pathname);
dstDir
(as absolute pathname);
recursive
excludeSubdirs }
copyFiles()
function is called from an expression that may be
repeatedly executed a number of times.
For a given set of parameters, the function always returns the same result during both the first and the subsequent "idle" calls.
See Also:
copyFile()