com.aliyun.sdk.service.ens20171110.models.DistApplicationDataRequest Maven / Gradle / Ivy
Show all versions of alibabacloud-ens20171110 Show documentation
// This file is auto-generated, don't edit it. Thanks.
package com.aliyun.sdk.service.ens20171110.models;
import com.aliyun.sdk.gateway.pop.*;
import darabonba.core.*;
import darabonba.core.async.*;
import darabonba.core.sync.*;
import darabonba.core.client.*;
import darabonba.core.RequestModel;
import darabonba.core.TeaModel;
import com.aliyun.sdk.gateway.pop.models.*;
/**
*
* {@link DistApplicationDataRequest} extends {@link RequestModel}
*
* DistApplicationDataRequest
*/
public class DistApplicationDataRequest extends Request {
@com.aliyun.core.annotation.Query
@com.aliyun.core.annotation.NameInMap("AppId")
@com.aliyun.core.annotation.Validation(required = true)
private String appId;
@com.aliyun.core.annotation.Query
@com.aliyun.core.annotation.NameInMap("Data")
@com.aliyun.core.annotation.Validation(required = true)
private String data;
@com.aliyun.core.annotation.Query
@com.aliyun.core.annotation.NameInMap("DistStrategy")
private String distStrategy;
private DistApplicationDataRequest(Builder builder) {
super(builder);
this.appId = builder.appId;
this.data = builder.data;
this.distStrategy = builder.distStrategy;
}
public static Builder builder() {
return new Builder();
}
public static DistApplicationDataRequest create() {
return builder().build();
}
@Override
public Builder toBuilder() {
return new Builder(this);
}
/**
* @return appId
*/
public String getAppId() {
return this.appId;
}
/**
* @return data
*/
public String getData() {
return this.data;
}
/**
* @return distStrategy
*/
public String getDistStrategy() {
return this.distStrategy;
}
public static final class Builder extends Request.Builder {
private String appId;
private String data;
private String distStrategy;
private Builder() {
super();
}
private Builder(DistApplicationDataRequest request) {
super(request);
this.appId = request.appId;
this.data = request.data;
this.distStrategy = request.distStrategy;
}
/**
* The ID of the application. To obtain the application ID, call the ListApplications operation.
* This parameter is required.
*
* example:
* e76f8985-7965-41fc-925b-9648bb6bf650
*/
public Builder appId(String appId) {
this.putQueryParameter("AppId", appId);
this.appId = appId;
return this;
}
/**
* The list of data files that you want to distribute. The value must be a JSON string.
* This parameter is required.
*
* example:
* [{"name":"app01", "version":"1.0", "destPath":"/root/installed", "decompress":true, "targetDirName":"target01", "fileMode":755, "timeout":1000 }, { "name":"app02", "version":"1.1", "destPath":"/tmp/test.txt", "decompress":false }]
*/
public Builder data(String data) {
this.putQueryParameter("Data", data);
this.data = data;
return this;
}
/**
* The canary release policy. The value must be a JSON string. You can specify multiple distribution policies. By default, all data files are distributed.
*
* example:
* {"name":"ScheduleToAllByMatchExpressions","parameters":{"match_expressions":[{"key":"region_id","operator":"In","values":["cn-wuhan-telecom_unicom_cmcc-2"]}]}}
*/
public Builder distStrategy(String distStrategy) {
this.putQueryParameter("DistStrategy", distStrategy);
this.distStrategy = distStrategy;
return this;
}
@Override
public DistApplicationDataRequest build() {
return new DistApplicationDataRequest(this);
}
}
}