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

software.amazon.awssdk.services.sagemaker.model.CreateModelQualityJobDefinitionRequest Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon SageMaker module holds the client classes that are used for communicating with Amazon SageMaker Service

There is a newer version: 2.31.2
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.sagemaker.model;

import java.beans.Transient;
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.awscore.AwsRequestOverrideConfiguration;
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.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;

/**
 */
@Generated("software.amazon.awssdk:codegen")
public final class CreateModelQualityJobDefinitionRequest extends SageMakerRequest implements
        ToCopyableBuilder {
    private static final SdkField JOB_DEFINITION_NAME_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("JobDefinitionName").getter(getter(CreateModelQualityJobDefinitionRequest::jobDefinitionName))
            .setter(setter(Builder::jobDefinitionName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("JobDefinitionName").build()).build();

    private static final SdkField MODEL_QUALITY_BASELINE_CONFIG_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("ModelQualityBaselineConfig")
            .getter(getter(CreateModelQualityJobDefinitionRequest::modelQualityBaselineConfig))
            .setter(setter(Builder::modelQualityBaselineConfig))
            .constructor(ModelQualityBaselineConfig::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ModelQualityBaselineConfig").build())
            .build();

    private static final SdkField MODEL_QUALITY_APP_SPECIFICATION_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("ModelQualityAppSpecification")
            .getter(getter(CreateModelQualityJobDefinitionRequest::modelQualityAppSpecification))
            .setter(setter(Builder::modelQualityAppSpecification))
            .constructor(ModelQualityAppSpecification::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ModelQualityAppSpecification")
                    .build()).build();

    private static final SdkField MODEL_QUALITY_JOB_INPUT_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("ModelQualityJobInput")
            .getter(getter(CreateModelQualityJobDefinitionRequest::modelQualityJobInput))
            .setter(setter(Builder::modelQualityJobInput)).constructor(ModelQualityJobInput::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ModelQualityJobInput").build())
            .build();

    private static final SdkField MODEL_QUALITY_JOB_OUTPUT_CONFIG_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("ModelQualityJobOutputConfig")
            .getter(getter(CreateModelQualityJobDefinitionRequest::modelQualityJobOutputConfig))
            .setter(setter(Builder::modelQualityJobOutputConfig))
            .constructor(MonitoringOutputConfig::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ModelQualityJobOutputConfig")
                    .build()).build();

    private static final SdkField JOB_RESOURCES_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("JobResources")
            .getter(getter(CreateModelQualityJobDefinitionRequest::jobResources)).setter(setter(Builder::jobResources))
            .constructor(MonitoringResources::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("JobResources").build()).build();

    private static final SdkField NETWORK_CONFIG_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("NetworkConfig")
            .getter(getter(CreateModelQualityJobDefinitionRequest::networkConfig)).setter(setter(Builder::networkConfig))
            .constructor(MonitoringNetworkConfig::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("NetworkConfig").build()).build();

    private static final SdkField ROLE_ARN_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("RoleArn").getter(getter(CreateModelQualityJobDefinitionRequest::roleArn))
            .setter(setter(Builder::roleArn))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("RoleArn").build()).build();

    private static final SdkField STOPPING_CONDITION_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("StoppingCondition")
            .getter(getter(CreateModelQualityJobDefinitionRequest::stoppingCondition)).setter(setter(Builder::stoppingCondition))
            .constructor(MonitoringStoppingCondition::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("StoppingCondition").build()).build();

    private static final SdkField> TAGS_FIELD = SdkField
            .> builder(MarshallingType.LIST)
            .memberName("Tags")
            .getter(getter(CreateModelQualityJobDefinitionRequest::tags))
            .setter(setter(Builder::tags))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Tags").build(),
                    ListTrait
                            .builder()
                            .memberLocationName(null)
                            .memberFieldInfo(
                                    SdkField. builder(MarshallingType.SDK_POJO)
                                            .constructor(Tag::builder)
                                            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD)
                                                    .locationName("member").build()).build()).build()).build();

    private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(JOB_DEFINITION_NAME_FIELD,
            MODEL_QUALITY_BASELINE_CONFIG_FIELD, MODEL_QUALITY_APP_SPECIFICATION_FIELD, MODEL_QUALITY_JOB_INPUT_FIELD,
            MODEL_QUALITY_JOB_OUTPUT_CONFIG_FIELD, JOB_RESOURCES_FIELD, NETWORK_CONFIG_FIELD, ROLE_ARN_FIELD,
            STOPPING_CONDITION_FIELD, TAGS_FIELD));

    private final String jobDefinitionName;

    private final ModelQualityBaselineConfig modelQualityBaselineConfig;

    private final ModelQualityAppSpecification modelQualityAppSpecification;

    private final ModelQualityJobInput modelQualityJobInput;

    private final MonitoringOutputConfig modelQualityJobOutputConfig;

    private final MonitoringResources jobResources;

    private final MonitoringNetworkConfig networkConfig;

    private final String roleArn;

    private final MonitoringStoppingCondition stoppingCondition;

    private final List tags;

    private CreateModelQualityJobDefinitionRequest(BuilderImpl builder) {
        super(builder);
        this.jobDefinitionName = builder.jobDefinitionName;
        this.modelQualityBaselineConfig = builder.modelQualityBaselineConfig;
        this.modelQualityAppSpecification = builder.modelQualityAppSpecification;
        this.modelQualityJobInput = builder.modelQualityJobInput;
        this.modelQualityJobOutputConfig = builder.modelQualityJobOutputConfig;
        this.jobResources = builder.jobResources;
        this.networkConfig = builder.networkConfig;
        this.roleArn = builder.roleArn;
        this.stoppingCondition = builder.stoppingCondition;
        this.tags = builder.tags;
    }

    /**
     * 

* The name of the monitoring job definition. *

* * @return The name of the monitoring job definition. */ public final String jobDefinitionName() { return jobDefinitionName; } /** *

* Specifies the constraints and baselines for the monitoring job. *

* * @return Specifies the constraints and baselines for the monitoring job. */ public final ModelQualityBaselineConfig modelQualityBaselineConfig() { return modelQualityBaselineConfig; } /** *

* The container that runs the monitoring job. *

* * @return The container that runs the monitoring job. */ public final ModelQualityAppSpecification modelQualityAppSpecification() { return modelQualityAppSpecification; } /** *

* A list of the inputs that are monitored. Currently endpoints are supported. *

* * @return A list of the inputs that are monitored. Currently endpoints are supported. */ public final ModelQualityJobInput modelQualityJobInput() { return modelQualityJobInput; } /** * Returns the value of the ModelQualityJobOutputConfig property for this object. * * @return The value of the ModelQualityJobOutputConfig property for this object. */ public final MonitoringOutputConfig modelQualityJobOutputConfig() { return modelQualityJobOutputConfig; } /** * Returns the value of the JobResources property for this object. * * @return The value of the JobResources property for this object. */ public final MonitoringResources jobResources() { return jobResources; } /** *

* Specifies the network configuration for the monitoring job. *

* * @return Specifies the network configuration for the monitoring job. */ public final MonitoringNetworkConfig networkConfig() { return networkConfig; } /** *

* The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker can assume to perform tasks on your behalf. *

* * @return The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker can assume to perform tasks on your * behalf. */ public final String roleArn() { return roleArn; } /** * Returns the value of the StoppingCondition property for this object. * * @return The value of the StoppingCondition property for this object. */ public final MonitoringStoppingCondition stoppingCondition() { return stoppingCondition; } /** * For responses, this returns true if the service returned a value for the Tags 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 hasTags() { return tags != null && !(tags instanceof SdkAutoConstructList); } /** *

* (Optional) An array of key-value pairs. For more information, see Using * Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User Guide. *

*

* 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 #hasTags} method. *

* * @return (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User Guide. */ public final List tags() { return tags; } @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 + super.hashCode(); hashCode = 31 * hashCode + Objects.hashCode(jobDefinitionName()); hashCode = 31 * hashCode + Objects.hashCode(modelQualityBaselineConfig()); hashCode = 31 * hashCode + Objects.hashCode(modelQualityAppSpecification()); hashCode = 31 * hashCode + Objects.hashCode(modelQualityJobInput()); hashCode = 31 * hashCode + Objects.hashCode(modelQualityJobOutputConfig()); hashCode = 31 * hashCode + Objects.hashCode(jobResources()); hashCode = 31 * hashCode + Objects.hashCode(networkConfig()); hashCode = 31 * hashCode + Objects.hashCode(roleArn()); hashCode = 31 * hashCode + Objects.hashCode(stoppingCondition()); hashCode = 31 * hashCode + Objects.hashCode(hasTags() ? tags() : null); return hashCode; } @Override public final boolean equals(Object obj) { return super.equals(obj) && equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof CreateModelQualityJobDefinitionRequest)) { return false; } CreateModelQualityJobDefinitionRequest other = (CreateModelQualityJobDefinitionRequest) obj; return Objects.equals(jobDefinitionName(), other.jobDefinitionName()) && Objects.equals(modelQualityBaselineConfig(), other.modelQualityBaselineConfig()) && Objects.equals(modelQualityAppSpecification(), other.modelQualityAppSpecification()) && Objects.equals(modelQualityJobInput(), other.modelQualityJobInput()) && Objects.equals(modelQualityJobOutputConfig(), other.modelQualityJobOutputConfig()) && Objects.equals(jobResources(), other.jobResources()) && Objects.equals(networkConfig(), other.networkConfig()) && Objects.equals(roleArn(), other.roleArn()) && Objects.equals(stoppingCondition(), other.stoppingCondition()) && hasTags() == other.hasTags() && Objects.equals(tags(), other.tags()); } /** * 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("CreateModelQualityJobDefinitionRequest").add("JobDefinitionName", jobDefinitionName()) .add("ModelQualityBaselineConfig", modelQualityBaselineConfig()) .add("ModelQualityAppSpecification", modelQualityAppSpecification()) .add("ModelQualityJobInput", modelQualityJobInput()) .add("ModelQualityJobOutputConfig", modelQualityJobOutputConfig()).add("JobResources", jobResources()) .add("NetworkConfig", networkConfig()).add("RoleArn", roleArn()).add("StoppingCondition", stoppingCondition()) .add("Tags", hasTags() ? tags() : null).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "JobDefinitionName": return Optional.ofNullable(clazz.cast(jobDefinitionName())); case "ModelQualityBaselineConfig": return Optional.ofNullable(clazz.cast(modelQualityBaselineConfig())); case "ModelQualityAppSpecification": return Optional.ofNullable(clazz.cast(modelQualityAppSpecification())); case "ModelQualityJobInput": return Optional.ofNullable(clazz.cast(modelQualityJobInput())); case "ModelQualityJobOutputConfig": return Optional.ofNullable(clazz.cast(modelQualityJobOutputConfig())); case "JobResources": return Optional.ofNullable(clazz.cast(jobResources())); case "NetworkConfig": return Optional.ofNullable(clazz.cast(networkConfig())); case "RoleArn": return Optional.ofNullable(clazz.cast(roleArn())); case "StoppingCondition": return Optional.ofNullable(clazz.cast(stoppingCondition())); case "Tags": return Optional.ofNullable(clazz.cast(tags())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((CreateModelQualityJobDefinitionRequest) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SageMakerRequest.Builder, SdkPojo, CopyableBuilder { /** *

* The name of the monitoring job definition. *

* * @param jobDefinitionName * The name of the monitoring job definition. * @return Returns a reference to this object so that method calls can be chained together. */ Builder jobDefinitionName(String jobDefinitionName); /** *

* Specifies the constraints and baselines for the monitoring job. *

* * @param modelQualityBaselineConfig * Specifies the constraints and baselines for the monitoring job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder modelQualityBaselineConfig(ModelQualityBaselineConfig modelQualityBaselineConfig); /** *

* Specifies the constraints and baselines for the monitoring job. *

* This is a convenience that creates an instance of the {@link ModelQualityBaselineConfig.Builder} avoiding the * need to create one manually via {@link ModelQualityBaselineConfig#builder()}. * * When the {@link Consumer} completes, {@link ModelQualityBaselineConfig.Builder#build()} is called immediately * and its result is passed to {@link #modelQualityBaselineConfig(ModelQualityBaselineConfig)}. * * @param modelQualityBaselineConfig * a consumer that will call methods on {@link ModelQualityBaselineConfig.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #modelQualityBaselineConfig(ModelQualityBaselineConfig) */ default Builder modelQualityBaselineConfig(Consumer modelQualityBaselineConfig) { return modelQualityBaselineConfig(ModelQualityBaselineConfig.builder().applyMutation(modelQualityBaselineConfig) .build()); } /** *

* The container that runs the monitoring job. *

* * @param modelQualityAppSpecification * The container that runs the monitoring job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder modelQualityAppSpecification(ModelQualityAppSpecification modelQualityAppSpecification); /** *

* The container that runs the monitoring job. *

* This is a convenience that creates an instance of the {@link ModelQualityAppSpecification.Builder} avoiding * the need to create one manually via {@link ModelQualityAppSpecification#builder()}. * * When the {@link Consumer} completes, {@link ModelQualityAppSpecification.Builder#build()} is called * immediately and its result is passed to {@link #modelQualityAppSpecification(ModelQualityAppSpecification)}. * * @param modelQualityAppSpecification * a consumer that will call methods on {@link ModelQualityAppSpecification.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #modelQualityAppSpecification(ModelQualityAppSpecification) */ default Builder modelQualityAppSpecification(Consumer modelQualityAppSpecification) { return modelQualityAppSpecification(ModelQualityAppSpecification.builder() .applyMutation(modelQualityAppSpecification).build()); } /** *

* A list of the inputs that are monitored. Currently endpoints are supported. *

* * @param modelQualityJobInput * A list of the inputs that are monitored. Currently endpoints are supported. * @return Returns a reference to this object so that method calls can be chained together. */ Builder modelQualityJobInput(ModelQualityJobInput modelQualityJobInput); /** *

* A list of the inputs that are monitored. Currently endpoints are supported. *

* This is a convenience that creates an instance of the {@link ModelQualityJobInput.Builder} avoiding the need * to create one manually via {@link ModelQualityJobInput#builder()}. * * When the {@link Consumer} completes, {@link ModelQualityJobInput.Builder#build()} is called immediately and * its result is passed to {@link #modelQualityJobInput(ModelQualityJobInput)}. * * @param modelQualityJobInput * a consumer that will call methods on {@link ModelQualityJobInput.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #modelQualityJobInput(ModelQualityJobInput) */ default Builder modelQualityJobInput(Consumer modelQualityJobInput) { return modelQualityJobInput(ModelQualityJobInput.builder().applyMutation(modelQualityJobInput).build()); } /** * Sets the value of the ModelQualityJobOutputConfig property for this object. * * @param modelQualityJobOutputConfig * The new value for the ModelQualityJobOutputConfig property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder modelQualityJobOutputConfig(MonitoringOutputConfig modelQualityJobOutputConfig); /** * Sets the value of the ModelQualityJobOutputConfig property for this object. * * This is a convenience that creates an instance of the {@link MonitoringOutputConfig.Builder} avoiding the * need to create one manually via {@link MonitoringOutputConfig#builder()}. * * When the {@link Consumer} completes, {@link MonitoringOutputConfig.Builder#build()} is called immediately and * its result is passed to {@link #modelQualityJobOutputConfig(MonitoringOutputConfig)}. * * @param modelQualityJobOutputConfig * a consumer that will call methods on {@link MonitoringOutputConfig.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #modelQualityJobOutputConfig(MonitoringOutputConfig) */ default Builder modelQualityJobOutputConfig(Consumer modelQualityJobOutputConfig) { return modelQualityJobOutputConfig(MonitoringOutputConfig.builder().applyMutation(modelQualityJobOutputConfig) .build()); } /** * Sets the value of the JobResources property for this object. * * @param jobResources * The new value for the JobResources property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder jobResources(MonitoringResources jobResources); /** * Sets the value of the JobResources property for this object. * * This is a convenience that creates an instance of the {@link MonitoringResources.Builder} avoiding the need * to create one manually via {@link MonitoringResources#builder()}. * * When the {@link Consumer} completes, {@link MonitoringResources.Builder#build()} is called immediately and * its result is passed to {@link #jobResources(MonitoringResources)}. * * @param jobResources * a consumer that will call methods on {@link MonitoringResources.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #jobResources(MonitoringResources) */ default Builder jobResources(Consumer jobResources) { return jobResources(MonitoringResources.builder().applyMutation(jobResources).build()); } /** *

* Specifies the network configuration for the monitoring job. *

* * @param networkConfig * Specifies the network configuration for the monitoring job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder networkConfig(MonitoringNetworkConfig networkConfig); /** *

* Specifies the network configuration for the monitoring job. *

* This is a convenience that creates an instance of the {@link MonitoringNetworkConfig.Builder} avoiding the * need to create one manually via {@link MonitoringNetworkConfig#builder()}. * * When the {@link Consumer} completes, {@link MonitoringNetworkConfig.Builder#build()} is called immediately * and its result is passed to {@link #networkConfig(MonitoringNetworkConfig)}. * * @param networkConfig * a consumer that will call methods on {@link MonitoringNetworkConfig.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #networkConfig(MonitoringNetworkConfig) */ default Builder networkConfig(Consumer networkConfig) { return networkConfig(MonitoringNetworkConfig.builder().applyMutation(networkConfig).build()); } /** *

* The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker can assume to perform tasks on your * behalf. *

* * @param roleArn * The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker can assume to perform tasks on * your behalf. * @return Returns a reference to this object so that method calls can be chained together. */ Builder roleArn(String roleArn); /** * Sets the value of the StoppingCondition property for this object. * * @param stoppingCondition * The new value for the StoppingCondition property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder stoppingCondition(MonitoringStoppingCondition stoppingCondition); /** * Sets the value of the StoppingCondition property for this object. * * This is a convenience that creates an instance of the {@link MonitoringStoppingCondition.Builder} avoiding * the need to create one manually via {@link MonitoringStoppingCondition#builder()}. * * When the {@link Consumer} completes, {@link MonitoringStoppingCondition.Builder#build()} is called * immediately and its result is passed to {@link #stoppingCondition(MonitoringStoppingCondition)}. * * @param stoppingCondition * a consumer that will call methods on {@link MonitoringStoppingCondition.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #stoppingCondition(MonitoringStoppingCondition) */ default Builder stoppingCondition(Consumer stoppingCondition) { return stoppingCondition(MonitoringStoppingCondition.builder().applyMutation(stoppingCondition).build()); } /** *

* (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User Guide. *

* * @param tags * (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User * Guide. * @return Returns a reference to this object so that method calls can be chained together. */ Builder tags(Collection tags); /** *

* (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User Guide. *

* * @param tags * (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User * Guide. * @return Returns a reference to this object so that method calls can be chained together. */ Builder tags(Tag... tags); /** *

* (Optional) An array of key-value pairs. For more information, see Using Cost Allocation Tags in the Amazon Web Services Billing and Cost Management User Guide. *

* This is a convenience that creates an instance of the {@link List.Builder} avoiding the need to create * one manually via {@link List#builder()}. * * When the {@link Consumer} completes, {@link List.Builder#build()} is called immediately and its result * is passed to {@link #tags(List)}. * * @param tags * a consumer that will call methods on {@link List.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #tags(List) */ Builder tags(Consumer... tags); @Override Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration); @Override Builder overrideConfiguration(Consumer builderConsumer); } static final class BuilderImpl extends SageMakerRequest.BuilderImpl implements Builder { private String jobDefinitionName; private ModelQualityBaselineConfig modelQualityBaselineConfig; private ModelQualityAppSpecification modelQualityAppSpecification; private ModelQualityJobInput modelQualityJobInput; private MonitoringOutputConfig modelQualityJobOutputConfig; private MonitoringResources jobResources; private MonitoringNetworkConfig networkConfig; private String roleArn; private MonitoringStoppingCondition stoppingCondition; private List tags = DefaultSdkAutoConstructList.getInstance(); private BuilderImpl() { } private BuilderImpl(CreateModelQualityJobDefinitionRequest model) { super(model); jobDefinitionName(model.jobDefinitionName); modelQualityBaselineConfig(model.modelQualityBaselineConfig); modelQualityAppSpecification(model.modelQualityAppSpecification); modelQualityJobInput(model.modelQualityJobInput); modelQualityJobOutputConfig(model.modelQualityJobOutputConfig); jobResources(model.jobResources); networkConfig(model.networkConfig); roleArn(model.roleArn); stoppingCondition(model.stoppingCondition); tags(model.tags); } public final String getJobDefinitionName() { return jobDefinitionName; } public final void setJobDefinitionName(String jobDefinitionName) { this.jobDefinitionName = jobDefinitionName; } @Override @Transient public final Builder jobDefinitionName(String jobDefinitionName) { this.jobDefinitionName = jobDefinitionName; return this; } public final ModelQualityBaselineConfig.Builder getModelQualityBaselineConfig() { return modelQualityBaselineConfig != null ? modelQualityBaselineConfig.toBuilder() : null; } public final void setModelQualityBaselineConfig(ModelQualityBaselineConfig.BuilderImpl modelQualityBaselineConfig) { this.modelQualityBaselineConfig = modelQualityBaselineConfig != null ? modelQualityBaselineConfig.build() : null; } @Override @Transient public final Builder modelQualityBaselineConfig(ModelQualityBaselineConfig modelQualityBaselineConfig) { this.modelQualityBaselineConfig = modelQualityBaselineConfig; return this; } public final ModelQualityAppSpecification.Builder getModelQualityAppSpecification() { return modelQualityAppSpecification != null ? modelQualityAppSpecification.toBuilder() : null; } public final void setModelQualityAppSpecification(ModelQualityAppSpecification.BuilderImpl modelQualityAppSpecification) { this.modelQualityAppSpecification = modelQualityAppSpecification != null ? modelQualityAppSpecification.build() : null; } @Override @Transient public final Builder modelQualityAppSpecification(ModelQualityAppSpecification modelQualityAppSpecification) { this.modelQualityAppSpecification = modelQualityAppSpecification; return this; } public final ModelQualityJobInput.Builder getModelQualityJobInput() { return modelQualityJobInput != null ? modelQualityJobInput.toBuilder() : null; } public final void setModelQualityJobInput(ModelQualityJobInput.BuilderImpl modelQualityJobInput) { this.modelQualityJobInput = modelQualityJobInput != null ? modelQualityJobInput.build() : null; } @Override @Transient public final Builder modelQualityJobInput(ModelQualityJobInput modelQualityJobInput) { this.modelQualityJobInput = modelQualityJobInput; return this; } public final MonitoringOutputConfig.Builder getModelQualityJobOutputConfig() { return modelQualityJobOutputConfig != null ? modelQualityJobOutputConfig.toBuilder() : null; } public final void setModelQualityJobOutputConfig(MonitoringOutputConfig.BuilderImpl modelQualityJobOutputConfig) { this.modelQualityJobOutputConfig = modelQualityJobOutputConfig != null ? modelQualityJobOutputConfig.build() : null; } @Override @Transient public final Builder modelQualityJobOutputConfig(MonitoringOutputConfig modelQualityJobOutputConfig) { this.modelQualityJobOutputConfig = modelQualityJobOutputConfig; return this; } public final MonitoringResources.Builder getJobResources() { return jobResources != null ? jobResources.toBuilder() : null; } public final void setJobResources(MonitoringResources.BuilderImpl jobResources) { this.jobResources = jobResources != null ? jobResources.build() : null; } @Override @Transient public final Builder jobResources(MonitoringResources jobResources) { this.jobResources = jobResources; return this; } public final MonitoringNetworkConfig.Builder getNetworkConfig() { return networkConfig != null ? networkConfig.toBuilder() : null; } public final void setNetworkConfig(MonitoringNetworkConfig.BuilderImpl networkConfig) { this.networkConfig = networkConfig != null ? networkConfig.build() : null; } @Override @Transient public final Builder networkConfig(MonitoringNetworkConfig networkConfig) { this.networkConfig = networkConfig; return this; } public final String getRoleArn() { return roleArn; } public final void setRoleArn(String roleArn) { this.roleArn = roleArn; } @Override @Transient public final Builder roleArn(String roleArn) { this.roleArn = roleArn; return this; } public final MonitoringStoppingCondition.Builder getStoppingCondition() { return stoppingCondition != null ? stoppingCondition.toBuilder() : null; } public final void setStoppingCondition(MonitoringStoppingCondition.BuilderImpl stoppingCondition) { this.stoppingCondition = stoppingCondition != null ? stoppingCondition.build() : null; } @Override @Transient public final Builder stoppingCondition(MonitoringStoppingCondition stoppingCondition) { this.stoppingCondition = stoppingCondition; return this; } public final List getTags() { List result = TagListCopier.copyToBuilder(this.tags); if (result instanceof SdkAutoConstructList) { return null; } return result; } public final void setTags(Collection tags) { this.tags = TagListCopier.copyFromBuilder(tags); } @Override @Transient public final Builder tags(Collection tags) { this.tags = TagListCopier.copy(tags); return this; } @Override @Transient @SafeVarargs public final Builder tags(Tag... tags) { tags(Arrays.asList(tags)); return this; } @Override @Transient @SafeVarargs public final Builder tags(Consumer... tags) { tags(Stream.of(tags).map(c -> Tag.builder().applyMutation(c).build()).collect(Collectors.toList())); return this; } @Override public Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) { super.overrideConfiguration(overrideConfiguration); return this; } @Override public Builder overrideConfiguration(Consumer builderConsumer) { super.overrideConfiguration(builderConsumer); return this; } @Override public CreateModelQualityJobDefinitionRequest build() { return new CreateModelQualityJobDefinitionRequest(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy