function
Library: File system utilities (OMVFS legacy)
Include: omvfs.xin |
define external function vfsCopy value stream sourcepath to value stream targetpath or define external function vfsCopy value stream sourcepath to value stream targetURL in value vfsDir targetdir or define external function vfsCopy value stream sourceURL on value vfsDir sourcedir to value stream targetpath or define external function vfsCopy value stream sourceURL on value vfsDir sourcedir to value stream targetURL in value vfsDir targetdir
Argument definitions
Use vfsCopy to copy
You must include the following line at the beginning of your OmniMark program:
include "omvfs.xin"
The copy source sourcepath must:
The copy target targetpath must:
The copy source sourceURL must:
The vfsDir object sourcedir must:
The copy target targetURL must:
The vfsDir object targetdir must:
If targetpath does not exist, targetpath will be the name of the copy source. If targetpath exists (is a directory) a copy of the copy source will be placed inside the directory targetpath.
If targetURL does not exist, targetURL will be the name of the copy source. If targetURL exists (is a directory) a copy of the copy source will be placed inside the directory targetURL.
External exception VFS300 is thrown for any general OS operation failure. The text accompanying the exception will contain details on the reason for the failure.
External exception VFS111 is thrown if an URL supplied as a parameter to this function contains invalid encoding.
External exception VFS004 is thrown if the URL exceeds system length limits.
For complete details on absolute URLs and valid encoding, see Internet Standards RFC 1738: Uniform Resource Locators.
For complete details on relative URLs, see Internet Standards RFC 1808: Relative Uniform Resource Locators.
Making a copy of a directory and its contents at a new location with a new name.
include "omvfs.xin" process . . . vfsCopy "../version1" to "/oldversion"
Making a copy of a file at a new location with the same name.
include "omvfs.xin" process local vfsDir Chicago . . . set Chicago to vfsConnect "file:///ChicagoFormats/Style/" . . . vfsCopy "../version1.exe" to "version1.exe" in Chicago