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

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

The newest version!

package org.jclouds.googlecomputeengine.domain;

import java.net.URI;
import javax.annotation.Generated;
import org.jclouds.javax.annotation.Nullable;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
 final class AutoValue_Image_RawDisk extends Image.RawDisk {

  private final URI source;
  private final String containerType;
  private final String sha1Checksum;

  AutoValue_Image_RawDisk(
      URI source,
      String containerType,
      @Nullable String sha1Checksum) {
    if (source == null) {
      throw new NullPointerException("Null source");
    }
    this.source = source;
    if (containerType == null) {
      throw new NullPointerException("Null containerType");
    }
    this.containerType = containerType;
    this.sha1Checksum = sha1Checksum;
  }

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

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

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

  @Override
  public String toString() {
    return "RawDisk{"
        + "source=" + source + ", "
        + "containerType=" + containerType + ", "
        + "sha1Checksum=" + sha1Checksum
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof Image.RawDisk) {
      Image.RawDisk that = (Image.RawDisk) o;
      return (this.source.equals(that.source()))
           && (this.containerType.equals(that.containerType()))
           && ((this.sha1Checksum == null) ? (that.sha1Checksum() == null) : this.sha1Checksum.equals(that.sha1Checksum()));
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h = 1;
    h *= 1000003;
    h ^= this.source.hashCode();
    h *= 1000003;
    h ^= this.containerType.hashCode();
    h *= 1000003;
    h ^= (sha1Checksum == null) ? 0 : this.sha1Checksum.hashCode();
    return h;
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy