Class DsnWrite
- java.lang.Object
-
- zowe.client.sdk.zosfiles.dsn.methods.DsnWrite
-
public class DsnWrite extends Object
Provides write dataset and member functionality- Version:
- 2.0
- Author:
- Leonid Baranov, Frank Giordano
-
-
Constructor Summary
Constructors Constructor Description DsnWrite(ZosConnection connection)DsnWrite ConstructorDsnWrite(ZosConnection connection, ZosmfRequest request)Alternative DsnWrite constructor with ZoweRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Responsewrite(String dataSetName, String content)Replaces the content of an existing sequential data set with new content.Responsewrite(String dataSetName, String memberName, String content)Replaces the content of a member of a partitioned data set (PDS or PDSE) with new content.
-
-
-
Constructor Detail
-
DsnWrite
public DsnWrite(ZosConnection connection)
DsnWrite Constructor- Parameters:
connection- connection information, see ZOSConnection object
-
DsnWrite
public DsnWrite(ZosConnection connection, ZosmfRequest request)
Alternative DsnWrite 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
-
-
Method Detail
-
write
public Response write(String dataSetName, String memberName, String content) throws ZosmfRequestException
Replaces the content of a member of a partitioned data set (PDS or PDSE) with new content. A new dataset member will be created if the specified dataset member does not exist.- Parameters:
dataSetName- dataset name of where the member is located (e.g. 'DATASET.LIB')memberName- name of member to add new contentcontent- new content- Returns:
- http response object
- Throws:
ZosmfRequestException- request error state
-
write
public Response write(String dataSetName, String content) throws ZosmfRequestException
Replaces the content of an existing sequential data set with new content.- Parameters:
dataSetName- sequential dataset (e.g. 'DATASET.LIB')content- new content- Returns:
- http response object
- Throws:
ZosmfRequestException- request error state
-
-