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

software.amazon.awssdk.services.applicationdiscovery.model.CustomerMeCollectorInfo Maven / Gradle / Ivy

Go to download

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

There is a newer version: 2.28.6
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.applicationdiscovery.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.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 inventory data for installed Migration Evaluator collectors. *

*/ @Generated("software.amazon.awssdk:codegen") public final class CustomerMeCollectorInfo implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField ACTIVE_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("activeMeCollectors").getter(getter(CustomerMeCollectorInfo::activeMeCollectors)) .setter(setter(Builder::activeMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("activeMeCollectors").build()) .build(); private static final SdkField HEALTHY_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("healthyMeCollectors").getter(getter(CustomerMeCollectorInfo::healthyMeCollectors)) .setter(setter(Builder::healthyMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("healthyMeCollectors").build()) .build(); private static final SdkField DENY_LISTED_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("denyListedMeCollectors").getter(getter(CustomerMeCollectorInfo::denyListedMeCollectors)) .setter(setter(Builder::denyListedMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("denyListedMeCollectors").build()) .build(); private static final SdkField SHUTDOWN_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("shutdownMeCollectors").getter(getter(CustomerMeCollectorInfo::shutdownMeCollectors)) .setter(setter(Builder::shutdownMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("shutdownMeCollectors").build()) .build(); private static final SdkField UNHEALTHY_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("unhealthyMeCollectors").getter(getter(CustomerMeCollectorInfo::unhealthyMeCollectors)) .setter(setter(Builder::unhealthyMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("unhealthyMeCollectors").build()) .build(); private static final SdkField TOTAL_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("totalMeCollectors").getter(getter(CustomerMeCollectorInfo::totalMeCollectors)) .setter(setter(Builder::totalMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("totalMeCollectors").build()).build(); private static final SdkField UNKNOWN_ME_COLLECTORS_FIELD = SdkField. builder(MarshallingType.INTEGER) .memberName("unknownMeCollectors").getter(getter(CustomerMeCollectorInfo::unknownMeCollectors)) .setter(setter(Builder::unknownMeCollectors)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("unknownMeCollectors").build()) .build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(ACTIVE_ME_COLLECTORS_FIELD, HEALTHY_ME_COLLECTORS_FIELD, DENY_LISTED_ME_COLLECTORS_FIELD, SHUTDOWN_ME_COLLECTORS_FIELD, UNHEALTHY_ME_COLLECTORS_FIELD, TOTAL_ME_COLLECTORS_FIELD, UNKNOWN_ME_COLLECTORS_FIELD)); private static final long serialVersionUID = 1L; private final Integer activeMeCollectors; private final Integer healthyMeCollectors; private final Integer denyListedMeCollectors; private final Integer shutdownMeCollectors; private final Integer unhealthyMeCollectors; private final Integer totalMeCollectors; private final Integer unknownMeCollectors; private CustomerMeCollectorInfo(BuilderImpl builder) { this.activeMeCollectors = builder.activeMeCollectors; this.healthyMeCollectors = builder.healthyMeCollectors; this.denyListedMeCollectors = builder.denyListedMeCollectors; this.shutdownMeCollectors = builder.shutdownMeCollectors; this.unhealthyMeCollectors = builder.unhealthyMeCollectors; this.totalMeCollectors = builder.totalMeCollectors; this.unknownMeCollectors = builder.unknownMeCollectors; } /** *

* The number of active Migration Evaluator collectors. *

* * @return The number of active Migration Evaluator collectors. */ public final Integer activeMeCollectors() { return activeMeCollectors; } /** *

* The number of healthy Migration Evaluator collectors. *

* * @return The number of healthy Migration Evaluator collectors. */ public final Integer healthyMeCollectors() { return healthyMeCollectors; } /** *

* The number of deny-listed Migration Evaluator collectors. *

* * @return The number of deny-listed Migration Evaluator collectors. */ public final Integer denyListedMeCollectors() { return denyListedMeCollectors; } /** *

* The number of Migration Evaluator collectors with SHUTDOWN status. *

* * @return The number of Migration Evaluator collectors with SHUTDOWN status. */ public final Integer shutdownMeCollectors() { return shutdownMeCollectors; } /** *

* The number of unhealthy Migration Evaluator collectors. *

* * @return The number of unhealthy Migration Evaluator collectors. */ public final Integer unhealthyMeCollectors() { return unhealthyMeCollectors; } /** *

* The total number of Migration Evaluator collectors. *

* * @return The total number of Migration Evaluator collectors. */ public final Integer totalMeCollectors() { return totalMeCollectors; } /** *

* The number of unknown Migration Evaluator collectors. *

* * @return The number of unknown Migration Evaluator collectors. */ public final Integer unknownMeCollectors() { return unknownMeCollectors; } @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(activeMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(healthyMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(denyListedMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(shutdownMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(unhealthyMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(totalMeCollectors()); hashCode = 31 * hashCode + Objects.hashCode(unknownMeCollectors()); 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 CustomerMeCollectorInfo)) { return false; } CustomerMeCollectorInfo other = (CustomerMeCollectorInfo) obj; return Objects.equals(activeMeCollectors(), other.activeMeCollectors()) && Objects.equals(healthyMeCollectors(), other.healthyMeCollectors()) && Objects.equals(denyListedMeCollectors(), other.denyListedMeCollectors()) && Objects.equals(shutdownMeCollectors(), other.shutdownMeCollectors()) && Objects.equals(unhealthyMeCollectors(), other.unhealthyMeCollectors()) && Objects.equals(totalMeCollectors(), other.totalMeCollectors()) && Objects.equals(unknownMeCollectors(), other.unknownMeCollectors()); } /** * 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("CustomerMeCollectorInfo").add("ActiveMeCollectors", activeMeCollectors()) .add("HealthyMeCollectors", healthyMeCollectors()).add("DenyListedMeCollectors", denyListedMeCollectors()) .add("ShutdownMeCollectors", shutdownMeCollectors()).add("UnhealthyMeCollectors", unhealthyMeCollectors()) .add("TotalMeCollectors", totalMeCollectors()).add("UnknownMeCollectors", unknownMeCollectors()).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "activeMeCollectors": return Optional.ofNullable(clazz.cast(activeMeCollectors())); case "healthyMeCollectors": return Optional.ofNullable(clazz.cast(healthyMeCollectors())); case "denyListedMeCollectors": return Optional.ofNullable(clazz.cast(denyListedMeCollectors())); case "shutdownMeCollectors": return Optional.ofNullable(clazz.cast(shutdownMeCollectors())); case "unhealthyMeCollectors": return Optional.ofNullable(clazz.cast(unhealthyMeCollectors())); case "totalMeCollectors": return Optional.ofNullable(clazz.cast(totalMeCollectors())); case "unknownMeCollectors": return Optional.ofNullable(clazz.cast(unknownMeCollectors())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((CustomerMeCollectorInfo) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** *

* The number of active Migration Evaluator collectors. *

* * @param activeMeCollectors * The number of active Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder activeMeCollectors(Integer activeMeCollectors); /** *

* The number of healthy Migration Evaluator collectors. *

* * @param healthyMeCollectors * The number of healthy Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder healthyMeCollectors(Integer healthyMeCollectors); /** *

* The number of deny-listed Migration Evaluator collectors. *

* * @param denyListedMeCollectors * The number of deny-listed Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder denyListedMeCollectors(Integer denyListedMeCollectors); /** *

* The number of Migration Evaluator collectors with SHUTDOWN status. *

* * @param shutdownMeCollectors * The number of Migration Evaluator collectors with SHUTDOWN status. * @return Returns a reference to this object so that method calls can be chained together. */ Builder shutdownMeCollectors(Integer shutdownMeCollectors); /** *

* The number of unhealthy Migration Evaluator collectors. *

* * @param unhealthyMeCollectors * The number of unhealthy Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder unhealthyMeCollectors(Integer unhealthyMeCollectors); /** *

* The total number of Migration Evaluator collectors. *

* * @param totalMeCollectors * The total number of Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder totalMeCollectors(Integer totalMeCollectors); /** *

* The number of unknown Migration Evaluator collectors. *

* * @param unknownMeCollectors * The number of unknown Migration Evaluator collectors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder unknownMeCollectors(Integer unknownMeCollectors); } static final class BuilderImpl implements Builder { private Integer activeMeCollectors; private Integer healthyMeCollectors; private Integer denyListedMeCollectors; private Integer shutdownMeCollectors; private Integer unhealthyMeCollectors; private Integer totalMeCollectors; private Integer unknownMeCollectors; private BuilderImpl() { } private BuilderImpl(CustomerMeCollectorInfo model) { activeMeCollectors(model.activeMeCollectors); healthyMeCollectors(model.healthyMeCollectors); denyListedMeCollectors(model.denyListedMeCollectors); shutdownMeCollectors(model.shutdownMeCollectors); unhealthyMeCollectors(model.unhealthyMeCollectors); totalMeCollectors(model.totalMeCollectors); unknownMeCollectors(model.unknownMeCollectors); } public final Integer getActiveMeCollectors() { return activeMeCollectors; } public final void setActiveMeCollectors(Integer activeMeCollectors) { this.activeMeCollectors = activeMeCollectors; } @Override public final Builder activeMeCollectors(Integer activeMeCollectors) { this.activeMeCollectors = activeMeCollectors; return this; } public final Integer getHealthyMeCollectors() { return healthyMeCollectors; } public final void setHealthyMeCollectors(Integer healthyMeCollectors) { this.healthyMeCollectors = healthyMeCollectors; } @Override public final Builder healthyMeCollectors(Integer healthyMeCollectors) { this.healthyMeCollectors = healthyMeCollectors; return this; } public final Integer getDenyListedMeCollectors() { return denyListedMeCollectors; } public final void setDenyListedMeCollectors(Integer denyListedMeCollectors) { this.denyListedMeCollectors = denyListedMeCollectors; } @Override public final Builder denyListedMeCollectors(Integer denyListedMeCollectors) { this.denyListedMeCollectors = denyListedMeCollectors; return this; } public final Integer getShutdownMeCollectors() { return shutdownMeCollectors; } public final void setShutdownMeCollectors(Integer shutdownMeCollectors) { this.shutdownMeCollectors = shutdownMeCollectors; } @Override public final Builder shutdownMeCollectors(Integer shutdownMeCollectors) { this.shutdownMeCollectors = shutdownMeCollectors; return this; } public final Integer getUnhealthyMeCollectors() { return unhealthyMeCollectors; } public final void setUnhealthyMeCollectors(Integer unhealthyMeCollectors) { this.unhealthyMeCollectors = unhealthyMeCollectors; } @Override public final Builder unhealthyMeCollectors(Integer unhealthyMeCollectors) { this.unhealthyMeCollectors = unhealthyMeCollectors; return this; } public final Integer getTotalMeCollectors() { return totalMeCollectors; } public final void setTotalMeCollectors(Integer totalMeCollectors) { this.totalMeCollectors = totalMeCollectors; } @Override public final Builder totalMeCollectors(Integer totalMeCollectors) { this.totalMeCollectors = totalMeCollectors; return this; } public final Integer getUnknownMeCollectors() { return unknownMeCollectors; } public final void setUnknownMeCollectors(Integer unknownMeCollectors) { this.unknownMeCollectors = unknownMeCollectors; } @Override public final Builder unknownMeCollectors(Integer unknownMeCollectors) { this.unknownMeCollectors = unknownMeCollectors; return this; } @Override public CustomerMeCollectorInfo build() { return new CustomerMeCollectorInfo(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy