Class DsnCopy
- java.lang.Object
-
- zowe.client.sdk.zosfiles.dsn.methods.DsnCopy
-
public class DsnCopy extends Object
Provides copy dataset and dataset member functionality- Version:
- 2.0
- Author:
- Leonid Baranov, Frank Giordano
-
-
Constructor Summary
Constructors Constructor Description DsnCopy(ZosConnection connection)DsnCopy constructorDsnCopy(ZosConnection connection, ZoweRequest request)Alternative DsnCopy constructor with ZoweRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Responsecopy(String fromDataSetName, String toDataSetName, boolean replace, boolean copyAllMembers)This copy method allows the following copy operations:ResponsecopyCommon(CopyParams params)Copy dataset or dataset member request driven by CopyParams object settings
-
-
-
Constructor Detail
-
DsnCopy
public DsnCopy(ZosConnection connection)
DsnCopy constructor- Parameters:
connection- is a connection, see ZOSConnection object
-
DsnCopy
public DsnCopy(ZosConnection connection, ZoweRequest request) throws Exception
Alternative DsnCopy constructor with ZoweRequest object. This is mainly used for internal code unit testing with mockito, and it is not recommended to be used by the larger community.- Parameters:
connection- connection information, see ZOSConnection objectrequest- any compatible ZoweRequest Interface object- Throws:
Exception- processing error
-
-
Method Detail
-
copy
public Response copy(String fromDataSetName, String toDataSetName, boolean replace, boolean copyAllMembers) throws Exception
This copy method allows the following copy operations:- sequential dataset to sequential dataset - sequential dataset to partition dataset member - partition dataset member to partition dataset member - partition dataset member to partition dataset non-existing member - partition dataset member to sequential dataset
If copyAllMembers parameter value sent as true it will perform a copy of all members in source partition dataset to the target partition dataset if no member name included in the source partition dataset value (fromDataSetName).
- Parameters:
fromDataSetName- is a name of source dataset (e.g. 'SOURCE.DATASET' or 'SOURCE.DATASET(MEMBER)')toDataSetName- is a name of target dataset (e.g. 'TARGET.DATASET' or 'TARGET.DATASET(MEMBER)')replace- if true members in the target dataset are replacedcopyAllMembers- if true copy all members in source partition dataset specified- Returns:
- http response object
- Throws:
Exception- error processing copy request
-
copyCommon
public Response copyCommon(CopyParams params) throws Exception
Copy dataset or dataset member request driven by CopyParams object settings- Parameters:
params- contains copy dataset parameters- Returns:
- http response object
- Throws:
Exception- error processing copy request
-
-