All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.amazon.awssdk.services.kafka.model.ClusterOperationInfo Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Kafka module holds the client classes that are used for communicating with Kafka.

There is a newer version: 2.29.15
Show newest version
/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */

package software.amazon.awssdk.services.kafka.model;

import java.io.Serializable;
import java.time.Instant;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.stream.Collectors;
import java.util.stream.Stream;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.ListTrait;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.core.traits.TimestampFormatTrait;
import software.amazon.awssdk.core.util.DefaultSdkAutoConstructList;
import software.amazon.awssdk.core.util.SdkAutoConstructList;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 *
 * 

* Returns information about a cluster operation. *

* */ @Generated("software.amazon.awssdk:codegen") public final class ClusterOperationInfo implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField CLIENT_REQUEST_ID_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ClientRequestId").getter(getter(ClusterOperationInfo::clientRequestId)) .setter(setter(Builder::clientRequestId)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("clientRequestId").build()).build(); private static final SdkField CLUSTER_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ClusterArn").getter(getter(ClusterOperationInfo::clusterArn)).setter(setter(Builder::clusterArn)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("clusterArn").build()).build(); private static final SdkField CREATION_TIME_FIELD = SdkField . builder(MarshallingType.INSTANT) .memberName("CreationTime") .getter(getter(ClusterOperationInfo::creationTime)) .setter(setter(Builder::creationTime)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("creationTime").build(), TimestampFormatTrait.create(TimestampFormatTrait.Format.ISO_8601)).build(); private static final SdkField END_TIME_FIELD = SdkField . builder(MarshallingType.INSTANT) .memberName("EndTime") .getter(getter(ClusterOperationInfo::endTime)) .setter(setter(Builder::endTime)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("endTime").build(), TimestampFormatTrait.create(TimestampFormatTrait.Format.ISO_8601)).build(); private static final SdkField ERROR_INFO_FIELD = SdkField. builder(MarshallingType.SDK_POJO) .memberName("ErrorInfo").getter(getter(ClusterOperationInfo::errorInfo)).setter(setter(Builder::errorInfo)) .constructor(ErrorInfo::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("errorInfo").build()).build(); private static final SdkField OPERATION_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("OperationArn").getter(getter(ClusterOperationInfo::operationArn)).setter(setter(Builder::operationArn)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("operationArn").build()).build(); private static final SdkField OPERATION_STATE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("OperationState").getter(getter(ClusterOperationInfo::operationState)) .setter(setter(Builder::operationState)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("operationState").build()).build(); private static final SdkField> OPERATION_STEPS_FIELD = SdkField .> builder(MarshallingType.LIST) .memberName("OperationSteps") .getter(getter(ClusterOperationInfo::operationSteps)) .setter(setter(Builder::operationSteps)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("operationSteps").build(), ListTrait .builder() .memberLocationName(null) .memberFieldInfo( SdkField. builder(MarshallingType.SDK_POJO) .constructor(ClusterOperationStep::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD) .locationName("member").build()).build()).build()).build(); private static final SdkField OPERATION_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("OperationType").getter(getter(ClusterOperationInfo::operationType)) .setter(setter(Builder::operationType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("operationType").build()).build(); private static final SdkField SOURCE_CLUSTER_INFO_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("SourceClusterInfo") .getter(getter(ClusterOperationInfo::sourceClusterInfo)).setter(setter(Builder::sourceClusterInfo)) .constructor(MutableClusterInfo::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("sourceClusterInfo").build()).build(); private static final SdkField TARGET_CLUSTER_INFO_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("TargetClusterInfo") .getter(getter(ClusterOperationInfo::targetClusterInfo)).setter(setter(Builder::targetClusterInfo)) .constructor(MutableClusterInfo::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("targetClusterInfo").build()).build(); private static final SdkField VPC_CONNECTION_INFO_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("VpcConnectionInfo") .getter(getter(ClusterOperationInfo::vpcConnectionInfo)).setter(setter(Builder::vpcConnectionInfo)) .constructor(VpcConnectionInfo::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("vpcConnectionInfo").build()).build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(CLIENT_REQUEST_ID_FIELD, CLUSTER_ARN_FIELD, CREATION_TIME_FIELD, END_TIME_FIELD, ERROR_INFO_FIELD, OPERATION_ARN_FIELD, OPERATION_STATE_FIELD, OPERATION_STEPS_FIELD, OPERATION_TYPE_FIELD, SOURCE_CLUSTER_INFO_FIELD, TARGET_CLUSTER_INFO_FIELD, VPC_CONNECTION_INFO_FIELD)); private static final long serialVersionUID = 1L; private final String clientRequestId; private final String clusterArn; private final Instant creationTime; private final Instant endTime; private final ErrorInfo errorInfo; private final String operationArn; private final String operationState; private final List operationSteps; private final String operationType; private final MutableClusterInfo sourceClusterInfo; private final MutableClusterInfo targetClusterInfo; private final VpcConnectionInfo vpcConnectionInfo; private ClusterOperationInfo(BuilderImpl builder) { this.clientRequestId = builder.clientRequestId; this.clusterArn = builder.clusterArn; this.creationTime = builder.creationTime; this.endTime = builder.endTime; this.errorInfo = builder.errorInfo; this.operationArn = builder.operationArn; this.operationState = builder.operationState; this.operationSteps = builder.operationSteps; this.operationType = builder.operationType; this.sourceClusterInfo = builder.sourceClusterInfo; this.targetClusterInfo = builder.targetClusterInfo; this.vpcConnectionInfo = builder.vpcConnectionInfo; } /** * *

* The ID of the API request that triggered this operation. *

* * @return

* The ID of the API request that triggered this operation. *

*/ public final String clientRequestId() { return clientRequestId; } /** * *

* ARN of the cluster. *

* * @return

* ARN of the cluster. *

*/ public final String clusterArn() { return clusterArn; } /** * *

* The time that the operation was created. *

* * @return

* The time that the operation was created. *

*/ public final Instant creationTime() { return creationTime; } /** * *

* The time at which the operation finished. *

* * @return

* The time at which the operation finished. *

*/ public final Instant endTime() { return endTime; } /** * *

* Describes the error if the operation fails. *

* * @return

* Describes the error if the operation fails. *

*/ public final ErrorInfo errorInfo() { return errorInfo; } /** * *

* ARN of the cluster operation. *

* * @return

* ARN of the cluster operation. *

*/ public final String operationArn() { return operationArn; } /** * *

* State of the cluster operation. *

* * @return

* State of the cluster operation. *

*/ public final String operationState() { return operationState; } /** * For responses, this returns true if the service returned a value for the OperationSteps property. This DOES NOT * check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the property). * This is useful because the SDK will never return a null collection or map, but you may need to differentiate * between the service returning nothing (or null) and the service returning an empty collection or map. For * requests, this returns true if a value for the property was specified in the request builder, and false if a * value was not specified. */ public final boolean hasOperationSteps() { return operationSteps != null && !(operationSteps instanceof SdkAutoConstructList); } /** * *

* Steps completed during the operation. *

* *

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasOperationSteps} method. *

* * @return

* Steps completed during the operation. *

*/ public final List operationSteps() { return operationSteps; } /** * *

* Type of the cluster operation. *

* * @return

* Type of the cluster operation. *

*/ public final String operationType() { return operationType; } /** * *

* Information about cluster attributes before a cluster is updated. *

* * @return

* Information about cluster attributes before a cluster is updated. *

*/ public final MutableClusterInfo sourceClusterInfo() { return sourceClusterInfo; } /** * *

* Information about cluster attributes after a cluster is updated. *

* * @return

* Information about cluster attributes after a cluster is updated. *

*/ public final MutableClusterInfo targetClusterInfo() { return targetClusterInfo; } /** * *

* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *

* * @return

* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *

*/ public final VpcConnectionInfo vpcConnectionInfo() { return vpcConnectionInfo; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + Objects.hashCode(clientRequestId()); hashCode = 31 * hashCode + Objects.hashCode(clusterArn()); hashCode = 31 * hashCode + Objects.hashCode(creationTime()); hashCode = 31 * hashCode + Objects.hashCode(endTime()); hashCode = 31 * hashCode + Objects.hashCode(errorInfo()); hashCode = 31 * hashCode + Objects.hashCode(operationArn()); hashCode = 31 * hashCode + Objects.hashCode(operationState()); hashCode = 31 * hashCode + Objects.hashCode(hasOperationSteps() ? operationSteps() : null); hashCode = 31 * hashCode + Objects.hashCode(operationType()); hashCode = 31 * hashCode + Objects.hashCode(sourceClusterInfo()); hashCode = 31 * hashCode + Objects.hashCode(targetClusterInfo()); hashCode = 31 * hashCode + Objects.hashCode(vpcConnectionInfo()); return hashCode; } @Override public final boolean equals(Object obj) { return equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof ClusterOperationInfo)) { return false; } ClusterOperationInfo other = (ClusterOperationInfo) obj; return Objects.equals(clientRequestId(), other.clientRequestId()) && Objects.equals(clusterArn(), other.clusterArn()) && Objects.equals(creationTime(), other.creationTime()) && Objects.equals(endTime(), other.endTime()) && Objects.equals(errorInfo(), other.errorInfo()) && Objects.equals(operationArn(), other.operationArn()) && Objects.equals(operationState(), other.operationState()) && hasOperationSteps() == other.hasOperationSteps() && Objects.equals(operationSteps(), other.operationSteps()) && Objects.equals(operationType(), other.operationType()) && Objects.equals(sourceClusterInfo(), other.sourceClusterInfo()) && Objects.equals(targetClusterInfo(), other.targetClusterInfo()) && Objects.equals(vpcConnectionInfo(), other.vpcConnectionInfo()); } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. */ @Override public final String toString() { return ToString.builder("ClusterOperationInfo").add("ClientRequestId", clientRequestId()).add("ClusterArn", clusterArn()) .add("CreationTime", creationTime()).add("EndTime", endTime()).add("ErrorInfo", errorInfo()) .add("OperationArn", operationArn()).add("OperationState", operationState()) .add("OperationSteps", hasOperationSteps() ? operationSteps() : null).add("OperationType", operationType()) .add("SourceClusterInfo", sourceClusterInfo()).add("TargetClusterInfo", targetClusterInfo()) .add("VpcConnectionInfo", vpcConnectionInfo()).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "ClientRequestId": return Optional.ofNullable(clazz.cast(clientRequestId())); case "ClusterArn": return Optional.ofNullable(clazz.cast(clusterArn())); case "CreationTime": return Optional.ofNullable(clazz.cast(creationTime())); case "EndTime": return Optional.ofNullable(clazz.cast(endTime())); case "ErrorInfo": return Optional.ofNullable(clazz.cast(errorInfo())); case "OperationArn": return Optional.ofNullable(clazz.cast(operationArn())); case "OperationState": return Optional.ofNullable(clazz.cast(operationState())); case "OperationSteps": return Optional.ofNullable(clazz.cast(operationSteps())); case "OperationType": return Optional.ofNullable(clazz.cast(operationType())); case "SourceClusterInfo": return Optional.ofNullable(clazz.cast(sourceClusterInfo())); case "TargetClusterInfo": return Optional.ofNullable(clazz.cast(targetClusterInfo())); case "VpcConnectionInfo": return Optional.ofNullable(clazz.cast(vpcConnectionInfo())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((ClusterOperationInfo) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** * *

* The ID of the API request that triggered this operation. *

* * @param clientRequestId *

* The ID of the API request that triggered this operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder clientRequestId(String clientRequestId); /** * *

* ARN of the cluster. *

* * @param clusterArn *

* ARN of the cluster. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder clusterArn(String clusterArn); /** * *

* The time that the operation was created. *

* * @param creationTime *

* The time that the operation was created. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder creationTime(Instant creationTime); /** * *

* The time at which the operation finished. *

* * @param endTime *

* The time at which the operation finished. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder endTime(Instant endTime); /** * *

* Describes the error if the operation fails. *

* * @param errorInfo *

* Describes the error if the operation fails. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder errorInfo(ErrorInfo errorInfo); /** * *

* Describes the error if the operation fails. *

* * This is a convenience method that creates an instance of the {@link ErrorInfo.Builder} avoiding the need to * create one manually via {@link ErrorInfo#builder()}. * *

* When the {@link Consumer} completes, {@link ErrorInfo.Builder#build()} is called immediately and its result * is passed to {@link #errorInfo(ErrorInfo)}. * * @param errorInfo * a consumer that will call methods on {@link ErrorInfo.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #errorInfo(ErrorInfo) */ default Builder errorInfo(Consumer errorInfo) { return errorInfo(ErrorInfo.builder().applyMutation(errorInfo).build()); } /** * *

* ARN of the cluster operation. *

* * @param operationArn *

* ARN of the cluster operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder operationArn(String operationArn); /** * *

* State of the cluster operation. *

* * @param operationState *

* State of the cluster operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder operationState(String operationState); /** * *

* Steps completed during the operation. *

* * @param operationSteps *

* Steps completed during the operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder operationSteps(Collection operationSteps); /** * *

* Steps completed during the operation. *

* * @param operationSteps *

* Steps completed during the operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder operationSteps(ClusterOperationStep... operationSteps); /** * *

* Steps completed during the operation. *

* * This is a convenience method that creates an instance of the * {@link software.amazon.awssdk.services.kafka.model.ClusterOperationStep.Builder} avoiding the need to create * one manually via {@link software.amazon.awssdk.services.kafka.model.ClusterOperationStep#builder()}. * *

* When the {@link Consumer} completes, * {@link software.amazon.awssdk.services.kafka.model.ClusterOperationStep.Builder#build()} is called * immediately and its result is passed to {@link #operationSteps(List)}. * * @param operationSteps * a consumer that will call methods on * {@link software.amazon.awssdk.services.kafka.model.ClusterOperationStep.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #operationSteps(java.util.Collection) */ Builder operationSteps(Consumer... operationSteps); /** * *

* Type of the cluster operation. *

* * @param operationType *

* Type of the cluster operation. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder operationType(String operationType); /** * *

* Information about cluster attributes before a cluster is updated. *

* * @param sourceClusterInfo *

* Information about cluster attributes before a cluster is updated. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder sourceClusterInfo(MutableClusterInfo sourceClusterInfo); /** * *

* Information about cluster attributes before a cluster is updated. *

* * This is a convenience method that creates an instance of the {@link MutableClusterInfo.Builder} avoiding the * need to create one manually via {@link MutableClusterInfo#builder()}. * *

* When the {@link Consumer} completes, {@link MutableClusterInfo.Builder#build()} is called immediately and its * result is passed to {@link #sourceClusterInfo(MutableClusterInfo)}. * * @param sourceClusterInfo * a consumer that will call methods on {@link MutableClusterInfo.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #sourceClusterInfo(MutableClusterInfo) */ default Builder sourceClusterInfo(Consumer sourceClusterInfo) { return sourceClusterInfo(MutableClusterInfo.builder().applyMutation(sourceClusterInfo).build()); } /** * *

* Information about cluster attributes after a cluster is updated. *

* * @param targetClusterInfo *

* Information about cluster attributes after a cluster is updated. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder targetClusterInfo(MutableClusterInfo targetClusterInfo); /** * *

* Information about cluster attributes after a cluster is updated. *

* * This is a convenience method that creates an instance of the {@link MutableClusterInfo.Builder} avoiding the * need to create one manually via {@link MutableClusterInfo#builder()}. * *

* When the {@link Consumer} completes, {@link MutableClusterInfo.Builder#build()} is called immediately and its * result is passed to {@link #targetClusterInfo(MutableClusterInfo)}. * * @param targetClusterInfo * a consumer that will call methods on {@link MutableClusterInfo.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #targetClusterInfo(MutableClusterInfo) */ default Builder targetClusterInfo(Consumer targetClusterInfo) { return targetClusterInfo(MutableClusterInfo.builder().applyMutation(targetClusterInfo).build()); } /** * *

* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *

* * @param vpcConnectionInfo *

* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *

* @return Returns a reference to this object so that method calls can be chained together. */ Builder vpcConnectionInfo(VpcConnectionInfo vpcConnectionInfo); /** * *

* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *

* * This is a convenience method that creates an instance of the {@link VpcConnectionInfo.Builder} avoiding the * need to create one manually via {@link VpcConnectionInfo#builder()}. * *

* When the {@link Consumer} completes, {@link VpcConnectionInfo.Builder#build()} is called immediately and its * result is passed to {@link #vpcConnectionInfo(VpcConnectionInfo)}. * * @param vpcConnectionInfo * a consumer that will call methods on {@link VpcConnectionInfo.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #vpcConnectionInfo(VpcConnectionInfo) */ default Builder vpcConnectionInfo(Consumer vpcConnectionInfo) { return vpcConnectionInfo(VpcConnectionInfo.builder().applyMutation(vpcConnectionInfo).build()); } } static final class BuilderImpl implements Builder { private String clientRequestId; private String clusterArn; private Instant creationTime; private Instant endTime; private ErrorInfo errorInfo; private String operationArn; private String operationState; private List operationSteps = DefaultSdkAutoConstructList.getInstance(); private String operationType; private MutableClusterInfo sourceClusterInfo; private MutableClusterInfo targetClusterInfo; private VpcConnectionInfo vpcConnectionInfo; private BuilderImpl() { } private BuilderImpl(ClusterOperationInfo model) { clientRequestId(model.clientRequestId); clusterArn(model.clusterArn); creationTime(model.creationTime); endTime(model.endTime); errorInfo(model.errorInfo); operationArn(model.operationArn); operationState(model.operationState); operationSteps(model.operationSteps); operationType(model.operationType); sourceClusterInfo(model.sourceClusterInfo); targetClusterInfo(model.targetClusterInfo); vpcConnectionInfo(model.vpcConnectionInfo); } public final String getClientRequestId() { return clientRequestId; } public final void setClientRequestId(String clientRequestId) { this.clientRequestId = clientRequestId; } @Override public final Builder clientRequestId(String clientRequestId) { this.clientRequestId = clientRequestId; return this; } public final String getClusterArn() { return clusterArn; } public final void setClusterArn(String clusterArn) { this.clusterArn = clusterArn; } @Override public final Builder clusterArn(String clusterArn) { this.clusterArn = clusterArn; return this; } public final Instant getCreationTime() { return creationTime; } public final void setCreationTime(Instant creationTime) { this.creationTime = creationTime; } @Override public final Builder creationTime(Instant creationTime) { this.creationTime = creationTime; return this; } public final Instant getEndTime() { return endTime; } public final void setEndTime(Instant endTime) { this.endTime = endTime; } @Override public final Builder endTime(Instant endTime) { this.endTime = endTime; return this; } public final ErrorInfo.Builder getErrorInfo() { return errorInfo != null ? errorInfo.toBuilder() : null; } public final void setErrorInfo(ErrorInfo.BuilderImpl errorInfo) { this.errorInfo = errorInfo != null ? errorInfo.build() : null; } @Override public final Builder errorInfo(ErrorInfo errorInfo) { this.errorInfo = errorInfo; return this; } public final String getOperationArn() { return operationArn; } public final void setOperationArn(String operationArn) { this.operationArn = operationArn; } @Override public final Builder operationArn(String operationArn) { this.operationArn = operationArn; return this; } public final String getOperationState() { return operationState; } public final void setOperationState(String operationState) { this.operationState = operationState; } @Override public final Builder operationState(String operationState) { this.operationState = operationState; return this; } public final List getOperationSteps() { List result = ___listOfClusterOperationStepCopier.copyToBuilder(this.operationSteps); if (result instanceof SdkAutoConstructList) { return null; } return result; } public final void setOperationSteps(Collection operationSteps) { this.operationSteps = ___listOfClusterOperationStepCopier.copyFromBuilder(operationSteps); } @Override public final Builder operationSteps(Collection operationSteps) { this.operationSteps = ___listOfClusterOperationStepCopier.copy(operationSteps); return this; } @Override @SafeVarargs public final Builder operationSteps(ClusterOperationStep... operationSteps) { operationSteps(Arrays.asList(operationSteps)); return this; } @Override @SafeVarargs public final Builder operationSteps(Consumer... operationSteps) { operationSteps(Stream.of(operationSteps).map(c -> ClusterOperationStep.builder().applyMutation(c).build()) .collect(Collectors.toList())); return this; } public final String getOperationType() { return operationType; } public final void setOperationType(String operationType) { this.operationType = operationType; } @Override public final Builder operationType(String operationType) { this.operationType = operationType; return this; } public final MutableClusterInfo.Builder getSourceClusterInfo() { return sourceClusterInfo != null ? sourceClusterInfo.toBuilder() : null; } public final void setSourceClusterInfo(MutableClusterInfo.BuilderImpl sourceClusterInfo) { this.sourceClusterInfo = sourceClusterInfo != null ? sourceClusterInfo.build() : null; } @Override public final Builder sourceClusterInfo(MutableClusterInfo sourceClusterInfo) { this.sourceClusterInfo = sourceClusterInfo; return this; } public final MutableClusterInfo.Builder getTargetClusterInfo() { return targetClusterInfo != null ? targetClusterInfo.toBuilder() : null; } public final void setTargetClusterInfo(MutableClusterInfo.BuilderImpl targetClusterInfo) { this.targetClusterInfo = targetClusterInfo != null ? targetClusterInfo.build() : null; } @Override public final Builder targetClusterInfo(MutableClusterInfo targetClusterInfo) { this.targetClusterInfo = targetClusterInfo; return this; } public final VpcConnectionInfo.Builder getVpcConnectionInfo() { return vpcConnectionInfo != null ? vpcConnectionInfo.toBuilder() : null; } public final void setVpcConnectionInfo(VpcConnectionInfo.BuilderImpl vpcConnectionInfo) { this.vpcConnectionInfo = vpcConnectionInfo != null ? vpcConnectionInfo.build() : null; } @Override public final Builder vpcConnectionInfo(VpcConnectionInfo vpcConnectionInfo) { this.vpcConnectionInfo = vpcConnectionInfo; return this; } @Override public ClusterOperationInfo build() { return new ClusterOperationInfo(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy