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

com.mux.sdk.models.AssetStaticRenditions Maven / Gradle / Ivy

/*
 * Mux API
 * Mux is how developers build online video. This API encompasses both Mux Video and Mux Data functionality to help you build your video-related projects better and faster than ever before.
 *
 * The version of the OpenAPI document: v1
 * Contact: [email protected]
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package com.mux.sdk.models;

import java.util.Objects;
import java.util.Arrays;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import com.mux.sdk.models.AssetStaticRenditionsFiles;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;

/**
 * An object containing the current status of any static renditions (mp4s). The object does not exist if no static renditions have been requested. See [Download your videos](https://docs.mux.com/guides/enable-static-mp4-renditions) for more information.
 */
@ApiModel(description = "An object containing the current status of any static renditions (mp4s). The object does not exist if no static renditions have been requested. See [Download your videos](https://docs.mux.com/guides/enable-static-mp4-renditions) for more information.")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AssetStaticRenditions {
  /**
   * Indicates the status of downloadable MP4 versions of this asset.
   */
  @JsonAdapter(StatusEnum.Adapter.class)
  public enum StatusEnum {
    READY("ready"),
    
    PREPARING("preparing"),
    
    DISABLED("disabled"),
    
    ERRORED("errored");

    private String value;

    StatusEnum(String value) {
      this.value = value;
    }

    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }

    public static StatusEnum fromValue(String value) {
      for (StatusEnum b : StatusEnum.values()) {
        if (b.value.equals(value)) {
          return b;
        }
      }
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
    }

    public static class Adapter extends TypeAdapter {
      @Override
      public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException {
        jsonWriter.value(enumeration.getValue());
      }

      @Override
      public StatusEnum read(final JsonReader jsonReader) throws IOException {
        String value =  jsonReader.nextString();
        return StatusEnum.fromValue(value);
      }
    }
  }

  public static final String SERIALIZED_NAME_STATUS = "status";
  @SerializedName(SERIALIZED_NAME_STATUS)
  private StatusEnum status = StatusEnum.DISABLED;

  public static final String SERIALIZED_NAME_FILES = "files";
  @SerializedName(SERIALIZED_NAME_FILES)
  private java.util.List files = null;


  public AssetStaticRenditions status(StatusEnum status) {
    
    this.status = status;
    return this;
  }

   /**
   * Indicates the status of downloadable MP4 versions of this asset.
   * @return status
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "Indicates the status of downloadable MP4 versions of this asset.")

  public StatusEnum getStatus() {
    return status;
  }


  public void setStatus(StatusEnum status) {
    this.status = status;
  }


  public AssetStaticRenditions files(java.util.List files) {
    
    this.files = files;
    return this;
  }

  public AssetStaticRenditions addFilesItem(AssetStaticRenditionsFiles filesItem) {
    if (this.files == null) {
      this.files = new java.util.ArrayList<>();
    }
    this.files.add(filesItem);
    return this;
  }

   /**
   * Array of file objects.
   * @return files
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "Array of file objects.")

  public java.util.List getFiles() {
    return files;
  }


  public void setFiles(java.util.List files) {
    this.files = files;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    AssetStaticRenditions assetStaticRenditions = (AssetStaticRenditions) o;
    return Objects.equals(this.status, assetStaticRenditions.status) &&
        Objects.equals(this.files, assetStaticRenditions.files);
  }

  @Override
  public int hashCode() {
    return Objects.hash(status, files);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class AssetStaticRenditions {\n");
    sb.append("    status: ").append(toIndentedString(status)).append("\n");
    sb.append("    files: ").append(toIndentedString(files)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy