java.lang.Object
com.ibm.jzos.sample.nonvsam.file.CopyFile
This sample demonstrates how to copy data from one file to
another, appending to the second file if it already exists.
The file names are given as arguments.
- Since:
- 2.4.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidCopies a non-VSAM file as source to the other non-VSAM file as destination.static voidThe main method accepts two file names as the only arguments and callscopy(String, String)to copy records from the source file to the destination file.
-
Constructor Details
-
CopyFile
public CopyFile()
-
-
Method Details
-
main
The main method accepts two file names as the only arguments and callscopy(String, String)to copy records from the source file to the destination file.- Parameters:
args- The names of the files to read from and write to
-
copy
Copies a non-VSAM file as source to the other non-VSAM file as destination.- Parameters:
source- The name of the file to read fromdestination- The name of the file to create and copy to
-