kucoin-universal-sdk
Version:
Official KuCoin Universal SDK.
79 lines • 2.57 kB
JavaScript
;
// Code generated by Kucoin Universal SDK Generator; DO NOT EDIT.
Object.defineProperty(exports, "__esModule", { value: true });
exports.RemoveIsolatedMarginReqBuilder = exports.RemoveIsolatedMarginReq = void 0;
const class_transformer_1 = require("class-transformer");
class RemoveIsolatedMarginReq {
/**
* Private constructor, please use the corresponding static methods to construct the object.
*/
constructor() {
// @ts-ignore
this.symbol = null;
// @ts-ignore
this.withdrawAmount = null;
}
/**
* Creates a new instance of the `RemoveIsolatedMarginReq` class.
* The builder pattern allows step-by-step construction of a `RemoveIsolatedMarginReq` object.
*/
static builder() {
return new RemoveIsolatedMarginReqBuilder(new RemoveIsolatedMarginReq());
}
/**
* Creates a new instance of the `RemoveIsolatedMarginReq` class with the given data.
*/
static create(data) {
let obj = new RemoveIsolatedMarginReq();
obj.symbol = data.symbol;
obj.withdrawAmount = data.withdrawAmount;
return obj;
}
/**
* Convert the object to a JSON string.
*/
toJson() {
return JSON.stringify((0, class_transformer_1.instanceToPlain)(this));
}
/**
* Create an object from a JSON string.
*/
static fromJson(input) {
return this.fromObject(JSON.parse(input));
}
/**
* Create an object from Js Object.
*/
static fromObject(jsonObject) {
return (0, class_transformer_1.plainToClassFromExist)(new RemoveIsolatedMarginReq(), jsonObject);
}
}
exports.RemoveIsolatedMarginReq = RemoveIsolatedMarginReq;
class RemoveIsolatedMarginReqBuilder {
constructor(obj) {
this.obj = obj;
this.obj = obj;
}
/**
* Symbol of the contract, Please refer to [Get Symbol endpoint: symbol](https://www.kucoin.com/docs-new/api-3470220)
*/
setSymbol(value) {
this.obj.symbol = value;
return this;
}
/**
* The size of the position that can be deposited. If it is USDT-margin, it represents the amount of USDT. If it is coin-margin, this value represents the number of coins
*/
setWithdrawAmount(value) {
this.obj.withdrawAmount = value;
return this;
}
/**
* Get the final object.
*/
build() {
return this.obj;
}
}
exports.RemoveIsolatedMarginReqBuilder = RemoveIsolatedMarginReqBuilder;
//# sourceMappingURL=model_remove_isolated_margin_req.js.map