Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* 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.elasticsearch.model;
import java.io.Serializable;
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;
/**
*
* The configuration of an Elasticsearch domain.
*
*/
@Generated("software.amazon.awssdk:codegen")
public final class ElasticsearchDomainConfig implements SdkPojo, Serializable,
ToCopyableBuilder {
private static final SdkField ELASTICSEARCH_VERSION_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::elasticsearchVersion)).setter(setter(Builder::elasticsearchVersion))
.constructor(ElasticsearchVersionStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ElasticsearchVersion").build())
.build();
private static final SdkField ELASTICSEARCH_CLUSTER_CONFIG_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::elasticsearchClusterConfig))
.setter(setter(Builder::elasticsearchClusterConfig))
.constructor(ElasticsearchClusterConfigStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ElasticsearchClusterConfig").build())
.build();
private static final SdkField EBS_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::ebsOptions))
.setter(setter(Builder::ebsOptions)).constructor(EBSOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("EBSOptions").build()).build();
private static final SdkField ACCESS_POLICIES_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::accessPolicies))
.setter(setter(Builder::accessPolicies)).constructor(AccessPoliciesStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AccessPolicies").build()).build();
private static final SdkField SNAPSHOT_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::snapshotOptions))
.setter(setter(Builder::snapshotOptions)).constructor(SnapshotOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("SnapshotOptions").build()).build();
private static final SdkField VPC_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::vpcOptions))
.setter(setter(Builder::vpcOptions)).constructor(VPCDerivedInfoStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("VPCOptions").build()).build();
private static final SdkField COGNITO_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::cognitoOptions))
.setter(setter(Builder::cognitoOptions)).constructor(CognitoOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CognitoOptions").build()).build();
private static final SdkField ENCRYPTION_AT_REST_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::encryptionAtRestOptions)).setter(setter(Builder::encryptionAtRestOptions))
.constructor(EncryptionAtRestOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("EncryptionAtRestOptions").build())
.build();
private static final SdkField NODE_TO_NODE_ENCRYPTION_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::nodeToNodeEncryptionOptions))
.setter(setter(Builder::nodeToNodeEncryptionOptions))
.constructor(NodeToNodeEncryptionOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("NodeToNodeEncryptionOptions")
.build()).build();
private static final SdkField ADVANCED_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO).getter(getter(ElasticsearchDomainConfig::advancedOptions))
.setter(setter(Builder::advancedOptions)).constructor(AdvancedOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AdvancedOptions").build()).build();
private static final SdkField LOG_PUBLISHING_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::logPublishingOptions)).setter(setter(Builder::logPublishingOptions))
.constructor(LogPublishingOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("LogPublishingOptions").build())
.build();
private static final SdkField DOMAIN_ENDPOINT_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::domainEndpointOptions)).setter(setter(Builder::domainEndpointOptions))
.constructor(DomainEndpointOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DomainEndpointOptions").build())
.build();
private static final SdkField ADVANCED_SECURITY_OPTIONS_FIELD = SdkField
. builder(MarshallingType.SDK_POJO)
.getter(getter(ElasticsearchDomainConfig::advancedSecurityOptions)).setter(setter(Builder::advancedSecurityOptions))
.constructor(AdvancedSecurityOptionsStatus::builder)
.traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AdvancedSecurityOptions").build())
.build();
private static final List> SDK_FIELDS = Collections
.unmodifiableList(Arrays.asList(ELASTICSEARCH_VERSION_FIELD, ELASTICSEARCH_CLUSTER_CONFIG_FIELD, EBS_OPTIONS_FIELD,
ACCESS_POLICIES_FIELD, SNAPSHOT_OPTIONS_FIELD, VPC_OPTIONS_FIELD, COGNITO_OPTIONS_FIELD,
ENCRYPTION_AT_REST_OPTIONS_FIELD, NODE_TO_NODE_ENCRYPTION_OPTIONS_FIELD, ADVANCED_OPTIONS_FIELD,
LOG_PUBLISHING_OPTIONS_FIELD, DOMAIN_ENDPOINT_OPTIONS_FIELD, ADVANCED_SECURITY_OPTIONS_FIELD));
private static final long serialVersionUID = 1L;
private final ElasticsearchVersionStatus elasticsearchVersion;
private final ElasticsearchClusterConfigStatus elasticsearchClusterConfig;
private final EBSOptionsStatus ebsOptions;
private final AccessPoliciesStatus accessPolicies;
private final SnapshotOptionsStatus snapshotOptions;
private final VPCDerivedInfoStatus vpcOptions;
private final CognitoOptionsStatus cognitoOptions;
private final EncryptionAtRestOptionsStatus encryptionAtRestOptions;
private final NodeToNodeEncryptionOptionsStatus nodeToNodeEncryptionOptions;
private final AdvancedOptionsStatus advancedOptions;
private final LogPublishingOptionsStatus logPublishingOptions;
private final DomainEndpointOptionsStatus domainEndpointOptions;
private final AdvancedSecurityOptionsStatus advancedSecurityOptions;
private ElasticsearchDomainConfig(BuilderImpl builder) {
this.elasticsearchVersion = builder.elasticsearchVersion;
this.elasticsearchClusterConfig = builder.elasticsearchClusterConfig;
this.ebsOptions = builder.ebsOptions;
this.accessPolicies = builder.accessPolicies;
this.snapshotOptions = builder.snapshotOptions;
this.vpcOptions = builder.vpcOptions;
this.cognitoOptions = builder.cognitoOptions;
this.encryptionAtRestOptions = builder.encryptionAtRestOptions;
this.nodeToNodeEncryptionOptions = builder.nodeToNodeEncryptionOptions;
this.advancedOptions = builder.advancedOptions;
this.logPublishingOptions = builder.logPublishingOptions;
this.domainEndpointOptions = builder.domainEndpointOptions;
this.advancedSecurityOptions = builder.advancedSecurityOptions;
}
/**
*
* String of format X.Y to specify version for the Elasticsearch domain.
*
*
* @return String of format X.Y to specify version for the Elasticsearch domain.
*/
public ElasticsearchVersionStatus elasticsearchVersion() {
return elasticsearchVersion;
}
/**
*
* Specifies the ElasticsearchClusterConfig for the Elasticsearch domain.
*
*
* @return Specifies the ElasticsearchClusterConfig for the Elasticsearch domain.
*/
public ElasticsearchClusterConfigStatus elasticsearchClusterConfig() {
return elasticsearchClusterConfig;
}
/**
*
* Specifies the EBSOptions for the Elasticsearch domain.
*
*
* @return Specifies the EBSOptions for the Elasticsearch domain.
*/
public EBSOptionsStatus ebsOptions() {
return ebsOptions;
}
/**
*
* IAM access policy as a JSON-formatted string.
*
*
* @return IAM access policy as a JSON-formatted string.
*/
public AccessPoliciesStatus accessPolicies() {
return accessPolicies;
}
/**
*
* Specifies the SnapshotOptions for the Elasticsearch domain.
*
*
* @return Specifies the SnapshotOptions for the Elasticsearch domain.
*/
public SnapshotOptionsStatus snapshotOptions() {
return snapshotOptions;
}
/**
*
*
* @return The CognitoOptions for the specified domain. For more information, see Amazon Cognito Authentication for Kibana.
*/
public CognitoOptionsStatus cognitoOptions() {
return cognitoOptions;
}
/**
*
* Specifies the EncryptionAtRestOptions for the Elasticsearch domain.
*
*
* @return Specifies the EncryptionAtRestOptions for the Elasticsearch domain.
*/
public EncryptionAtRestOptionsStatus encryptionAtRestOptions() {
return encryptionAtRestOptions;
}
/**
*
* Specifies the NodeToNodeEncryptionOptions for the Elasticsearch domain.
*
*
* @return Specifies the NodeToNodeEncryptionOptions for the Elasticsearch domain.
*/
public NodeToNodeEncryptionOptionsStatus nodeToNodeEncryptionOptions() {
return nodeToNodeEncryptionOptions;
}
/**
*
*
* @return Specifies the AdvancedOptions for the domain. See Configuring Advanced Options for more information.
*/
public AdvancedOptionsStatus advancedOptions() {
return advancedOptions;
}
/**
*
* Log publishing options for the given domain.
*
*
* @return Log publishing options for the given domain.
*/
public LogPublishingOptionsStatus logPublishingOptions() {
return logPublishingOptions;
}
/**
*
* Specifies the DomainEndpointOptions for the Elasticsearch domain.
*
*
* @return Specifies the DomainEndpointOptions for the Elasticsearch domain.
*/
public DomainEndpointOptionsStatus domainEndpointOptions() {
return domainEndpointOptions;
}
/**
*
* Specifies AdvancedSecurityOptions for the domain.
*
*
* @return Specifies AdvancedSecurityOptions for the domain.
*/
public AdvancedSecurityOptionsStatus advancedSecurityOptions() {
return advancedSecurityOptions;
}
@Override
public Builder toBuilder() {
return new BuilderImpl(this);
}
public static Builder builder() {
return new BuilderImpl();
}
public static Class extends Builder> serializableBuilderClass() {
return BuilderImpl.class;
}
@Override
public int hashCode() {
int hashCode = 1;
hashCode = 31 * hashCode + Objects.hashCode(elasticsearchVersion());
hashCode = 31 * hashCode + Objects.hashCode(elasticsearchClusterConfig());
hashCode = 31 * hashCode + Objects.hashCode(ebsOptions());
hashCode = 31 * hashCode + Objects.hashCode(accessPolicies());
hashCode = 31 * hashCode + Objects.hashCode(snapshotOptions());
hashCode = 31 * hashCode + Objects.hashCode(vpcOptions());
hashCode = 31 * hashCode + Objects.hashCode(cognitoOptions());
hashCode = 31 * hashCode + Objects.hashCode(encryptionAtRestOptions());
hashCode = 31 * hashCode + Objects.hashCode(nodeToNodeEncryptionOptions());
hashCode = 31 * hashCode + Objects.hashCode(advancedOptions());
hashCode = 31 * hashCode + Objects.hashCode(logPublishingOptions());
hashCode = 31 * hashCode + Objects.hashCode(domainEndpointOptions());
hashCode = 31 * hashCode + Objects.hashCode(advancedSecurityOptions());
return hashCode;
}
@Override
public boolean equals(Object obj) {
return equalsBySdkFields(obj);
}
@Override
public boolean equalsBySdkFields(Object obj) {
if (this == obj) {
return true;
}
if (obj == null) {
return false;
}
if (!(obj instanceof ElasticsearchDomainConfig)) {
return false;
}
ElasticsearchDomainConfig other = (ElasticsearchDomainConfig) obj;
return Objects.equals(elasticsearchVersion(), other.elasticsearchVersion())
&& Objects.equals(elasticsearchClusterConfig(), other.elasticsearchClusterConfig())
&& Objects.equals(ebsOptions(), other.ebsOptions()) && Objects.equals(accessPolicies(), other.accessPolicies())
&& Objects.equals(snapshotOptions(), other.snapshotOptions()) && Objects.equals(vpcOptions(), other.vpcOptions())
&& Objects.equals(cognitoOptions(), other.cognitoOptions())
&& Objects.equals(encryptionAtRestOptions(), other.encryptionAtRestOptions())
&& Objects.equals(nodeToNodeEncryptionOptions(), other.nodeToNodeEncryptionOptions())
&& Objects.equals(advancedOptions(), other.advancedOptions())
&& Objects.equals(logPublishingOptions(), other.logPublishingOptions())
&& Objects.equals(domainEndpointOptions(), other.domainEndpointOptions())
&& Objects.equals(advancedSecurityOptions(), other.advancedSecurityOptions());
}
/**
* 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 String toString() {
return ToString.builder("ElasticsearchDomainConfig").add("ElasticsearchVersion", elasticsearchVersion())
.add("ElasticsearchClusterConfig", elasticsearchClusterConfig()).add("EBSOptions", ebsOptions())
.add("AccessPolicies", accessPolicies()).add("SnapshotOptions", snapshotOptions())
.add("VPCOptions", vpcOptions()).add("CognitoOptions", cognitoOptions())
.add("EncryptionAtRestOptions", encryptionAtRestOptions())
.add("NodeToNodeEncryptionOptions", nodeToNodeEncryptionOptions()).add("AdvancedOptions", advancedOptions())
.add("LogPublishingOptions", logPublishingOptions()).add("DomainEndpointOptions", domainEndpointOptions())
.add("AdvancedSecurityOptions", advancedSecurityOptions()).build();
}
public Optional getValueForField(String fieldName, Class clazz) {
switch (fieldName) {
case "ElasticsearchVersion":
return Optional.ofNullable(clazz.cast(elasticsearchVersion()));
case "ElasticsearchClusterConfig":
return Optional.ofNullable(clazz.cast(elasticsearchClusterConfig()));
case "EBSOptions":
return Optional.ofNullable(clazz.cast(ebsOptions()));
case "AccessPolicies":
return Optional.ofNullable(clazz.cast(accessPolicies()));
case "SnapshotOptions":
return Optional.ofNullable(clazz.cast(snapshotOptions()));
case "VPCOptions":
return Optional.ofNullable(clazz.cast(vpcOptions()));
case "CognitoOptions":
return Optional.ofNullable(clazz.cast(cognitoOptions()));
case "EncryptionAtRestOptions":
return Optional.ofNullable(clazz.cast(encryptionAtRestOptions()));
case "NodeToNodeEncryptionOptions":
return Optional.ofNullable(clazz.cast(nodeToNodeEncryptionOptions()));
case "AdvancedOptions":
return Optional.ofNullable(clazz.cast(advancedOptions()));
case "LogPublishingOptions":
return Optional.ofNullable(clazz.cast(logPublishingOptions()));
case "DomainEndpointOptions":
return Optional.ofNullable(clazz.cast(domainEndpointOptions()));
case "AdvancedSecurityOptions":
return Optional.ofNullable(clazz.cast(advancedSecurityOptions()));
default:
return Optional.empty();
}
}
@Override
public List> sdkFields() {
return SDK_FIELDS;
}
private static Function