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

org.jclouds.googlecomputeengine.domain.AutoValue_TargetPool Maven / Gradle / Ivy

The newest version!


package org.jclouds.googlecomputeengine.domain;

import java.net.URI;
import java.util.Date;
import java.util.List;
import javax.annotation.processing.Generated;
import org.jclouds.googlecomputeengine.options.TargetPoolCreationOptions;
import org.jclouds.javax.annotation.Nullable;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
 final class AutoValue_TargetPool extends TargetPool {

  private final String id;
  private final URI selfLink;
  private final Date creationTimestamp;
  private final String name;
  private final String description;
  private final URI region;
  private final List healthChecks;
  private final List instances;
  private final TargetPoolCreationOptions.SessionAffinityValue sessionAffinity;
  private final Float failoverRatio;
  private final URI backupPool;

  AutoValue_TargetPool(
      String id,
      URI selfLink,
      Date creationTimestamp,
      String name,
      @Nullable String description,
      URI region,
      List healthChecks,
      List instances,
      @Nullable TargetPoolCreationOptions.SessionAffinityValue sessionAffinity,
      @Nullable Float failoverRatio,
      @Nullable URI backupPool) {
    if (id == null) {
      throw new NullPointerException("Null id");
    }
    this.id = id;
    if (selfLink == null) {
      throw new NullPointerException("Null selfLink");
    }
    this.selfLink = selfLink;
    if (creationTimestamp == null) {
      throw new NullPointerException("Null creationTimestamp");
    }
    this.creationTimestamp = creationTimestamp;
    if (name == null) {
      throw new NullPointerException("Null name");
    }
    this.name = name;
    this.description = description;
    if (region == null) {
      throw new NullPointerException("Null region");
    }
    this.region = region;
    if (healthChecks == null) {
      throw new NullPointerException("Null healthChecks");
    }
    this.healthChecks = healthChecks;
    if (instances == null) {
      throw new NullPointerException("Null instances");
    }
    this.instances = instances;
    this.sessionAffinity = sessionAffinity;
    this.failoverRatio = failoverRatio;
    this.backupPool = backupPool;
  }

  @Override
  public String id() {
    return id;
  }

  @Override
  public URI selfLink() {
    return selfLink;
  }

  @Override
  public Date creationTimestamp() {
    return creationTimestamp;
  }

  @Override
  public String name() {
    return name;
  }

  @Nullable
  @Override
  public String description() {
    return description;
  }

  @Override
  public URI region() {
    return region;
  }

  @Override
  public List healthChecks() {
    return healthChecks;
  }

  @Override
  public List instances() {
    return instances;
  }

  @Nullable
  @Override
  public TargetPoolCreationOptions.SessionAffinityValue sessionAffinity() {
    return sessionAffinity;
  }

  @Nullable
  @Override
  public Float failoverRatio() {
    return failoverRatio;
  }

  @Nullable
  @Override
  public URI backupPool() {
    return backupPool;
  }

  @Override
  public String toString() {
    return "TargetPool{"
         + "id=" + id + ", "
         + "selfLink=" + selfLink + ", "
         + "creationTimestamp=" + creationTimestamp + ", "
         + "name=" + name + ", "
         + "description=" + description + ", "
         + "region=" + region + ", "
         + "healthChecks=" + healthChecks + ", "
         + "instances=" + instances + ", "
         + "sessionAffinity=" + sessionAffinity + ", "
         + "failoverRatio=" + failoverRatio + ", "
         + "backupPool=" + backupPool
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof TargetPool) {
      TargetPool that = (TargetPool) o;
      return (this.id.equals(that.id()))
           && (this.selfLink.equals(that.selfLink()))
           && (this.creationTimestamp.equals(that.creationTimestamp()))
           && (this.name.equals(that.name()))
           && ((this.description == null) ? (that.description() == null) : this.description.equals(that.description()))
           && (this.region.equals(that.region()))
           && (this.healthChecks.equals(that.healthChecks()))
           && (this.instances.equals(that.instances()))
           && ((this.sessionAffinity == null) ? (that.sessionAffinity() == null) : this.sessionAffinity.equals(that.sessionAffinity()))
           && ((this.failoverRatio == null) ? (that.failoverRatio() == null) : this.failoverRatio.equals(that.failoverRatio()))
           && ((this.backupPool == null) ? (that.backupPool() == null) : this.backupPool.equals(that.backupPool()));
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= id.hashCode();
    h$ *= 1000003;
    h$ ^= selfLink.hashCode();
    h$ *= 1000003;
    h$ ^= creationTimestamp.hashCode();
    h$ *= 1000003;
    h$ ^= name.hashCode();
    h$ *= 1000003;
    h$ ^= (description == null) ? 0 : description.hashCode();
    h$ *= 1000003;
    h$ ^= region.hashCode();
    h$ *= 1000003;
    h$ ^= healthChecks.hashCode();
    h$ *= 1000003;
    h$ ^= instances.hashCode();
    h$ *= 1000003;
    h$ ^= (sessionAffinity == null) ? 0 : sessionAffinity.hashCode();
    h$ *= 1000003;
    h$ ^= (failoverRatio == null) ? 0 : failoverRatio.hashCode();
    h$ *= 1000003;
    h$ ^= (backupPool == null) ? 0 : backupPool.hashCode();
    return h$;
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy