com.mux.sdk.models.Space 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.Broadcast;
import com.mux.sdk.models.SpaceStatus;
import com.mux.sdk.models.SpaceType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
/**
* Space
*/
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class Space {
public static final String SERIALIZED_NAME_ID = "id";
@SerializedName(SERIALIZED_NAME_ID)
private String id;
public static final String SERIALIZED_NAME_CREATED_AT = "created_at";
@SerializedName(SERIALIZED_NAME_CREATED_AT)
private String createdAt;
public static final String SERIALIZED_NAME_TYPE = "type";
@SerializedName(SERIALIZED_NAME_TYPE)
private SpaceType type = SpaceType.SERVER;
public static final String SERIALIZED_NAME_STATUS = "status";
@SerializedName(SERIALIZED_NAME_STATUS)
private SpaceStatus status;
public static final String SERIALIZED_NAME_PASSTHROUGH = "passthrough";
@SerializedName(SERIALIZED_NAME_PASSTHROUGH)
private String passthrough;
public static final String SERIALIZED_NAME_BROADCASTS = "broadcasts";
@SerializedName(SERIALIZED_NAME_BROADCASTS)
private java.util.List broadcasts = null;
public static final String SERIALIZED_NAME_ACTIVE_SESSION_ID = "active_session_id";
@SerializedName(SERIALIZED_NAME_ACTIVE_SESSION_ID)
private String activeSessionId;
public Space id(String id) {
this.id = id;
return this;
}
/**
* Unique identifier for the space. Max 255 characters.
* @return id
**/
@ApiModelProperty(required = true, value = "Unique identifier for the space. Max 255 characters.")
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public Space createdAt(String createdAt) {
this.createdAt = createdAt;
return this;
}
/**
* Time the space was created, defined as a Unix timestamp (seconds since epoch).
* @return createdAt
**/
@ApiModelProperty(required = true, value = "Time the space was created, defined as a Unix timestamp (seconds since epoch).")
public String getCreatedAt() {
return createdAt;
}
public void setCreatedAt(String createdAt) {
this.createdAt = createdAt;
}
public Space type(SpaceType type) {
this.type = type;
return this;
}
/**
* Get type
* @return type
**/
@ApiModelProperty(required = true, value = "")
public SpaceType getType() {
return type;
}
public void setType(SpaceType type) {
this.type = type;
}
public Space status(SpaceStatus status) {
this.status = status;
return this;
}
/**
* Get status
* @return status
**/
@ApiModelProperty(required = true, value = "")
public SpaceStatus getStatus() {
return status;
}
public void setStatus(SpaceStatus status) {
this.status = status;
}
public Space passthrough(String passthrough) {
this.passthrough = passthrough;
return this;
}
/**
* Arbitrary user-supplied metadata that will be included in the space details and related webhooks. Max: 255 characters.
* @return passthrough
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "Arbitrary user-supplied metadata that will be included in the space details and related webhooks. Max: 255 characters.")
public String getPassthrough() {
return passthrough;
}
public void setPassthrough(String passthrough) {
this.passthrough = passthrough;
}
public Space broadcasts(java.util.List broadcasts) {
this.broadcasts = broadcasts;
return this;
}
public Space addBroadcastsItem(Broadcast broadcastsItem) {
if (this.broadcasts == null) {
this.broadcasts = new java.util.ArrayList<>();
}
this.broadcasts.add(broadcastsItem);
return this;
}
/**
* An array of broadcast destinations.
* @return broadcasts
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "An array of broadcast destinations.")
public java.util.List getBroadcasts() {
return broadcasts;
}
public void setBroadcasts(java.util.List broadcasts) {
this.broadcasts = broadcasts;
}
public Space activeSessionId(String activeSessionId) {
this.activeSessionId = activeSessionId;
return this;
}
/**
* Unique identifier for the current lifecycle of the space. Only set when the space is `active` and is set to a new value each time the space transitions from `idle` to `active`. This value is useful for logging and debugging issues. Max 255 characters.
* @return activeSessionId
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "Unique identifier for the current lifecycle of the space. Only set when the space is `active` and is set to a new value each time the space transitions from `idle` to `active`. This value is useful for logging and debugging issues. Max 255 characters.")
public String getActiveSessionId() {
return activeSessionId;
}
public void setActiveSessionId(String activeSessionId) {
this.activeSessionId = activeSessionId;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Space space = (Space) o;
return Objects.equals(this.id, space.id) &&
Objects.equals(this.createdAt, space.createdAt) &&
Objects.equals(this.type, space.type) &&
Objects.equals(this.status, space.status) &&
Objects.equals(this.passthrough, space.passthrough) &&
Objects.equals(this.broadcasts, space.broadcasts) &&
Objects.equals(this.activeSessionId, space.activeSessionId);
}
@Override
public int hashCode() {
return Objects.hash(id, createdAt, type, status, passthrough, broadcasts, activeSessionId);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Space {\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" status: ").append(toIndentedString(status)).append("\n");
sb.append(" passthrough: ").append(toIndentedString(passthrough)).append("\n");
sb.append(" broadcasts: ").append(toIndentedString(broadcasts)).append("\n");
sb.append(" activeSessionId: ").append(toIndentedString(activeSessionId)).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