com.aliyun.sdk.service.gpdb20160503.models.AllocateInstancePublicConnectionRequest Maven / Gradle / Ivy
// This file is auto-generated, don't edit it. Thanks.
package com.aliyun.sdk.service.gpdb20160503.models;
import com.aliyun.core.annotation.*;
import darabonba.core.RequestModel;
import darabonba.core.TeaModel;
import com.aliyun.sdk.gateway.pop.models.*;
/**
* {@link AllocateInstancePublicConnectionRequest} extends {@link RequestModel}
*
* AllocateInstancePublicConnectionRequest
*/
public class AllocateInstancePublicConnectionRequest extends Request {
@Query
@NameInMap("AddressType")
private String addressType;
@Query
@NameInMap("ConnectionStringPrefix")
@Validation(required = true)
private String connectionStringPrefix;
@Query
@NameInMap("DBInstanceId")
@Validation(required = true)
private String DBInstanceId;
@Query
@NameInMap("OwnerId")
private Long ownerId;
@Query
@NameInMap("Port")
@Validation(required = true)
private String port;
@Query
@NameInMap("ResourceOwnerAccount")
private String resourceOwnerAccount;
@Query
@NameInMap("ResourceOwnerId")
private Long resourceOwnerId;
private AllocateInstancePublicConnectionRequest(Builder builder) {
super(builder);
this.addressType = builder.addressType;
this.connectionStringPrefix = builder.connectionStringPrefix;
this.DBInstanceId = builder.DBInstanceId;
this.ownerId = builder.ownerId;
this.port = builder.port;
this.resourceOwnerAccount = builder.resourceOwnerAccount;
this.resourceOwnerId = builder.resourceOwnerId;
}
public static Builder builder() {
return new Builder();
}
public static AllocateInstancePublicConnectionRequest create() {
return builder().build();
}
@Override
public Builder toBuilder() {
return new Builder(this);
}
/**
* @return addressType
*/
public String getAddressType() {
return this.addressType;
}
/**
* @return connectionStringPrefix
*/
public String getConnectionStringPrefix() {
return this.connectionStringPrefix;
}
/**
* @return DBInstanceId
*/
public String getDBInstanceId() {
return this.DBInstanceId;
}
/**
* @return ownerId
*/
public Long getOwnerId() {
return this.ownerId;
}
/**
* @return port
*/
public String getPort() {
return this.port;
}
/**
* @return resourceOwnerAccount
*/
public String getResourceOwnerAccount() {
return this.resourceOwnerAccount;
}
/**
* @return resourceOwnerId
*/
public Long getResourceOwnerId() {
return this.resourceOwnerId;
}
public static final class Builder extends Request.Builder {
private String addressType;
private String connectionStringPrefix;
private String DBInstanceId;
private Long ownerId;
private String port;
private String resourceOwnerAccount;
private Long resourceOwnerId;
private Builder() {
super();
}
private Builder(AllocateInstancePublicConnectionRequest request) {
super(request);
this.addressType = request.addressType;
this.connectionStringPrefix = request.connectionStringPrefix;
this.DBInstanceId = request.DBInstanceId;
this.ownerId = request.ownerId;
this.port = request.port;
this.resourceOwnerAccount = request.resourceOwnerAccount;
this.resourceOwnerId = request.resourceOwnerId;
}
/**
* The network type of the endpoint. Valid values:
*
*
* * **primary**: primary endpoint
* * **cluster**: instance endpoint. This value is supported only for an instance that contains multiple coordinator nodes.
*
* > The default value is primary.
*/
public Builder addressType(String addressType) {
this.putQueryParameter("AddressType", addressType);
this.addressType = addressType;
return this;
}
/**
* The prefix of the endpoint.
*
*
* Specify a prefix for the endpoint. Example: `gp-bp12ga6v69h86****`. In this example, the endpoint is `gp-bp12ga6v69h86****.gpdb.rds.aliyuncs.com`.
*/
public Builder connectionStringPrefix(String connectionStringPrefix) {
this.putQueryParameter("ConnectionStringPrefix", connectionStringPrefix);
this.connectionStringPrefix = connectionStringPrefix;
return this;
}
/**
* The ID of the instance.
*
*
* > You can call the [DescribeDBInstances](~~86911~~) operation to query the details of all AnalyticDB for PostgreSQL instances in a specific region, including instance IDs.
*/
public Builder DBInstanceId(String DBInstanceId) {
this.putQueryParameter("DBInstanceId", DBInstanceId);
this.DBInstanceId = DBInstanceId;
return this;
}
/**
* OwnerId.
*/
public Builder ownerId(Long ownerId) {
this.putQueryParameter("OwnerId", ownerId);
this.ownerId = ownerId;
return this;
}
/**
* The port number. Example: 5432.
*/
public Builder port(String port) {
this.putQueryParameter("Port", port);
this.port = port;
return this;
}
/**
* ResourceOwnerAccount.
*/
public Builder resourceOwnerAccount(String resourceOwnerAccount) {
this.putQueryParameter("ResourceOwnerAccount", resourceOwnerAccount);
this.resourceOwnerAccount = resourceOwnerAccount;
return this;
}
/**
* ResourceOwnerId.
*/
public Builder resourceOwnerId(Long resourceOwnerId) {
this.putQueryParameter("ResourceOwnerId", resourceOwnerId);
this.resourceOwnerId = resourceOwnerId;
return this;
}
@Override
public AllocateInstancePublicConnectionRequest build() {
return new AllocateInstancePublicConnectionRequest(this);
}
}
}