nl.vpro.nep.sam.model.StreamWithRequiredPropertiesAttributes Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of media-nep Show documentation
Show all versions of media-nep Show documentation
Support for the several APIs of NEP that POMS is integrating with
/*
* Stream Access Manager
* Get access to a stream in order to view it
*
* The version of the OpenAPI document: 4.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package nl.vpro.nep.sam.model;
import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import nl.vpro.nep.sam.model.StreamProfileItemAttributes;
import nl.vpro.nep.sam.model.StreamTypeEnum;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonTypeName;
import jakarta.validation.constraints.*;
import jakarta.validation.Valid;
/**
* StreamWithRequiredPropertiesAttributes
*/
@JsonPropertyOrder({
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_STREAM_TYPE,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_START_TIME,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_STOP_TIME,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_CHANNEL,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_STATUS,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_LEGACY,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_VERSION,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_DRM,
StreamWithRequiredPropertiesAttributes.JSON_PROPERTY_PROFILES
})
@JsonTypeName("StreamWithRequiredProperties_attributes")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2024-12-18T10:26:20.602909888Z[Etc/UTC]", comments = "Generator version: 7.6.0")
public class StreamWithRequiredPropertiesAttributes {
public static final String JSON_PROPERTY_STREAM_TYPE = "streamType";
private StreamTypeEnum streamType;
public static final String JSON_PROPERTY_START_TIME = "startTime";
private String startTime;
public static final String JSON_PROPERTY_STOP_TIME = "stopTime";
private String stopTime;
public static final String JSON_PROPERTY_CHANNEL = "channel";
private String channel;
/**
* The status of the stream (offline or online)
*/
public enum StatusEnum {
OFFLINE("offline"),
ONLINE("online");
private String value;
StatusEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
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 final String JSON_PROPERTY_STATUS = "status";
private StatusEnum status;
public static final String JSON_PROPERTY_LEGACY = "legacy";
private Boolean legacy = false;
public static final String JSON_PROPERTY_VERSION = "version";
private Integer version;
public static final String JSON_PROPERTY_DRM = "drm";
private Boolean drm = true;
public static final String JSON_PROPERTY_PROFILES = "profiles";
private List<@Valid StreamProfileItemAttributes> profiles = new ArrayList<>();
public StreamWithRequiredPropertiesAttributes() {
}
public StreamWithRequiredPropertiesAttributes streamType(StreamTypeEnum streamType) {
this.streamType = streamType;
return this;
}
/**
* Get streamType
* @return streamType
**/
@jakarta.annotation.Nonnull
@NotNull
@Valid
@JsonProperty(JSON_PROPERTY_STREAM_TYPE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public StreamTypeEnum getStreamType() {
return streamType;
}
@JsonProperty(JSON_PROPERTY_STREAM_TYPE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setStreamType(StreamTypeEnum streamType) {
this.streamType = streamType;
}
public StreamWithRequiredPropertiesAttributes startTime(String startTime) {
this.startTime = startTime;
return this;
}
/**
* The start time of the stream
* @return startTime
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_START_TIME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getStartTime() {
return startTime;
}
@JsonProperty(JSON_PROPERTY_START_TIME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setStartTime(String startTime) {
this.startTime = startTime;
}
public StreamWithRequiredPropertiesAttributes stopTime(String stopTime) {
this.stopTime = stopTime;
return this;
}
/**
* The stop time of the stream
* @return stopTime
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_STOP_TIME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getStopTime() {
return stopTime;
}
@JsonProperty(JSON_PROPERTY_STOP_TIME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setStopTime(String stopTime) {
this.stopTime = stopTime;
}
public StreamWithRequiredPropertiesAttributes channel(String channel) {
this.channel = channel;
return this;
}
/**
* The stream id of the channel where this stream is broadcasted
* @return channel
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_CHANNEL)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getChannel() {
return channel;
}
@JsonProperty(JSON_PROPERTY_CHANNEL)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setChannel(String channel) {
this.channel = channel;
}
public StreamWithRequiredPropertiesAttributes status(StatusEnum status) {
this.status = status;
return this;
}
/**
* The status of the stream (offline or online)
* @return status
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_STATUS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public StatusEnum getStatus() {
return status;
}
@JsonProperty(JSON_PROPERTY_STATUS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setStatus(StatusEnum status) {
this.status = status;
}
public StreamWithRequiredPropertiesAttributes legacy(Boolean legacy) {
this.legacy = legacy;
return this;
}
/**
* Flags if the stream has not been migrated to the new cdn yet, default: false
* @return legacy
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_LEGACY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Boolean getLegacy() {
return legacy;
}
@JsonProperty(JSON_PROPERTY_LEGACY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setLegacy(Boolean legacy) {
this.legacy = legacy;
}
public StreamWithRequiredPropertiesAttributes version(Integer version) {
this.version = version;
return this;
}
/**
* Get version
* @return version
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_VERSION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Integer getVersion() {
return version;
}
@JsonProperty(JSON_PROPERTY_VERSION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setVersion(Integer version) {
this.version = version;
}
public StreamWithRequiredPropertiesAttributes drm(Boolean drm) {
this.drm = drm;
return this;
}
/**
* Indicates if the stream has drm encryption or not, default: true
* @return drm
**/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_DRM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Boolean getDrm() {
return drm;
}
@JsonProperty(JSON_PROPERTY_DRM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setDrm(Boolean drm) {
this.drm = drm;
}
public StreamWithRequiredPropertiesAttributes profiles(List<@Valid StreamProfileItemAttributes> profiles) {
this.profiles = profiles;
return this;
}
public StreamWithRequiredPropertiesAttributes addProfilesItem(StreamProfileItemAttributes profilesItem) {
if (this.profiles == null) {
this.profiles = new ArrayList<>();
}
this.profiles.add(profilesItem);
return this;
}
/**
* Get profiles
* @return profiles
**/
@jakarta.annotation.Nullable
@Valid
@JsonProperty(JSON_PROPERTY_PROFILES)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public List<@Valid StreamProfileItemAttributes> getProfiles() {
return profiles;
}
@JsonProperty(JSON_PROPERTY_PROFILES)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setProfiles(List<@Valid StreamProfileItemAttributes> profiles) {
this.profiles = profiles;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
StreamWithRequiredPropertiesAttributes streamWithRequiredPropertiesAttributes = (StreamWithRequiredPropertiesAttributes) o;
return Objects.equals(this.streamType, streamWithRequiredPropertiesAttributes.streamType) &&
Objects.equals(this.startTime, streamWithRequiredPropertiesAttributes.startTime) &&
Objects.equals(this.stopTime, streamWithRequiredPropertiesAttributes.stopTime) &&
Objects.equals(this.channel, streamWithRequiredPropertiesAttributes.channel) &&
Objects.equals(this.status, streamWithRequiredPropertiesAttributes.status) &&
Objects.equals(this.legacy, streamWithRequiredPropertiesAttributes.legacy) &&
Objects.equals(this.version, streamWithRequiredPropertiesAttributes.version) &&
Objects.equals(this.drm, streamWithRequiredPropertiesAttributes.drm) &&
Objects.equals(this.profiles, streamWithRequiredPropertiesAttributes.profiles);
}
@Override
public int hashCode() {
return Objects.hash(streamType, startTime, stopTime, channel, status, legacy, version, drm, profiles);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class StreamWithRequiredPropertiesAttributes {\n");
sb.append(" streamType: ").append(toIndentedString(streamType)).append("\n");
sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n");
sb.append(" stopTime: ").append(toIndentedString(stopTime)).append("\n");
sb.append(" channel: ").append(toIndentedString(channel)).append("\n");
sb.append(" status: ").append(toIndentedString(status)).append("\n");
sb.append(" legacy: ").append(toIndentedString(legacy)).append("\n");
sb.append(" version: ").append(toIndentedString(version)).append("\n");
sb.append(" drm: ").append(toIndentedString(drm)).append("\n");
sb.append(" profiles: ").append(toIndentedString(profiles)).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