(warning);
}
/**
* List of messages that warn about conditions that might cause your job not to run or to fail.
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setWarning(java.util.Collection)} or {@link #withWarning(java.util.Collection)} if you want to override
* the existing values.
*
*
* @param warning
* List of messages that warn about conditions that might cause your job not to run or to fail.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public JobMessages withWarning(String... warning) {
if (this.warning == null) {
setWarning(new java.util.ArrayList(warning.length));
}
for (String ele : warning) {
this.warning.add(ele);
}
return this;
}
/**
* List of messages that warn about conditions that might cause your job not to run or to fail.
*
* @param warning
* List of messages that warn about conditions that might cause your job not to run or to fail.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public JobMessages withWarning(java.util.Collection warning) {
setWarning(warning);
return this;
}
/**
* Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
* redacted from this string using a placeholder value.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getInfo() != null)
sb.append("Info: ").append(getInfo()).append(",");
if (getWarning() != null)
sb.append("Warning: ").append(getWarning());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof JobMessages == false)
return false;
JobMessages other = (JobMessages) obj;
if (other.getInfo() == null ^ this.getInfo() == null)
return false;
if (other.getInfo() != null && other.getInfo().equals(this.getInfo()) == false)
return false;
if (other.getWarning() == null ^ this.getWarning() == null)
return false;
if (other.getWarning() != null && other.getWarning().equals(this.getWarning()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getInfo() == null) ? 0 : getInfo().hashCode());
hashCode = prime * hashCode + ((getWarning() == null) ? 0 : getWarning().hashCode());
return hashCode;
}
@Override
public JobMessages clone() {
try {
return (JobMessages) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.mediaconvert.model.transform.JobMessagesMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}