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

software.amazon.awssdk.services.snowball.model.ClusterMetadata Maven / Gradle / Ivy

Go to download

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

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.snowball.model;

import java.io.Serializable;
import java.time.Instant;
import java.util.Arrays;
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 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.LocationTrait;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 * 

* Contains metadata about a specific cluster. *

*/ @Generated("software.amazon.awssdk:codegen") public final class ClusterMetadata implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField CLUSTER_ID_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ClusterId").getter(getter(ClusterMetadata::clusterId)).setter(setter(Builder::clusterId)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ClusterId").build()).build(); private static final SdkField DESCRIPTION_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("Description").getter(getter(ClusterMetadata::description)).setter(setter(Builder::description)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Description").build()).build(); private static final SdkField KMS_KEY_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("KmsKeyARN").getter(getter(ClusterMetadata::kmsKeyARN)).setter(setter(Builder::kmsKeyARN)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("KmsKeyARN").build()).build(); private static final SdkField ROLE_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("RoleARN").getter(getter(ClusterMetadata::roleARN)).setter(setter(Builder::roleARN)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("RoleARN").build()).build(); private static final SdkField CLUSTER_STATE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ClusterState").getter(getter(ClusterMetadata::clusterStateAsString)) .setter(setter(Builder::clusterState)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ClusterState").build()).build(); private static final SdkField JOB_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("JobType").getter(getter(ClusterMetadata::jobTypeAsString)).setter(setter(Builder::jobType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("JobType").build()).build(); private static final SdkField SNOWBALL_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("SnowballType").getter(getter(ClusterMetadata::snowballTypeAsString)) .setter(setter(Builder::snowballType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("SnowballType").build()).build(); private static final SdkField CREATION_DATE_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("CreationDate").getter(getter(ClusterMetadata::creationDate)).setter(setter(Builder::creationDate)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CreationDate").build()).build(); private static final SdkField RESOURCES_FIELD = SdkField. builder(MarshallingType.SDK_POJO) .memberName("Resources").getter(getter(ClusterMetadata::resources)).setter(setter(Builder::resources)) .constructor(JobResource::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Resources").build()).build(); private static final SdkField ADDRESS_ID_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("AddressId").getter(getter(ClusterMetadata::addressId)).setter(setter(Builder::addressId)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AddressId").build()).build(); private static final SdkField SHIPPING_OPTION_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ShippingOption").getter(getter(ClusterMetadata::shippingOptionAsString)) .setter(setter(Builder::shippingOption)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ShippingOption").build()).build(); private static final SdkField NOTIFICATION_FIELD = SdkField. builder(MarshallingType.SDK_POJO) .memberName("Notification").getter(getter(ClusterMetadata::notification)).setter(setter(Builder::notification)) .constructor(Notification::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Notification").build()).build(); private static final SdkField FORWARDING_ADDRESS_ID_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ForwardingAddressId").getter(getter(ClusterMetadata::forwardingAddressId)) .setter(setter(Builder::forwardingAddressId)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ForwardingAddressId").build()) .build(); private static final SdkField TAX_DOCUMENTS_FIELD = SdkField. builder(MarshallingType.SDK_POJO) .memberName("TaxDocuments").getter(getter(ClusterMetadata::taxDocuments)).setter(setter(Builder::taxDocuments)) .constructor(TaxDocuments::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TaxDocuments").build()).build(); private static final SdkField ON_DEVICE_SERVICE_CONFIGURATION_FIELD = SdkField . builder(MarshallingType.SDK_POJO) .memberName("OnDeviceServiceConfiguration") .getter(getter(ClusterMetadata::onDeviceServiceConfiguration)) .setter(setter(Builder::onDeviceServiceConfiguration)) .constructor(OnDeviceServiceConfiguration::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("OnDeviceServiceConfiguration") .build()).build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(CLUSTER_ID_FIELD, DESCRIPTION_FIELD, KMS_KEY_ARN_FIELD, ROLE_ARN_FIELD, CLUSTER_STATE_FIELD, JOB_TYPE_FIELD, SNOWBALL_TYPE_FIELD, CREATION_DATE_FIELD, RESOURCES_FIELD, ADDRESS_ID_FIELD, SHIPPING_OPTION_FIELD, NOTIFICATION_FIELD, FORWARDING_ADDRESS_ID_FIELD, TAX_DOCUMENTS_FIELD, ON_DEVICE_SERVICE_CONFIGURATION_FIELD)); private static final long serialVersionUID = 1L; private final String clusterId; private final String description; private final String kmsKeyARN; private final String roleARN; private final String clusterState; private final String jobType; private final String snowballType; private final Instant creationDate; private final JobResource resources; private final String addressId; private final String shippingOption; private final Notification notification; private final String forwardingAddressId; private final TaxDocuments taxDocuments; private final OnDeviceServiceConfiguration onDeviceServiceConfiguration; private ClusterMetadata(BuilderImpl builder) { this.clusterId = builder.clusterId; this.description = builder.description; this.kmsKeyARN = builder.kmsKeyARN; this.roleARN = builder.roleARN; this.clusterState = builder.clusterState; this.jobType = builder.jobType; this.snowballType = builder.snowballType; this.creationDate = builder.creationDate; this.resources = builder.resources; this.addressId = builder.addressId; this.shippingOption = builder.shippingOption; this.notification = builder.notification; this.forwardingAddressId = builder.forwardingAddressId; this.taxDocuments = builder.taxDocuments; this.onDeviceServiceConfiguration = builder.onDeviceServiceConfiguration; } /** *

* The automatically generated ID for a cluster. *

* * @return The automatically generated ID for a cluster. */ public final String clusterId() { return clusterId; } /** *

* The optional description of the cluster. *

* * @return The optional description of the cluster. */ public final String description() { return description; } /** *

* The KmsKeyARN Amazon Resource Name (ARN) associated with this cluster. This ARN was created using * the CreateKey API action in * Key Management Service (KMS. *

* * @return The KmsKeyARN Amazon Resource Name (ARN) associated with this cluster. This ARN was created * using the CreateKey * API action in Key Management Service (KMS. */ public final String kmsKeyARN() { return kmsKeyARN; } /** *

* The role ARN associated with this cluster. This ARN was created using the CreateRole API action in * Identity and Access Management (IAM). *

* * @return The role ARN associated with this cluster. This ARN was created using the CreateRole API action * in Identity and Access Management (IAM). */ public final String roleARN() { return roleARN; } /** *

* The current status of the cluster. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #clusterState} will * return {@link ClusterState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #clusterStateAsString}. *

* * @return The current status of the cluster. * @see ClusterState */ public final ClusterState clusterState() { return ClusterState.fromValue(clusterState); } /** *

* The current status of the cluster. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #clusterState} will * return {@link ClusterState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #clusterStateAsString}. *

* * @return The current status of the cluster. * @see ClusterState */ public final String clusterStateAsString() { return clusterState; } /** *

* The type of job for this cluster. Currently, the only job type supported for clusters is LOCAL_USE. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #jobType} will * return {@link JobType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #jobTypeAsString}. *

* * @return The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. * @see JobType */ public final JobType jobType() { return JobType.fromValue(jobType); } /** *

* The type of job for this cluster. Currently, the only job type supported for clusters is LOCAL_USE. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #jobType} will * return {@link JobType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #jobTypeAsString}. *

* * @return The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. * @see JobType */ public final String jobTypeAsString() { return jobType; } /** *

* The type of Snowcone device to use for this cluster. *

* *

* For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device type. *

*
*

* If the service returns an enum value that is not available in the current SDK version, {@link #snowballType} will * return {@link SnowballType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #snowballTypeAsString}. *

* * @return The type of Snowcone device to use for this cluster.

*

* For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device * type. *

* @see SnowballType */ public final SnowballType snowballType() { return SnowballType.fromValue(snowballType); } /** *

* The type of Snowcone device to use for this cluster. *

* *

* For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device type. *

*
*

* If the service returns an enum value that is not available in the current SDK version, {@link #snowballType} will * return {@link SnowballType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #snowballTypeAsString}. *

* * @return The type of Snowcone device to use for this cluster.

*

* For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device * type. *

* @see SnowballType */ public final String snowballTypeAsString() { return snowballType; } /** *

* The creation date for this cluster. *

* * @return The creation date for this cluster. */ public final Instant creationDate() { return creationDate; } /** *

* The arrays of JobResource objects that can include updated S3Resource objects or * LambdaResource objects. *

* * @return The arrays of JobResource objects that can include updated S3Resource objects or * LambdaResource objects. */ public final JobResource resources() { return resources; } /** *

* The automatically generated ID for a specific address. *

* * @return The automatically generated ID for a specific address. */ public final String addressId() { return addressId; } /** *

* The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each device, * rather it represents how quickly each device moves to its destination while in transit. Regional shipping speeds * are as follows: *

*
    *
  • *

    * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in about a * day. *

    *
  • *
  • *

    * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express are * delivered in about a day. In addition, most countries in the EU have access to standard shipping, which typically * takes less than a week, one way. *

    *
  • *
  • *

    * In India, Snow devices are delivered in one to seven days. *

    *
  • *
  • *

    * In the US, you have access to one-day shipping and two-day shipping. *

    *
  • *
*

* If the service returns an enum value that is not available in the current SDK version, {@link #shippingOption} * will return {@link ShippingOption#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #shippingOptionAsString}. *

* * @return The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each * device, rather it represents how quickly each device moves to its destination while in transit. Regional * shipping speeds are as follows:

*
    *
  • *

    * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in * about a day. *

    *
  • *
  • *

    * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express * are delivered in about a day. In addition, most countries in the EU have access to standard shipping, * which typically takes less than a week, one way. *

    *
  • *
  • *

    * In India, Snow devices are delivered in one to seven days. *

    *
  • *
  • *

    * In the US, you have access to one-day shipping and two-day shipping. *

    *
  • * @see ShippingOption */ public final ShippingOption shippingOption() { return ShippingOption.fromValue(shippingOption); } /** *

    * The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each device, * rather it represents how quickly each device moves to its destination while in transit. Regional shipping speeds * are as follows: *

    *
      *
    • *

      * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in about a * day. *

      *
    • *
    • *

      * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express are * delivered in about a day. In addition, most countries in the EU have access to standard shipping, which typically * takes less than a week, one way. *

      *
    • *
    • *

      * In India, Snow devices are delivered in one to seven days. *

      *
    • *
    • *

      * In the US, you have access to one-day shipping and two-day shipping. *

      *
    • *
    *

    * If the service returns an enum value that is not available in the current SDK version, {@link #shippingOption} * will return {@link ShippingOption#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #shippingOptionAsString}. *

    * * @return The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each * device, rather it represents how quickly each device moves to its destination while in transit. Regional * shipping speeds are as follows:

    *
      *
    • *

      * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in * about a day. *

      *
    • *
    • *

      * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express * are delivered in about a day. In addition, most countries in the EU have access to standard shipping, * which typically takes less than a week, one way. *

      *
    • *
    • *

      * In India, Snow devices are delivered in one to seven days. *

      *
    • *
    • *

      * In the US, you have access to one-day shipping and two-day shipping. *

      *
    • * @see ShippingOption */ public final String shippingOptionAsString() { return shippingOption; } /** *

      * The Amazon Simple Notification Service (Amazon SNS) notification settings for this cluster. *

      * * @return The Amazon Simple Notification Service (Amazon SNS) notification settings for this cluster. */ public final Notification notification() { return notification; } /** *

      * The ID of the address that you want a cluster shipped to, after it will be shipped to its primary address. This * field is not supported in most regions. *

      * * @return The ID of the address that you want a cluster shipped to, after it will be shipped to its primary * address. This field is not supported in most regions. */ public final String forwardingAddressId() { return forwardingAddressId; } /** *

      * The tax documents required in your Amazon Web Services Region. *

      * * @return The tax documents required in your Amazon Web Services Region. */ public final TaxDocuments taxDocuments() { return taxDocuments; } /** *

      * Represents metadata and configuration settings for services on an Amazon Web Services Snow Family device. *

      * * @return Represents metadata and configuration settings for services on an Amazon Web Services Snow Family device. */ public final OnDeviceServiceConfiguration onDeviceServiceConfiguration() { return onDeviceServiceConfiguration; } @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(clusterId()); hashCode = 31 * hashCode + Objects.hashCode(description()); hashCode = 31 * hashCode + Objects.hashCode(kmsKeyARN()); hashCode = 31 * hashCode + Objects.hashCode(roleARN()); hashCode = 31 * hashCode + Objects.hashCode(clusterStateAsString()); hashCode = 31 * hashCode + Objects.hashCode(jobTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(snowballTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(creationDate()); hashCode = 31 * hashCode + Objects.hashCode(resources()); hashCode = 31 * hashCode + Objects.hashCode(addressId()); hashCode = 31 * hashCode + Objects.hashCode(shippingOptionAsString()); hashCode = 31 * hashCode + Objects.hashCode(notification()); hashCode = 31 * hashCode + Objects.hashCode(forwardingAddressId()); hashCode = 31 * hashCode + Objects.hashCode(taxDocuments()); hashCode = 31 * hashCode + Objects.hashCode(onDeviceServiceConfiguration()); 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 ClusterMetadata)) { return false; } ClusterMetadata other = (ClusterMetadata) obj; return Objects.equals(clusterId(), other.clusterId()) && Objects.equals(description(), other.description()) && Objects.equals(kmsKeyARN(), other.kmsKeyARN()) && Objects.equals(roleARN(), other.roleARN()) && Objects.equals(clusterStateAsString(), other.clusterStateAsString()) && Objects.equals(jobTypeAsString(), other.jobTypeAsString()) && Objects.equals(snowballTypeAsString(), other.snowballTypeAsString()) && Objects.equals(creationDate(), other.creationDate()) && Objects.equals(resources(), other.resources()) && Objects.equals(addressId(), other.addressId()) && Objects.equals(shippingOptionAsString(), other.shippingOptionAsString()) && Objects.equals(notification(), other.notification()) && Objects.equals(forwardingAddressId(), other.forwardingAddressId()) && Objects.equals(taxDocuments(), other.taxDocuments()) && Objects.equals(onDeviceServiceConfiguration(), other.onDeviceServiceConfiguration()); } /** * 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("ClusterMetadata").add("ClusterId", clusterId()).add("Description", description()) .add("KmsKeyARN", kmsKeyARN()).add("RoleARN", roleARN()).add("ClusterState", clusterStateAsString()) .add("JobType", jobTypeAsString()).add("SnowballType", snowballTypeAsString()) .add("CreationDate", creationDate()).add("Resources", resources()).add("AddressId", addressId()) .add("ShippingOption", shippingOptionAsString()).add("Notification", notification()) .add("ForwardingAddressId", forwardingAddressId()).add("TaxDocuments", taxDocuments()) .add("OnDeviceServiceConfiguration", onDeviceServiceConfiguration()).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "ClusterId": return Optional.ofNullable(clazz.cast(clusterId())); case "Description": return Optional.ofNullable(clazz.cast(description())); case "KmsKeyARN": return Optional.ofNullable(clazz.cast(kmsKeyARN())); case "RoleARN": return Optional.ofNullable(clazz.cast(roleARN())); case "ClusterState": return Optional.ofNullable(clazz.cast(clusterStateAsString())); case "JobType": return Optional.ofNullable(clazz.cast(jobTypeAsString())); case "SnowballType": return Optional.ofNullable(clazz.cast(snowballTypeAsString())); case "CreationDate": return Optional.ofNullable(clazz.cast(creationDate())); case "Resources": return Optional.ofNullable(clazz.cast(resources())); case "AddressId": return Optional.ofNullable(clazz.cast(addressId())); case "ShippingOption": return Optional.ofNullable(clazz.cast(shippingOptionAsString())); case "Notification": return Optional.ofNullable(clazz.cast(notification())); case "ForwardingAddressId": return Optional.ofNullable(clazz.cast(forwardingAddressId())); case "TaxDocuments": return Optional.ofNullable(clazz.cast(taxDocuments())); case "OnDeviceServiceConfiguration": return Optional.ofNullable(clazz.cast(onDeviceServiceConfiguration())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((ClusterMetadata) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** *

      * The automatically generated ID for a cluster. *

      * * @param clusterId * The automatically generated ID for a cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder clusterId(String clusterId); /** *

      * The optional description of the cluster. *

      * * @param description * The optional description of the cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder description(String description); /** *

      * The KmsKeyARN Amazon Resource Name (ARN) associated with this cluster. This ARN was created * using the CreateKey API * action in Key Management Service (KMS. *

      * * @param kmsKeyARN * The KmsKeyARN Amazon Resource Name (ARN) associated with this cluster. This ARN was * created using the CreateKey API action * in Key Management Service (KMS. * @return Returns a reference to this object so that method calls can be chained together. */ Builder kmsKeyARN(String kmsKeyARN); /** *

      * The role ARN associated with this cluster. This ARN was created using the CreateRole API action in * Identity and Access Management (IAM). *

      * * @param roleARN * The role ARN associated with this cluster. This ARN was created using the CreateRole API * action in Identity and Access Management (IAM). * @return Returns a reference to this object so that method calls can be chained together. */ Builder roleARN(String roleARN); /** *

      * The current status of the cluster. *

      * * @param clusterState * The current status of the cluster. * @see ClusterState * @return Returns a reference to this object so that method calls can be chained together. * @see ClusterState */ Builder clusterState(String clusterState); /** *

      * The current status of the cluster. *

      * * @param clusterState * The current status of the cluster. * @see ClusterState * @return Returns a reference to this object so that method calls can be chained together. * @see ClusterState */ Builder clusterState(ClusterState clusterState); /** *

      * The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. *

      * * @param jobType * The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. * @see JobType * @return Returns a reference to this object so that method calls can be chained together. * @see JobType */ Builder jobType(String jobType); /** *

      * The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. *

      * * @param jobType * The type of job for this cluster. Currently, the only job type supported for clusters is * LOCAL_USE. * @see JobType * @return Returns a reference to this object so that method calls can be chained together. * @see JobType */ Builder jobType(JobType jobType); /** *

      * The type of Snowcone device to use for this cluster. *

      * *

      * For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device type. *

      *
      * * @param snowballType * The type of Snowcone device to use for this cluster.

      *

      * For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device * type. *

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

      * The type of Snowcone device to use for this cluster. *

      * *

      * For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device type. *

      *
      * * @param snowballType * The type of Snowcone device to use for this cluster.

      *

      * For cluster jobs, Amazon Web Services Snow Family currently supports only the EDGE device * type. *

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

      * The creation date for this cluster. *

      * * @param creationDate * The creation date for this cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder creationDate(Instant creationDate); /** *

      * The arrays of JobResource objects that can include updated S3Resource objects or * LambdaResource objects. *

      * * @param resources * The arrays of JobResource objects that can include updated S3Resource objects or * LambdaResource objects. * @return Returns a reference to this object so that method calls can be chained together. */ Builder resources(JobResource resources); /** *

      * The arrays of JobResource objects that can include updated S3Resource objects or * LambdaResource objects. *

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

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

      * The automatically generated ID for a specific address. *

      * * @param addressId * The automatically generated ID for a specific address. * @return Returns a reference to this object so that method calls can be chained together. */ Builder addressId(String addressId); /** *

      * The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each device, * rather it represents how quickly each device moves to its destination while in transit. Regional shipping * speeds are as follows: *

      *
        *
      • *

        * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in about * a day. *

        *
      • *
      • *

        * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express are * delivered in about a day. In addition, most countries in the EU have access to standard shipping, which * typically takes less than a week, one way. *

        *
      • *
      • *

        * In India, Snow devices are delivered in one to seven days. *

        *
      • *
      • *

        * In the US, you have access to one-day shipping and two-day shipping. *

        *
      • *
      * * @param shippingOption * The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each * device, rather it represents how quickly each device moves to its destination while in transit. * Regional shipping speeds are as follows:

      *
        *
      • *

        * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in * about a day. *

        *
      • *
      • *

        * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped * express are delivered in about a day. In addition, most countries in the EU have access to standard * shipping, which typically takes less than a week, one way. *

        *
      • *
      • *

        * In India, Snow devices are delivered in one to seven days. *

        *
      • *
      • *

        * In the US, you have access to one-day shipping and two-day shipping. *

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

        * The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each device, * rather it represents how quickly each device moves to its destination while in transit. Regional shipping * speeds are as follows: *

        *
          *
        • *

          * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in about * a day. *

          *
        • *
        • *

          * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped express are * delivered in about a day. In addition, most countries in the EU have access to standard shipping, which * typically takes less than a week, one way. *

          *
        • *
        • *

          * In India, Snow devices are delivered in one to seven days. *

          *
        • *
        • *

          * In the US, you have access to one-day shipping and two-day shipping. *

          *
        • *
        * * @param shippingOption * The shipping speed for each node in this cluster. This speed doesn't dictate how soon you'll get each * device, rather it represents how quickly each device moves to its destination while in transit. * Regional shipping speeds are as follows:

        *
          *
        • *

          * In Australia, you have access to express shipping. Typically, devices shipped express are delivered in * about a day. *

          *
        • *
        • *

          * In the European Union (EU), you have access to express shipping. Typically, Snow devices shipped * express are delivered in about a day. In addition, most countries in the EU have access to standard * shipping, which typically takes less than a week, one way. *

          *
        • *
        • *

          * In India, Snow devices are delivered in one to seven days. *

          *
        • *
        • *

          * In the US, you have access to one-day shipping and two-day shipping. *

          *
        • * @see ShippingOption * @return Returns a reference to this object so that method calls can be chained together. * @see ShippingOption */ Builder shippingOption(ShippingOption shippingOption); /** *

          * The Amazon Simple Notification Service (Amazon SNS) notification settings for this cluster. *

          * * @param notification * The Amazon Simple Notification Service (Amazon SNS) notification settings for this cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder notification(Notification notification); /** *

          * The Amazon Simple Notification Service (Amazon SNS) notification settings for this cluster. *

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

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

          * The ID of the address that you want a cluster shipped to, after it will be shipped to its primary address. * This field is not supported in most regions. *

          * * @param forwardingAddressId * The ID of the address that you want a cluster shipped to, after it will be shipped to its primary * address. This field is not supported in most regions. * @return Returns a reference to this object so that method calls can be chained together. */ Builder forwardingAddressId(String forwardingAddressId); /** *

          * The tax documents required in your Amazon Web Services Region. *

          * * @param taxDocuments * The tax documents required in your Amazon Web Services Region. * @return Returns a reference to this object so that method calls can be chained together. */ Builder taxDocuments(TaxDocuments taxDocuments); /** *

          * The tax documents required in your Amazon Web Services Region. *

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

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

          * Represents metadata and configuration settings for services on an Amazon Web Services Snow Family device. *

          * * @param onDeviceServiceConfiguration * Represents metadata and configuration settings for services on an Amazon Web Services Snow Family * device. * @return Returns a reference to this object so that method calls can be chained together. */ Builder onDeviceServiceConfiguration(OnDeviceServiceConfiguration onDeviceServiceConfiguration); /** *

          * Represents metadata and configuration settings for services on an Amazon Web Services Snow Family device. *

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

          * When the {@link Consumer} completes, {@link OnDeviceServiceConfiguration.Builder#build()} is called * immediately and its result is passed to {@link #onDeviceServiceConfiguration(OnDeviceServiceConfiguration)}. * * @param onDeviceServiceConfiguration * a consumer that will call methods on {@link OnDeviceServiceConfiguration.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #onDeviceServiceConfiguration(OnDeviceServiceConfiguration) */ default Builder onDeviceServiceConfiguration(Consumer onDeviceServiceConfiguration) { return onDeviceServiceConfiguration(OnDeviceServiceConfiguration.builder() .applyMutation(onDeviceServiceConfiguration).build()); } } static final class BuilderImpl implements Builder { private String clusterId; private String description; private String kmsKeyARN; private String roleARN; private String clusterState; private String jobType; private String snowballType; private Instant creationDate; private JobResource resources; private String addressId; private String shippingOption; private Notification notification; private String forwardingAddressId; private TaxDocuments taxDocuments; private OnDeviceServiceConfiguration onDeviceServiceConfiguration; private BuilderImpl() { } private BuilderImpl(ClusterMetadata model) { clusterId(model.clusterId); description(model.description); kmsKeyARN(model.kmsKeyARN); roleARN(model.roleARN); clusterState(model.clusterState); jobType(model.jobType); snowballType(model.snowballType); creationDate(model.creationDate); resources(model.resources); addressId(model.addressId); shippingOption(model.shippingOption); notification(model.notification); forwardingAddressId(model.forwardingAddressId); taxDocuments(model.taxDocuments); onDeviceServiceConfiguration(model.onDeviceServiceConfiguration); } public final String getClusterId() { return clusterId; } public final void setClusterId(String clusterId) { this.clusterId = clusterId; } @Override public final Builder clusterId(String clusterId) { this.clusterId = clusterId; return this; } public final String getDescription() { return description; } public final void setDescription(String description) { this.description = description; } @Override public final Builder description(String description) { this.description = description; return this; } public final String getKmsKeyARN() { return kmsKeyARN; } public final void setKmsKeyARN(String kmsKeyARN) { this.kmsKeyARN = kmsKeyARN; } @Override public final Builder kmsKeyARN(String kmsKeyARN) { this.kmsKeyARN = kmsKeyARN; return this; } public final String getRoleARN() { return roleARN; } public final void setRoleARN(String roleARN) { this.roleARN = roleARN; } @Override public final Builder roleARN(String roleARN) { this.roleARN = roleARN; return this; } public final String getClusterState() { return clusterState; } public final void setClusterState(String clusterState) { this.clusterState = clusterState; } @Override public final Builder clusterState(String clusterState) { this.clusterState = clusterState; return this; } @Override public final Builder clusterState(ClusterState clusterState) { this.clusterState(clusterState == null ? null : clusterState.toString()); return this; } public final String getJobType() { return jobType; } public final void setJobType(String jobType) { this.jobType = jobType; } @Override public final Builder jobType(String jobType) { this.jobType = jobType; return this; } @Override public final Builder jobType(JobType jobType) { this.jobType(jobType == null ? null : jobType.toString()); return this; } public final String getSnowballType() { return snowballType; } public final void setSnowballType(String snowballType) { this.snowballType = snowballType; } @Override public final Builder snowballType(String snowballType) { this.snowballType = snowballType; return this; } @Override public final Builder snowballType(SnowballType snowballType) { this.snowballType(snowballType == null ? null : snowballType.toString()); return this; } public final Instant getCreationDate() { return creationDate; } public final void setCreationDate(Instant creationDate) { this.creationDate = creationDate; } @Override public final Builder creationDate(Instant creationDate) { this.creationDate = creationDate; return this; } public final JobResource.Builder getResources() { return resources != null ? resources.toBuilder() : null; } public final void setResources(JobResource.BuilderImpl resources) { this.resources = resources != null ? resources.build() : null; } @Override public final Builder resources(JobResource resources) { this.resources = resources; return this; } public final String getAddressId() { return addressId; } public final void setAddressId(String addressId) { this.addressId = addressId; } @Override public final Builder addressId(String addressId) { this.addressId = addressId; return this; } public final String getShippingOption() { return shippingOption; } public final void setShippingOption(String shippingOption) { this.shippingOption = shippingOption; } @Override public final Builder shippingOption(String shippingOption) { this.shippingOption = shippingOption; return this; } @Override public final Builder shippingOption(ShippingOption shippingOption) { this.shippingOption(shippingOption == null ? null : shippingOption.toString()); return this; } public final Notification.Builder getNotification() { return notification != null ? notification.toBuilder() : null; } public final void setNotification(Notification.BuilderImpl notification) { this.notification = notification != null ? notification.build() : null; } @Override public final Builder notification(Notification notification) { this.notification = notification; return this; } public final String getForwardingAddressId() { return forwardingAddressId; } public final void setForwardingAddressId(String forwardingAddressId) { this.forwardingAddressId = forwardingAddressId; } @Override public final Builder forwardingAddressId(String forwardingAddressId) { this.forwardingAddressId = forwardingAddressId; return this; } public final TaxDocuments.Builder getTaxDocuments() { return taxDocuments != null ? taxDocuments.toBuilder() : null; } public final void setTaxDocuments(TaxDocuments.BuilderImpl taxDocuments) { this.taxDocuments = taxDocuments != null ? taxDocuments.build() : null; } @Override public final Builder taxDocuments(TaxDocuments taxDocuments) { this.taxDocuments = taxDocuments; return this; } public final OnDeviceServiceConfiguration.Builder getOnDeviceServiceConfiguration() { return onDeviceServiceConfiguration != null ? onDeviceServiceConfiguration.toBuilder() : null; } public final void setOnDeviceServiceConfiguration(OnDeviceServiceConfiguration.BuilderImpl onDeviceServiceConfiguration) { this.onDeviceServiceConfiguration = onDeviceServiceConfiguration != null ? onDeviceServiceConfiguration.build() : null; } @Override public final Builder onDeviceServiceConfiguration(OnDeviceServiceConfiguration onDeviceServiceConfiguration) { this.onDeviceServiceConfiguration = onDeviceServiceConfiguration; return this; } @Override public ClusterMetadata build() { return new ClusterMetadata(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy